TransFlow
0.1.0
A transient pipeline flow simulation library
|
71 const arma::uword nGridPoints,
72 const arma::uword nEquationsAndVariables,
74 const arma::cube& term_i,
75 const arma::cube& term_ipp,
76 const arma::mat& boundaryTerms);
93 const arma::uword nGridPoints,
94 const arma::uword nEquationsAndVariables,
125 const arma::uword nGridPoints,
126 const arma::uword nVariables)
const;
The MatrixEquation class sets up the matrix equation from the system of equations found from the gove...
Definition: matrixequation.hpp:36
arma::mat solve(const arma::uword nGridPoints, const arma::uword nEquationsAndVariables, const BoundaryConditions &boundaryConditions) const
Solve the matrix equation Ax = b.
arma::vec m_constants
Constants vector b.
Definition: matrixequation.hpp:104
void fillCoefficientMatrixAndConstantsVector(const arma::uword nGridPoints, const arma::uword nEquationsAndVariables, const BoundaryConditions &boundaryConditions, const arma::cube &term_i, const arma::cube &term_ipp, const arma::mat &boundaryTerms)
Fill in the coefficient matrix A (MatrixEquation::m_coefficients) and constants vector b (MatrixEquat...
arma::vec solveMatrixEquation() const
Internal method that solves the matrix equation.
const arma::sp_mat & coefficients() const
Get coefficient matrix A. For testing purposes.
Definition: matrixequation.hpp:98
arma::mat reshapeSolverOutput(const arma::vec &x, const BoundaryConditions &boundaryConditions, const arma::uword nGridPoints, const arma::uword nVariables) const
Reshape output from solving the matrix equation into a matrix containing flow, pressure and temperatu...
const arma::vec & constants() const
Get constants vector b. For testing purposes.
Definition: matrixequation.hpp:100
arma::sp_mat m_coefficients
Coefficient matrix A.
Definition: matrixequation.hpp:103
The BoundaryConditions class is a container for the boundary conditions at the inlet and outlet of a ...
Definition: boundaryconditions.hpp:27
~MatrixEquation()
Declared to avoid the inline compiler-generated default destructor.