Revision e2963065808465e78c566a62c31a67b267867bb6 authored by Dmitry Yu. Naumov on 19 October 2021, 09:43:49 UTC, committed by Dmitry Yu. Naumov on 19 October 2021, 09:43:49 UTC
[TH2M] Fixed a bug in using pressure, strain, stress dependent permeability models See merge request ogs/ogs!3821
ODESolverBuilder.h
/**
* \file
* \copyright
* Copyright (c) 2012-2021, OpenGeoSys Community (http://www.opengeosys.org)
* Distributed under a Modified BSD License.
* See accompanying file LICENSE.txt or
* http://www.opengeosys.org/project/license
*
*/
#pragma once
#include "BaseLib/Error.h"
#include "ODESolver.h"
#include "ConcreteODESolver.h"
#ifdef CVODE_FOUND
#include "CVodeSolver.h"
#endif
namespace BaseLib
{
class ConfigTree;
}
namespace MathLib
{
namespace ODE
{
//! \addtogroup ExternalODESolverInterface
//! @{
/*! Creates a new ODESolver instance from the given \c config.
*
* \tparam NumEquations the number of equations in the ODE system to be solved.
*/
template <unsigned NumEquations>
std::unique_ptr<ODESolver<NumEquations>> createODESolver(
BaseLib::ConfigTree const& config)
{
#ifdef CVODE_FOUND
return std::unique_ptr<ODESolver<NumEquations>>(
new ConcreteODESolver<CVodeSolver, NumEquations>(config));
#endif
(void)config; // Unused parameter warning if no library is available.
OGS_FATAL(
"No ODE solver could be created. Maybe it is because you did not build"
" OGS6 with support for any external ODE solver library.");
}
//! @}
} // namespace ODE
} // namespace MathLib
![swh spinner](/static/img/swh-spinner.gif)
Computing file changes ...