ExaDG
Loading...
Searching...
No Matches
parameters.h
1/* ______________________________________________________________________
2 *
3 * ExaDG - High-Order Discontinuous Galerkin for the Exa-Scale
4 *
5 * Copyright (C) 2021 by the ExaDG authors
6 *
7 * This program is free software: you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License as published by
9 * the Free Software Foundation, either version 3 of the License, or
10 * (at your option) any later version.
11 *
12 * This program is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
16 *
17 * You should have received a copy of the GNU General Public License
18 * along with this program. If not, see <https://www.gnu.org/licenses/>.
19 * ______________________________________________________________________
20 */
21
22#ifndef INCLUDE_EXADG_FLUID_STRUCTURE_INTERACTION_ACCELERATION_SCHEMES_PARAMETERS_H_
23#define INCLUDE_EXADG_FLUID_STRUCTURE_INTERACTION_ACCELERATION_SCHEMES_PARAMETERS_H_
24
25namespace ExaDG
26{
27namespace FSI
28{
29enum class AccelerationMethod
30{
31 Undefined,
32 Aitken,
33 IQN_ILS,
34 IQN_IMVLS
35};
36
37// The initial guess used in the FSI coupling loop is computed using an extrapolation of suitable
38// order (defined within the single-field time integrators) or the last iterate from the previous
39// time step.
40enum class InitialGuessCouplingScheme
41{
42 SolutionExtrapolatedToEndOfTimeStep,
43 ConvergedSolutionOfPreviousTimeStep
44};
45
46struct Parameters
47{
48 Parameters()
49 : acceleration_method(AccelerationMethod::Undefined),
50 abs_tol(1.e-12),
51 rel_tol(1.e-3),
52 omega_init(0.1),
53 initial_guess_coupling_scheme(
54 InitialGuessCouplingScheme::SolutionExtrapolatedToEndOfTimeStep),
55 reused_time_steps(0),
56 partitioned_iter_max(100),
57 geometric_tolerance(1.e-10)
58 {
59 }
60
61 void
62 add_parameters(dealii::ParameterHandler & prm, std::string const & subsection_name = "FSI")
63 {
64 prm.enter_subsection(subsection_name);
65 {
66 prm.add_parameter("AccelerationMethod",
67 acceleration_method,
68 "Acceleration method.",
69 Patterns::Enum<AccelerationMethod>(),
70 true);
71 prm.add_parameter(
72 "AbsTol", abs_tol, "Absolute solver tolerance.", dealii::Patterns::Double(0.0, 1.0), true);
73 prm.add_parameter(
74 "RelTol", rel_tol, "Relative solver tolerance.", dealii::Patterns::Double(0.0, 1.0), true);
75 prm.add_parameter("OmegaInit",
76 omega_init,
77 "Initial relaxation parameter.",
78 dealii::Patterns::Double(0.0, 1.0),
79 true);
80 prm.add_parameter("InitialGuessCouplingScheme",
81 initial_guess_coupling_scheme,
82 "Scheme for initial guess for the FSI coupling loop at every time step.",
83 Patterns::Enum<InitialGuessCouplingScheme>(),
84 false);
85 prm.add_parameter("ReusedTimeSteps",
86 reused_time_steps,
87 "Number of time steps reused for acceleration.",
88 dealii::Patterns::Integer(0, 100),
89 false);
90 prm.add_parameter("PartitionedIterMax",
91 partitioned_iter_max,
92 "Maximum number of fixed-point iterations.",
93 dealii::Patterns::Integer(1, 1000),
94 true);
95 prm.add_parameter("GeometricTolerance",
96 geometric_tolerance,
97 "Tolerance used to locate points at FSI interface.",
98 dealii::Patterns::Double(0.0, 1.0),
99 false);
100 }
101 prm.leave_subsection();
102 }
103
104 AccelerationMethod acceleration_method;
105 double abs_tol;
106 double rel_tol;
107 double omega_init;
108 InitialGuessCouplingScheme initial_guess_coupling_scheme;
109 unsigned int reused_time_steps;
110 unsigned int partitioned_iter_max;
111
112 // tolerance used to locate points at the fluid-structure interface
113 double geometric_tolerance;
114};
115} // namespace FSI
116} // namespace ExaDG
117
118
119
120#endif /* INCLUDE_EXADG_FLUID_STRUCTURE_INTERACTION_ACCELERATION_SCHEMES_PARAMETERS_H_ */
Definition driver.cpp:33