|
using | IdxRange = typename FieldMem::discrete_domain_type |
| The type of the index range on which the values of the function are defined.
|
|
using | ValField = typename FieldMem::span_type |
| The type of the values of the function being evolved.
|
|
using | ValConstField = typename FieldMem::view_type |
| The constant type of the values of the function being evolved.
|
|
using | DerivField = typename DerivFieldMem::span_type |
| The type of the derivatives of the function being evolved.
|
|
using | DerivConstField = typename DerivFieldMem::view_type |
| The constant type of the derivatives values of the function being evolved.
|
|
|
void | update (ValField y, double dt, std::function< void(DerivField, ValConstField)> dy_calculator) const |
| Carry out one step of the timestepping scheme.
|
|
void | update (ExecSpace const &exec_space, ValField y, double dt, std::function< void(DerivField, ValConstField)> dy_calculator) const |
| Carry out one step of the timestepping scheme.
|
|
virtual void | update (ExecSpace const &exec_space, ValField y, double dt, std::function< void(DerivField, ValConstField)> dy_calculator, std::function< void(ValField, DerivConstField, double)> y_update) const =0 |
| Carry out one step of the timestepping scheme.
|
|
template<class FieldType , class FuncType , std::size_t n_args> |
void | assemble_field_k_total (ExecSpace const &exec_space, FieldType k_total, FuncType func, std::array< FieldType, n_args > k_arr) const |
| Calculate func(k_arr[0], k_arr[1], ...) when FieldType is a Field (ddc::ChunkSpan).
|
|
template<class FieldType , class FuncType , std::size_t n_args> |
void | assemble_vector_field_k_total (ExecSpace const &exec_space, FieldType k_total, FuncType func, std::array< FieldType, n_args > k_arr) const |
| Calculate func(k_arr[0], k_arr[1], ...) when FieldType is a VectorField.
|
|
template<class FieldMem, class
DerivFieldMem = FieldMem, class ExecSpace = Kokkos::DefaultExecutionSpace>
class ITimeStepper< FieldMem, DerivFieldMem, ExecSpace >
The superclass from which all timestepping methods inherit.
The class exposes three update functions which are used to carry out one step of the chosen timestepping method to solve an ODE of the form: \(\partial_t y(t) = f(t, y(t)) \),
template<class FieldMem , class
DerivFieldMem = FieldMem, class ExecSpace = Kokkos::DefaultExecutionSpace>
Carry out one step of the timestepping scheme.
- Parameters
-
[in] | exec_space | The space on which the function is executed (CPU/GPU). |
[in,out] | y | The value(s) which should be evolved over time defined on each of the dimensions at each point of the index range. |
[in] | dt | The time step over which the values should be evolved. |
[in] | dy_calculator | The function describing how the derivative of the evolve function is calculated. |
[in] | y_update | The function describing how the value(s) are updated using the derivative. |
Implemented in CrankNicolson< FieldMem, DerivFieldMem, ExecSpace >, Euler< FieldMem, DerivFieldMem, ExecSpace >, RK2< FieldMem, DerivFieldMem, ExecSpace >, RK3< FieldMem, DerivFieldMem, ExecSpace >, RK4< FieldMem, DerivFieldMem, ExecSpace >, CrankNicolson< FieldMem, DerivFieldMem, ExecSpace >, Euler< FieldMem, DerivFieldMem, ExecSpace >, RK2< FieldMem, DerivFieldMem, ExecSpace >, RK3< FieldMem, DerivFieldMem, ExecSpace >, and RK4< FieldMem, DerivFieldMem, ExecSpace >.
template<class FieldMem , class
DerivFieldMem = FieldMem, class ExecSpace = Kokkos::DefaultExecutionSpace>
template<class FieldType , class FuncType , std::size_t n_args>
void ITimeStepper< FieldMem, DerivFieldMem, ExecSpace >::assemble_field_k_total |
( |
ExecSpace const & |
exec_space, |
|
|
FieldType |
k_total, |
|
|
FuncType |
func, |
|
|
std::array< FieldType, n_args > |
k_arr |
|
) |
| const |
|
inline |
Calculate func(k_arr[0], k_arr[1], ...) when FieldType is a Field (ddc::ChunkSpan).
This function should be private but is public due to Cuda restrictions.
- Parameters
-
[in] | exec_space | The space (CPU/GPU) where the calculation should be executed. |
[out] | k_total | The field to be filled with the combined derivative fields. |
[in] | func | A function which combines an element from each of the derivative fields. |
[in] | k_arr | The derivative fields being combined. |
template<class FieldMem , class
DerivFieldMem = FieldMem, class ExecSpace = Kokkos::DefaultExecutionSpace>
template<class FieldType , class FuncType , std::size_t n_args>
void ITimeStepper< FieldMem, DerivFieldMem, ExecSpace >::assemble_vector_field_k_total |
( |
ExecSpace const & |
exec_space, |
|
|
FieldType |
k_total, |
|
|
FuncType |
func, |
|
|
std::array< FieldType, n_args > |
k_arr |
|
) |
| const |
|
inline |
Calculate func(k_arr[0], k_arr[1], ...) when FieldType is a VectorField.
This function should be private but is public due to Cuda restrictions.
- Parameters
-
[in] | exec_space | The space (CPU/GPU) where the calculation should be executed. |
[out] | k_total | The field to be filled with the combined derivative fields. |
[in] | func | A function which combines an element from each of the derivative fields. |
[in] | k_arr | The derivative fields being combined. |