OpenCAEPoro  0.2.0 Sep/22/2022
A simulator for multicomponent porous media flow
IsothermalSolver.hpp
Go to the documentation of this file.
1 
12 #ifndef __FLUIDSOLVER_HEADER__
13 #define __FLUIDSOLVER_HEADER__
14 
15 // OpenCAEPoro header files
16 #include "OCPFluidMethod.hpp"
17 
20 {
21 public:
23  void SetupMethod(Reservoir& rs, const OCPControl& ctrl);
25  void InitReservoir(Reservoir& rs) const;
27  void Prepare(Reservoir& rs, OCP_DBL& dt);
29  void AssembleMat(const Reservoir& rs, const OCP_DBL& dt);
31  void SolveLinearSystem(Reservoir& rs, OCPControl& ctrl);
33  bool UpdateProperty(Reservoir& rs, OCPControl& ctrl);
35  bool FinishNR(Reservoir& rs, OCPControl& ctrl);
37  void FinishStep(Reservoir& rs, OCPControl& ctrl);
38 
39 private:
40  USI method = FIM;
41  LinearSystem LSolver;
42  LinearSystem auxLSolver;
43  OCP_IMPEC impec;
44  OCP_FIM fim;
45  OCP_FIMn fim_n;
46  OCP_AIMc aimc;
47  OCP_AIMs aims;
48  OCP_AIMt aimt;
49 };
50 
51 #endif /* end if __FLUIDSOLVER_HEADER__ */
52 
53 /*----------------------------------------------------------------------------*/
54 /* Brief Change History of This File */
55 /*----------------------------------------------------------------------------*/
56 /* Author Date Actions */
57 /*----------------------------------------------------------------------------*/
58 /* Shizhe Li Oct/21/2021 Create file */
59 /* Chensong Zhang Jan/16/2022 Update Doxygen */
60 /*----------------------------------------------------------------------------*/
unsigned int USI
Generic unsigned integer.
Definition: OCPConst.hpp:22
double OCP_DBL
Double precision.
Definition: OCPConst.hpp:26
const USI FIM
Solution method = FIM.
Definition: OCPConst.hpp:71
Declaration of solution methods for fluid part in OpenCAEPoro.
IsothermalSolver class for fluid solution method.
void SolveLinearSystem(Reservoir &rs, OCPControl &ctrl)
Solve the linear system in single problem.
void InitReservoir(Reservoir &rs) const
Initialize the Reservoir and prepare variables for some method.
void SetupMethod(Reservoir &rs, const OCPControl &ctrl)
Setup the fluid solver.
bool UpdateProperty(Reservoir &rs, OCPControl &ctrl)
Update properties of fluid.
bool FinishNR(Reservoir &rs, OCPControl &ctrl)
Finish the Newton-Raphson iteration.
void FinishStep(Reservoir &rs, OCPControl &ctrl)
Finish the current time step.
void AssembleMat(const Reservoir &rs, const OCP_DBL &dt)
Assemble Mat.
void Prepare(Reservoir &rs, OCP_DBL &dt)
Prepare for assembling Mat.
Linear solvers for discrete systems.
All control parameters except for well controlers.
Definition: OCPControl.hpp:94
perform AIM in space, that is, some grids will be implicit, others will be explicit at the same time ...
perform AIM in time, that is, local FIM will be performed after global IMPEC performs
OCP_FIM is FIM (Fully Implicit Method).
OCP_IMPEC is IMPEC (implict pressure explict saturation) method.