TransFlow
0.1.0
A transient pipeline flow simulation library
|
A class for calculating the time development of the gas composition from the gas velocity. More...
#include <batchtracking.hpp>
Public Member Functions | |
~BatchTracking () | |
Declared to avoid the inline compiler-generated default destructor. | |
Static Public Member Functions | |
static BatchTrackingState | advect (const BatchTrackingState &state, const arma::uword dt, const Pipeline &pipeline, const BoundaryConditions &boundaryConditions) |
A wrapper around BatchTracking::advect(const BatchTrackingState&, const double, const arma::mat&, const arma::vec&) More... | |
static BatchTrackingState | advect (const BatchTrackingState &state, const arma::uword dt, const arma::mat &inletAndOutletConcentration, const arma::vec &velocity) |
Calculate new Batch positions from gas velocity. More... | |
A class for calculating the time development of the gas composition from the gas velocity.
This class implements "batch tracking", which is a method for calculating the time development of the gas composition. This is done by setting up "batches" of gas with a given composition, and advancing each batch according to the gas velocity around each batch.
The batch tracking procedure is documented in Gas composition tracking in transient pipeline flow (Chaczykowski et. al., Journal of Natural Gas Science and Engineering 2018).
|
static |
Calculate new Batch positions from gas velocity.
This is the main advection function, which performs the calculations (all other advect functions are just wrappers around this one).
Advection is performed by translating each Batch according to the velocity of the gas around each Batch.
The batch tracking procedure is documented in Gas composition tracking in transient pipeline flow (Chaczykowski et. al., Journal of Natural Gas Science and Engineering 2018).
state | The current state, the positions and concentrations of all batches. |
dt | Time step [s]. |
inletAndOutletConcentration | Inlet and outlet concentration as column vectors. |
velocity | The velocity in the pipeline. |
|
static |
A wrapper around BatchTracking::advect(const BatchTrackingState&, const double, const arma::mat&, const arma::vec&)
dt | Time step [s]. |
state | BatchTrackingState to advect |
pipeline | Instance of Pipeline containing the current Pipeline state. Will get velocity from this. |
boundaryConditions | Boundary conditions. |