Jet
v1.3.3
|
Abstract base class for 2-D grid-based diffusion equation solver. More...
#include <jet/grid_diffusion_solver2.h>
Public Member Functions | |
GridDiffusionSolver2 () | |
Default constructor. More... | |
virtual | ~GridDiffusionSolver2 () |
Default destructor. More... | |
virtual void | solve (const ScalarGrid2 &source, double diffusionCoefficient, double timeIntervalInSeconds, ScalarGrid2 *dest, const ScalarField2 &boundarySdf=ConstantScalarField2(kMaxD), const ScalarField2 &fluidSdf=ConstantScalarField2(-kMaxD))=0 |
virtual void | solve (const CollocatedVectorGrid2 &source, double diffusionCoefficient, double timeIntervalInSeconds, CollocatedVectorGrid2 *dest, const ScalarField2 &boundarySdf=ConstantScalarField2(kMaxD), const ScalarField2 &fluidSdf=ConstantScalarField2(-kMaxD))=0 |
virtual void | solve (const FaceCenteredGrid2 &source, double diffusionCoefficient, double timeIntervalInSeconds, FaceCenteredGrid2 *dest, const ScalarField2 &boundarySdf=ConstantScalarField2(kMaxD), const ScalarField2 &fluidSdf=ConstantScalarField2(-kMaxD))=0 |
Abstract base class for 2-D grid-based diffusion equation solver.
This class provides functions to solve the diffusion equation for different types of fields. The target equation can be written as where
is the diffusion coefficient. The field
can be either scalar or vector field.
jet::GridDiffusionSolver2::GridDiffusionSolver2 | ( | ) |
Default constructor.
|
virtual |
Default destructor.
|
pure virtual |
Solves diffusion equation for a collocated vector field.
source | Input collocated vector field. |
diffusionCoefficient | Amount of diffusion. |
timeIntervalInSeconds | Small time-interval that diffusion occur. |
dest | Output collocated vector field. |
boundarySdf | Shape of the solid boundary that is empty by default. |
boundarySdf | Shape of the fluid boundary that is full by default. |
Implemented in jet::GridBackwardEulerDiffusionSolver2, and jet::GridForwardEulerDiffusionSolver2.
|
pure virtual |
Solves diffusion equation for a face-centered vector field.
source | Input face-centered vector field. |
diffusionCoefficient | Amount of diffusion. |
timeIntervalInSeconds | Small time-interval that diffusion occur. |
dest | Output face-centered vector field. |
boundarySdf | Shape of the solid boundary that is empty by default. |
boundarySdf | Shape of the fluid boundary that is full by default. |
Implemented in jet::GridBackwardEulerDiffusionSolver2, and jet::GridForwardEulerDiffusionSolver2.
|
pure virtual |
Solves diffusion equation for a scalar field.
source | Input scalar field. |
diffusionCoefficient | Amount of diffusion. |
timeIntervalInSeconds | Small time-interval that diffusion occur. |
dest | Output scalar field. |
boundarySdf | Shape of the solid boundary that is empty by default. |
boundarySdf | Shape of the fluid boundary that is full by default. |
Implemented in jet::GridBackwardEulerDiffusionSolver2, and jet::GridForwardEulerDiffusionSolver2.