8from .kernels
import create_compute_Riemann_kernel_for_Rusanov
9from .kernels
import create_abstract_solver_declarations
10from .kernels
import create_abstract_solver_definitions
11from .kernels
import create_solver_declarations
12from .kernels
import create_solver_definitions
16from .kernels
import SolverVariant
17from .kernels
import KernelVariant
24 name, patch_size, unknowns, auxiliary_variables, min_volume_h, max_volume_h, time_step_size,
25 flux=PDETerms.User_Defined_Implementation,
26 ncp=PDETerms.None_Implementation,
27 eigenvalues=PDETerms.User_Defined_Implementation,
28 boundary_conditions=PDETerms.User_Defined_Implementation,
29 refinement_criterion=PDETerms.Empty_Implementation,
30 initial_conditions=PDETerms.User_Defined_Implementation,
31 source_term=PDETerms.None_Implementation,
32 plot_grid_properties=False,
33 interpolate_linearly_in_time=True, overlap=1
37 This is the normalised time step size w.r.t. the coarsest admissible h value. If
38 the code employs AMR on top of it and refines further, it will automatically
39 downscale the time step size accordingly. So hand in a valid time step size w.r.t.
44 super(SubcyclingFixedTimeStep,self).
__init__(name,
52 kernel_namespace=
"rusanov")
62 eigenvalues=eigenvalues,
63 boundary_conditions=boundary_conditions,
64 refinement_criterion=refinement_criterion,
65 initial_conditions=initial_conditions,
66 source_term=source_term )
72 boundary_conditions=None,refinement_criterion=None,initial_conditions=None,source_term=None,
73 memory_location = None,
74 use_split_loop = False,
75 additional_action_set_includes = "",
76 additional_user_includes = ""
79 If you pass in User_Defined, then the generator will create C++ stubs
80 that you have to befill manually. If you pass in None_Implementation, it
81 will create nop, i.e., no implementation or defaults. Any other string
82 is copied 1:1 into the implementation. If you pass in None, then the
83 set value so far won't be overwritten.
85 Please note that not all options are supported by all solvers.
87 This routine should be the very last invoked by the constructor.
98 compute_max_eigenvalue_of_next_time_step =
False,
99 solver_variant = SolverVariant.WithVirtualFunctions,
100 kernel_variant = KernelVariant.PatchWiseAoS
107 compute_max_eigenvalue_of_next_time_step =
False,
108 solver_variant = SolverVariant.Stateless,
109 kernel_variant = KernelVariant.PatchWiseAoS
130#include "exahype2/TimeStepping.h"
131#include "exahype2/fv/rusanov/rusanov.h"
134 super(SubcyclingFixedTimeStep,self).
set_implementation(boundary_conditions, refinement_criterion, initial_conditions, memory_location, use_split_loop, additional_action_set_includes, additional_user_includes)
139 The actual action sets all are created by the superclass. So nothing
140 is to be done here. But we want to reset the actual updates and
141 projection, and these only happen if we are allowed to update
_abstract_solver_user_declarations
_solver_user_declarations
_user_action_set_includes
_source_term_implementation
_compute_new_time_step_size
_start_time_step_implementation
_eigenvalues_implementation
_compute_kernel_call_stateless
_constructor_implementation
_finish_time_step_implementation
_abstract_solver_user_definitions
Code snippet generator for fixed time stepping in the Runge-Kutta schemes.
Probably the simplest solver you could think off.
set_implementation(self, boundary_conditions, refinement_criterion, initial_conditions, memory_location, use_split_loop, additional_action_set_includes, additional_user_includes)
If you pass in User_Defined, then the generator will create C++ stubs that you have to befill manuall...
_interpolate_linearly_in_time
_abstract_solver_user_declarations
_compute_kernel_call_stateless
__init__(self, name, patch_size, unknowns, auxiliary_variables, min_volume_h, max_volume_h, time_step_size, flux=PDETerms.User_Defined_Implementation, ncp=PDETerms.None_Implementation, eigenvalues=PDETerms.User_Defined_Implementation, boundary_conditions=PDETerms.User_Defined_Implementation, refinement_criterion=PDETerms.Empty_Implementation, initial_conditions=PDETerms.User_Defined_Implementation, source_term=PDETerms.None_Implementation, plot_grid_properties=False, interpolate_linearly_in_time=True, overlap=1)
time_step_size: Float This is the normalised time step size w.r.t.
_source_term_implementation
create_data_structures(self)
Call the superclass' create_data_structures() to ensure that all the data structures are in place,...
_solver_user_declarations
set_implementation(self, flux=None, ncp=None, eigenvalues=None, boundary_conditions=None, refinement_criterion=None, initial_conditions=None, source_term=None, memory_location=None, use_split_loop=False, additional_action_set_includes="", additional_user_includes="")
If you pass in User_Defined, then the generator will create C++ stubs that you have to befill manuall...
_abstract_solver_user_definitions
_compute_new_time_step_size
create_action_sets(self)
The actual action sets all are created by the superclass.
_constructor_implementation
_finish_time_step_implementation
_start_time_step_implementation
_eigenvalues_implementation