Finite Volume Solver  prototype
A framework to build finite volume solvers for the AG Klein at the Freie Universität Berlin.
IgnitionDelayKinetics.hpp
Go to the documentation of this file.
1 // Copyright (c) 2020 Maikel Nadolski
2 // Copyright (c) 2020 Christian Zenker
3 //
4 // Permission is hereby granted, free of charge, to any person obtaining a copy
5 // of this software and associated documentation files (the "Software"), to deal
6 // in the Software without restriction, including without limitation the rights
7 // to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
8 // copies of the Software, and to permit persons to whom the Software is
9 // furnished to do so, subject to the following conditions:
10 //
11 // The above copyright notice and this permission notice shall be included in
12 // all copies or substantial portions of the Software.
13 //
14 // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
15 // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
16 // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
17 // AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
18 // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
19 // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
20 // SOFTWARE.
21 
22 #ifndef FUB_PERFECT_GAS_MIX_IGNITION_DELAY_KINETICS_HPP
23 #define FUB_PERFECT_GAS_MIX_IGNITION_DELAY_KINETICS_HPP
24 
26 #include "fub/TimeStepError.hpp"
28 #include "fub/ext/omp.hpp"
29 #include "fub/ext/outcome.hpp"
30 
31 #include <memory>
32 
33 namespace fub::perfect_gas_mix {
34 
36  double Yign{0.2};
37  double Yinit{1.0};
38  double tau{1.0};
39  double R_B{0.};
40  double R_C{70.};
41  double R_E{1.2};
42  double R2_A{0.};
43  double R2_C{5.};
44  double R2_E{1.5};
45  double E{0.5};
46  double C{7.};
47  double Tdiff{2.7};
48 };
49 
50 /// \ingroup LevelIntegrator
51 template <int R> class IgnitionDelayKinetics {
52 public:
53  static constexpr int Rank = R;
54  static constexpr std::size_t sRank = static_cast<std::size_t>(Rank);
55 
57 
59 
61  AdvanceLevel(amrex::IntegratorContext& simulation_data, int level,
62  Duration dt,
63  const ::amrex::IntVect& ngrow = ::amrex::IntVect(0));
64 
66 
67 private:
71 };
72 
73 extern template class IgnitionDelayKinetics<1>;
74 extern template class IgnitionDelayKinetics<2>;
75 extern template class IgnitionDelayKinetics<3>;
76 
77 } // namespace fub::perfect_gas_mix
78 
79 #endif
Definition: omp.hpp:42
This class is used by the HypebrolicSplitLevelIntegrator and delegates AMR related tasks to the AMReX...
Definition: AMReX/IntegratorContext.hpp:49
Definition: IgnitionDelayKinetics.hpp:51
static constexpr std::size_t sRank
Definition: IgnitionDelayKinetics.hpp:54
IgnitionDelayKinetics(const PerfectGasMix< Rank > &eq)
IgnitionDelayKineticsOptions options
Definition: IgnitionDelayKinetics.hpp:65
OmpLocal< KineticStateArray< PerfectGasMix< Rank > > > kinetic_state_
Definition: IgnitionDelayKinetics.hpp:70
static constexpr int Rank
Definition: IgnitionDelayKinetics.hpp:53
Result< void, TimeStepTooLarge > AdvanceLevel(amrex::IntegratorContext &simulation_data, int level, Duration dt, const ::amrex::IntVect &ngrow=::amrex::IntVect(0))
OmpLocal< CompleteArray< PerfectGasMix< Rank > > > state_
Definition: IgnitionDelayKinetics.hpp:69
OmpLocal< PerfectGasMix< Rank > > equation_
Definition: IgnitionDelayKinetics.hpp:68
Definition: ArrheniusKinetics.hpp:34
std::chrono::duration< double > Duration
Definition: Duration.hpp:31
boost::outcome_v2::result< T, E > Result
Definition: outcome.hpp:32
Definition: PerfectGasMix.hpp:208
Definition: IgnitionDelayKinetics.hpp:35
double R_C
Definition: IgnitionDelayKinetics.hpp:40
double R2_E
Definition: IgnitionDelayKinetics.hpp:44
double tau
Definition: IgnitionDelayKinetics.hpp:38
double R_B
Definition: IgnitionDelayKinetics.hpp:39
double R_E
Definition: IgnitionDelayKinetics.hpp:41
double Yign
Definition: IgnitionDelayKinetics.hpp:36
double Tdiff
Definition: IgnitionDelayKinetics.hpp:47
double Yinit
Definition: IgnitionDelayKinetics.hpp:37
double E
Definition: IgnitionDelayKinetics.hpp:45
double R2_C
Definition: IgnitionDelayKinetics.hpp:43
double C
Definition: IgnitionDelayKinetics.hpp:46
double R2_A
Definition: IgnitionDelayKinetics.hpp:42