ryujin 2.1.1 revision ee5cbcbf2346c1299c942d0e1f13b46449973c18
Loading...
Searching...
No Matches
parabolic_system.h
Go to the documentation of this file.
1//
2// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
3// Copyright (C) 2026 by the ryujin authors
4//
5
6#pragma once
7
8#include <compile_time_options.h>
10
11#include <deal.II/base/function_parser.h>
12#include <deal.II/base/parameter_acceptor.h>
13#include <deal.II/base/tensor.h>
14
15
16namespace ryujin
17{
18 namespace EulerPoisson
19 {
27 class ParabolicSystem final : public dealii::ParameterAcceptor
28 {
29 public:
30 static inline const std::string problem_name =
31 "Electrostatic force model with background magnetic field";
32
33 static constexpr bool is_identity = false;
34
35 ParabolicSystem(const std::string &subsection = "/ParabolicSystem");
36
38
39 ACCESSOR_READ_ONLY(magnetic_drift_limit);
40
41 ACCESSOR_READ_ONLY(electrostatic_configuration);
42
43 ACCESSOR_READ_ONLY(subsection);
44
45 unsigned int n_parabolic_state_vectors() const
46 {
47 return parabolic_component_names_.size();
48 }
49
50
51 ACCESSOR_READ_ONLY(parabolic_component_names);
52
53 private:
54 double alpha_;
55 bool magnetic_drift_limit_;
56 std::string subsection_;
57
58 std::string electrostatic_configuration_;
59
60 static inline const std::vector<std::string> parabolic_component_names_ =
61 {"phi"};
62 };
63
64
65 inline ParabolicSystem::ParabolicSystem(const std::string &subsection)
66 : ParameterAcceptor(subsection)
67 , subsection_(subsection)
68 {
69 alpha_ = 1.0;
70 add_parameter("alpha", alpha_, "The coupling constant alpha");
71
72 magnetic_drift_limit_ = false;
73 add_parameter("set up magnetic drift limit",
74 magnetic_drift_limit_,
75 "If set to true, then the velocity field is initialized to "
76 "satisfy the magnetic drift limit.");
77
78 electrostatic_configuration_ = "constant";
79 add_parameter(
80 "electrostatic configuration",
81 electrostatic_configuration_,
82 "Valid names are given by any of the subsections defined below");
83 }
84
85 } // namespace EulerPoisson
86} // namespace ryujin
ParabolicSystem(const std::string &subsection="/ParabolicSystem")
ACCESSOR_READ_ONLY(parabolic_component_names)
unsigned int n_parabolic_state_vectors() const
static const std::string problem_name
#define ACCESSOR_READ_ONLY(member)