/home/runner/work/amr-wind/amr-wind/amr-wind/equation_systems/vof/vof_bcop.H Source File

AMR-Wind API: /home/runner/work/amr-wind/amr-wind/amr-wind/equation_systems/vof/vof_bcop.H Source File
AMR-Wind API v0.1.0
CFD solver for wind plant simulations
Loading...
Searching...
No Matches
vof_bcop.H
Go to the documentation of this file.
1#ifndef VOF_BCOP_H
2#define VOF_BCOP_H
3
7
8namespace amr_wind::pde {
9
13template <>
14struct BCOp<VOF>
15{
16 BCOp(PDEFields& fields, const SimTime& time)
17 : m_fields(fields), m_time(time)
18 {}
19
20 void init_bcs()
21 {
22 BCVOF bc(m_fields.field);
24
25 // No source terms currently exist for VOF, so this is inconsequential
26 BCSrcTerm bc_src(m_fields.src_term);
27 bc_src();
28 }
29
30 void apply_bcs(const FieldState rho_state)
31 {
32 amrex::IntVect ng_diff(1);
33 auto& field = m_fields.field;
34 if ((rho_state != FieldState::Old && rho_state != FieldState::New)) {
35 amrex::Abort(
36 "vof_bcop.H apply_bcs(): a state other than New or Old was "
37 "used. The time used for fillphysbc must be evaluated before "
38 "using a different state for this routine.");
39 }
40 if (rho_state == FieldState::New) {
41 field.fillphysbc(m_time.new_time(), ng_diff);
42 }
43 field.apply_bc_funcs(rho_state);
44 }
45
48};
49
50} // namespace amr_wind::pde
51
52#endif /* VOF_BCOP_H */
Definition BCInterface.H:141
Definition vof_bciface.H:13
Definition SimTime.H:30
FieldState
Definition FieldDescTypes.H:14
@ New
Same as FieldState::NP1.
@ Old
Same as FieldState::N.
Definition AdvOp_Godunov.H:16
void init_bcs()
Definition vof_bcop.H:20
PDEFields & m_fields
Definition vof_bcop.H:46
BCOp(PDEFields &fields, const SimTime &time)
Definition vof_bcop.H:16
void apply_bcs(const FieldState rho_state)
Definition vof_bcop.H:30
const SimTime & m_time
Definition vof_bcop.H:47
Definition PDEOps.H:198
Definition PDEFields.H:27
Definition vof.H:17
static constexpr amrex::Real default_bc_value
Definition vof.H:29