Go to the documentation of this file.
7 #ifndef INCLUDE_JET_GRID_FRACTIONAL_SINGLE_PHASE_PRESSURE_SOLVER2_H_
8 #define INCLUDE_JET_GRID_FRACTIONAL_SINGLE_PHASE_PRESSURE_SOLVER2_H_
82 bool useCompressed =
false)
override;
113 std::vector<Array2<float>> _uWeights;
114 std::vector<Array2<float>> _vWeights;
115 std::vector<Array2<float>> _fluidSdf;
124 void decompressSolution();
134 typedef std::shared_ptr<GridFractionalSinglePhasePressureSolver2>
139 #endif // INCLUDE_JET_GRID_FRACTIONAL_SINGLE_PHASE_PRESSURE_SOLVER2_H_
Multigrid-syle 2-D linear system.
Definition: fdm_mg_linear_system2.h:23
const FdmLinearSystemSolver2Ptr & linearSystemSolver() const
Returns the linear system solver.
Compressed linear system (Ax=b) for 2-D finite differencing.
Definition: fdm_linear_system2.h:54
Linear system (Ax=b) for 2-D finite differencing.
Definition: fdm_linear_system2.h:36
std::shared_ptr< FdmLinearSystemSolver2 > FdmLinearSystemSolver2Ptr
Shared pointer type for the FdmLinearSystemSolver2.
Definition: fdm_linear_system_solver2.h:31
Vector2< double > Vector2D
Double-type 2D vector.
Definition: vector2.h:340
virtual ~GridFractionalSinglePhasePressureSolver2()
Default destructor.
Abstract base class for 2-D scalar field.
Definition: scalar_field2.h:18
GridBoundaryConditionSolver2Ptr suggestedBoundaryConditionSolver() const override
Returns the best boundary condition solver for this solver.
2-D face-centered (a.k.a MAC or staggered) grid.
Definition: face_centered_grid2.h:26
2-D array class.
Definition: array2.h:42
Definition: advection_solver2.h:18
void setLinearSystemSolver(const FdmLinearSystemSolver2Ptr &solver)
Sets the linear system solver.
2-D constant scalar field.
Definition: constant_scalar_field2.h:15
2-D vector class.
Definition: vector2.h:24
Abstract base class for 2-D grid-based pressure solver.
Definition: grid_pressure_solver2.h:29
const FdmVector2 & pressure() const
Returns the pressure field.
constexpr double kMaxD
Max double.
Definition: constants.h:88
GridFractionalSinglePhasePressureSolver2()
Default constructor.
void solve(const FaceCenteredGrid2 &input, double timeIntervalInSeconds, FaceCenteredGrid2 *output, const ScalarField2 &boundarySdf=ConstantScalarField2(kMaxD), const VectorField2 &boundaryVelocity=ConstantVectorField2({0, 0}), const ScalarField2 &fluidSdf=ConstantScalarField2(-kMaxD), bool useCompressed=false) override
Solves the pressure term and apply it to the velocity field.
std::shared_ptr< GridBoundaryConditionSolver2 > GridBoundaryConditionSolver2Ptr
Shared pointer type for the GridBoundaryConditionSolver2.
Definition: grid_boundary_condition_solver2.h:104
Abstract base class for 2-D vector field.
Definition: vector_field2.h:18
2-D fractional single-phase pressure solver.
Definition: grid_fractional_single_phase_pressure_solver2.h:47
std::shared_ptr< FdmMgSolver2 > FdmMgSolver2Ptr
Shared pointer type for the FdmMgSolver2.
Definition: fdm_mg_solver2.h:54
std::shared_ptr< GridFractionalSinglePhasePressureSolver2 > GridFractionalSinglePhasePressureSolver2Ptr
Shared pointer type for the GridFractionalSinglePhasePressureSolver2.
Definition: grid_fractional_single_phase_pressure_solver2.h:135
2-D constant vector field.
Definition: constant_vector_field2.h:16