Line data Source code
1 0 : // Distributed under the MIT License. 2 : // See LICENSE.txt for details. 3 : 4 : #pragma once 5 : 6 : #include <cstddef> 7 : 8 : #include "Time/StepChoosers/Cfl.hpp" 9 : #include "Time/StepChoosers/Constant.hpp" 10 : #include "Time/StepChoosers/ElementSizeCfl.hpp" 11 : #include "Time/StepChoosers/ErrorControl.hpp" 12 : #include "Time/StepChoosers/LimitIncrease.hpp" 13 : #include "Time/StepChoosers/Maximum.hpp" 14 : #include "Time/StepChoosers/PreventRapidIncrease.hpp" 15 : #include "Time/StepChoosers/StepToTimes.hpp" 16 : #include "Utilities/TMPL.hpp" 17 : 18 : /// \cond 19 : namespace Frame { 20 : struct Inertial; 21 : } // namespace Frame 22 : /// \endcond 23 : 24 : namespace StepChoosers { 25 : namespace Factory_detail { 26 : template <typename Use, typename System, bool HasCharSpeedFunctions> 27 : using common_step_choosers = tmpl::push_back< 28 : tmpl::conditional_t< 29 : HasCharSpeedFunctions, 30 : tmpl::list<StepChoosers::Cfl<Frame::Inertial, System>, 31 : StepChoosers::ElementSizeCfl<System::volume_dim, System>>, 32 : tmpl::list<>>, 33 : StepChoosers::Constant, 34 : StepChoosers::ErrorControl<Use, typename System::variables_tag>, 35 : StepChoosers::LimitIncrease, StepChoosers::Maximum, 36 : StepChoosers::PreventRapidIncrease<typename System::variables_tag>>; 37 : } // namespace Factory_detail 38 : 39 : template <typename System, bool HasCharSpeedFunctions = true> 40 0 : using standard_step_choosers = 41 : Factory_detail::common_step_choosers<StepChooserUse::LtsStep, System, 42 : HasCharSpeedFunctions>; 43 : 44 : template <typename System, bool HasCharSpeedFunctions = true> 45 0 : using standard_slab_choosers = 46 : tmpl::push_back<Factory_detail::common_step_choosers< 47 : StepChooserUse::Slab, System, HasCharSpeedFunctions>, 48 : StepChoosers::StepToTimes>; 49 : } // namespace StepChoosers