AdvectionSolver3.h
Go to the documentation of this file.
1 /*************************************************************************
2 > File Name: AdvectionSolver3.h
3 > Project Name: CubbyFlow
4 > Author: Chan-Ho Chris Ohk
5 > Purpose: Abstract based class for 3-D grid-based advection solver.
6 > Created Time: 2017/08/07
7 > Copyright (c) 2018, Chan-Ho Chris Ohk
8 *************************************************************************/
9 #ifndef CUBBYFLOW_ADVECTION_SOLVER3_H
10 #define CUBBYFLOW_ADVECTION_SOLVER3_H
11 
16 #include <Core/Grid/ScalarGrid3.h>
17 
18 namespace CubbyFlow
19 {
27  {
28  public:
30 
31  virtual ~AdvectionSolver3();
32 
52  virtual void Advect(
53  const ScalarGrid3& input,
54  const VectorField3& flow,
55  double dt,
56  ScalarGrid3* output,
57  const ScalarField3& boundarySDF = ConstantScalarField3(std::numeric_limits<double>::max())) = 0;
58 
78  virtual void Advect(
79  const CollocatedVectorGrid3& input,
80  const VectorField3& flow,
81  double dt,
82  CollocatedVectorGrid3* output,
83  const ScalarField3& boundarySDF = ConstantScalarField3(std::numeric_limits<double>::max()));
84 
104  virtual void Advect(
105  const FaceCenteredGrid3& input,
106  const VectorField3& flow,
107  double dt,
108  FaceCenteredGrid3* output,
109  const ScalarField3& boundarySDF = ConstantScalarField3(std::numeric_limits<double>::max()));
110  };
111 
113  using AdvectionSolver3Ptr = std::shared_ptr<AdvectionSolver3>;
114 }
115 
116 #endif
Abstract base class for 3-D collocated vector grid structure.
Definition: CollocatedVectorGrid3.h:19
std::shared_ptr< AdvectionSolver3 > AdvectionSolver3Ptr
Shared pointer type for the 3-D advection solver.
Definition: AdvectionSolver3.h:113
3-D face-centered (a.k.a MAC or staggered) grid.
Definition: FaceCenteredGrid3.h:25
virtual void Advect(const ScalarGrid3 &input, const VectorField3 &flow, double dt, ScalarGrid3 *output, const ScalarField3 &boundarySDF=ConstantScalarField3(std::numeric_limits< double >::max()))=0
Solves advection equation for given scalar grid.
Definition: pybind11Utils.h:24
3-D constant scalar field.
Definition: ConstantScalarField3.h:17
Abstract based class for 3-D grid-based advection solver.
Definition: AdvectionSolver3.h:26
Abstract base class for 3-D vector field.
Definition: VectorField3.h:21
Abstract base class for 3-D scalar field.
Definition: ScalarField3.h:21
Abstract base class for 3-D scalar grid structure.
Definition: ScalarGrid3.h:21