The TS-GitLab will have to shut down towards the end of the year — please think about migrating your projects to GitLab.com or GitHub.
(This is still a very early message, meant to keep you informed. There will be more urgent ones in the future.)

Commit b672d79c authored by Santiago Ospina's avatar Santiago Ospina
Browse files

Adds documentation for the CFL condition.


Signed-off-by: Santiago Ospina De Los Ríos's avatarSantiago Ospina <santiago.ospina@iup.uni-heidelberg.de>
parent 375f55c9
......@@ -9,27 +9,35 @@ namespace Dune{
namespace Dorie{
/**
* @brief Computes the CFL condition for a grid function representing a
* velocity field. In particular, the return value is the
* suggested timestep for the lowest CFL ratio for each cell:
* @brief Computes the CFL-condition (\f$\mathcal{CFL}\f$) for a grid
* function representing a velocity field. In particular, the
* return value is the suggested timestep for the lowest CFL
* ratio for each cell:
*
* @f{eqnarray*}{
* CFL = \min_{T\in\mathcal{T}_h}{||\beta||^{-1}_{L^inf(T)h^T} \\
* \delta t \lt \rho CFL
* \mathcal{CFL} = \min_{T\in\mathcal{T}_h} ||\beta||^{-1}_{[L^\infty(T)]^d}h_T
* @f}
* where \f$\mathcal{T}_h\f$ is triangulation, \f$\beta\f$ the
* velocity field, and \f$h_T\f$ the diameter of the cell
* \f$T\in \mathcal{T}_h\f$.
* As is usual with the CFL-condition, one can restrict the time
* step \f$\Delta t\f$ for explicit schemes using a given courant
* number \f$\varrho \le 1\f$:
*
* @f{eqnarray*}{
* \Delta t \lt \varrho \cdot \mathcal{CFL}
* @f}
* where $\rho$ is the courant number and $\beta$ is the velocity
* field.
*
* @param[in] gf Grid function representing the veolcity field
* $\beta$.
* \f$\beta\f$.
* @param[in] intorder The integration order. This value determines the
* quadrature points to evaluate
* $||\beta||_{L^inf(T)h^T}$.
* \f$||\beta||_{[L^\infty(T)]^d}h_T\f$.
*
* @tparam GF The grid function type.
* @tparam TF The time field. Type to represent time values.
*
* @return { description_of_the_return_value }
* @return The CFL-condition (\f$\mathcal{CFL}\f$)
*/
template<class GF, class TF = double>
TF cfl_condition(const GF& gf, unsigned int intorder = 1)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment