/home/runner/work/kynema-sgf/kynema-sgf/src/equation_systems/icns/source_terms/GeostrophicForcing.H Source File

Kynema-SGF API: /home/runner/work/kynema-sgf/kynema-sgf/src/equation_systems/icns/source_terms/GeostrophicForcing.H Source File
Kynema-SGF API v0.1.0
CFD solver for wind plant simulations
Loading...
Searching...
No Matches
GeostrophicForcing.H
Go to the documentation of this file.
1#ifndef GEOSTROPHICFORCING_H
2#define GEOSTROPHICFORCING_H
3
5#include "src/core/SimTime.H"
6#include "AMReX_REAL.H"
7
8using namespace amrex::literals;
9
10namespace kynema_sgf::pde::icns {
11
15class GeostrophicForcing : public MomentumSource::Register<GeostrophicForcing>
16{
17public:
18 static std::string identifier() { return "GeostrophicForcing"; }
19
20 explicit GeostrophicForcing(const CFDSim& /*unused*/);
21
23
24 void operator()(
25 int lev, FieldState fstate, amrex::MultiFab& src_term) const override;
26
27private:
29 const amrex::AmrCore& m_mesh;
30
32 std::string m_vel_timetable;
33
35 amrex::Vector<amrex::Real> m_time_table;
36
38 amrex::Vector<amrex::Real> m_speed_table;
39
41 amrex::Vector<amrex::Real> m_direction_table;
42
44 amrex::Real m_coriolis_factor;
45
47 bool m_use_phase_ramp{false};
48
50 int m_n_band{2};
51
53 amrex::Vector<amrex::Real> m_target_vel{0.0_rt, 0.0_rt, 0.0_rt};
54
56 amrex::Vector<amrex::Real> m_g_forcing{0.0_rt, 0.0_rt, 0.0_rt};
57
58 bool m_is_horizontal{false};
59
61 amrex::Real m_forcing_mphase0;
63 amrex::Real m_forcing_mphase1;
64
66 amrex::Real m_water_level;
67
69 const Field* m_vof;
70};
71
72} // namespace kynema_sgf::pde::icns
73
74#endif /* GEOSTROPHICFORCING_H */
Definition CFDSim.H:55
Definition Field.H:112
Definition SimTime.H:33
std::string m_vel_timetable
File name for target velocity time table.
Definition GeostrophicForcing.H:32
amrex::Vector< amrex::Real > m_target_vel
Target velocity.
Definition GeostrophicForcing.H:53
const amrex::AmrCore & m_mesh
Definition GeostrophicForcing.H:29
bool m_use_phase_ramp
Activated when water is present in domain.
Definition GeostrophicForcing.H:47
const Field * m_vof
VOF field, to avoid forcing on liquid above force-off height.
Definition GeostrophicForcing.H:69
amrex::Vector< amrex::Real > m_direction_table
Velocity forcing direction table.
Definition GeostrophicForcing.H:41
static std::string identifier()
Definition GeostrophicForcing.H:18
const SimTime & m_time
Definition GeostrophicForcing.H:28
amrex::Real m_forcing_mphase0
Height from water interface where force is off.
Definition GeostrophicForcing.H:61
int m_n_band
Number of cells in band to prevent forcing near liquid.
Definition GeostrophicForcing.H:50
bool m_is_horizontal
Definition GeostrophicForcing.H:58
GeostrophicForcing(const CFDSim &)
Definition GeostrophicForcing.cpp:28
amrex::Real m_forcing_mphase1
Height from water interface over which force is ramped.
Definition GeostrophicForcing.H:63
amrex::Real m_water_level
Local storage of interface location.
Definition GeostrophicForcing.H:66
void operator()(int lev, FieldState fstate, amrex::MultiFab &src_term) const override
Definition GeostrophicForcing.cpp:103
amrex::Vector< amrex::Real > m_speed_table
Velocity forcing speed table.
Definition GeostrophicForcing.H:38
amrex::Vector< amrex::Real > m_time_table
Velocity forcing time table.
Definition GeostrophicForcing.H:35
amrex::Vector< amrex::Real > m_g_forcing
Forcing source term (pressure gradient)
Definition GeostrophicForcing.H:56
amrex::Real m_coriolis_factor
Coriolis factor.
Definition GeostrophicForcing.H:44
FieldState
Definition FieldDescTypes.H:16
Definition ABLForcing.cpp:14