Description

Class to represent the fluid dynamics system.

This class is used to represent a fluid system and take care of the time integration of the fluid dynamics. This is a class designed for base SPH simulation.

The class holds pointer to data, which is hold somewhere else. It also include a forceSystem, which takes care of the computation of force between markers. The forceSystem is owned by the class.

Inherits chrono::fsi::ChFsiGeneral.

Collaboration diagram for chrono::fsi::ChFluidDynamics:

Public Member Functions

 ChFluidDynamics (ChBce *otherBceWorker, ChFsiDataManager *otherFsiData, SimParams *otherParamsH, NumberOfObjects *otherNumObjects)
 Fluid dynamics class constructor. More...
 
 ~ChFluidDynamics ()
 Class destructor. Deletes the force system.
 
virtual void IntegrateSPH (SphMarkerDataD *sphMarkersD2, SphMarkerDataD *sphMarkersD1, FsiBodiesDataD *fsiBodiesD1, Real dT)
 Integrate the fluid system in time. More...
 
virtual void DensityReinitialization ()
 Function to Shepard Filtering. More...
 
virtual void Finalize ()
 Synchronize the copy of the data (parameters and number of objects) between device (GPU) and host (CPU). More...
 

Protected Member Functions

virtual void UpdateFluid (SphMarkerDataD *sphMarkersD, Real dT)
 Update SPH markers data. More...
 
virtual void ApplyBoundarySPH_Markers (SphMarkerDataD *sphMarkersD)
 Apply boundary to SPH markers (fluid and BCE). More...
 

Protected Attributes

ChFsiDataManagerfsiData
 pointer to the fsi data. The values are maintained externally
 
ChFsiForceParallelforceSystem
 force system object. It calculates the force between markers.
 
SimParamsparamsH
 pointer to parameters. The values are mainained externally.
 
NumberOfObjectsnumObjectsH
 pointer to number of objects (fluid markers, number of rigids, boundaries)
 

Constructor & Destructor Documentation

chrono::fsi::ChFluidDynamics::ChFluidDynamics ( ChBce otherBceWorker,
ChFsiDataManager otherFsiData,
SimParams otherParamsH,
NumberOfObjects otherNumObjects 
)

Fluid dynamics class constructor.

The class constructor performs the following operations: Instantiate ChFsiForceParallel, i.e. force system; Copy the pointer to fluid data, parameters, and number of objects to member variables.

Member Function Documentation

virtual void chrono::fsi::ChFluidDynamics::ApplyBoundarySPH_Markers ( SphMarkerDataD sphMarkersD)
protectedvirtual

Apply boundary to SPH markers (fluid and BCE).

The function applies periodic boundary to the markers.

virtual void chrono::fsi::ChFluidDynamics::DensityReinitialization ( )
virtual

Function to Shepard Filtering.

It calculates the densities directly, not based on the derivative of the density. This function is used in addition to the density update in UpdateFluid.

virtual void chrono::fsi::ChFluidDynamics::Finalize ( )
virtual

Synchronize the copy of the data (parameters and number of objects) between device (GPU) and host (CPU).

This function needs to be called once the host data are modified

virtual void chrono::fsi::ChFluidDynamics::IntegrateSPH ( SphMarkerDataD sphMarkersD2,
SphMarkerDataD sphMarkersD1,
FsiBodiesDataD fsiBodiesD1,
Real  dT 
)
virtual

Integrate the fluid system in time.

In a explicit scheme, to perform the integration, the force system calculates the forces between the particles. Then the forces are used to to update the markers position, velocity, and density in time, the latter is used to update the pressure from an equation of state. In the implicit scheme, the pressures are updated instead of density.

virtual void chrono::fsi::ChFluidDynamics::UpdateFluid ( SphMarkerDataD sphMarkersD,
Real  dT 
)
protectedvirtual

Update SPH markers data.

In an explicit formulation, the update Fluid function relies on explicit Euler Integration argorithm.