physics.hpp
#ifndef PHYSICS_HPP
#define PHYSICS_HPP
class Model{
public:
virtual double s(double)=0;
virtual double ds(double)=0;
virtual double kr(double)=0;
virtual double dkr(double)=0;
};
class ModelBC{
public:
double s(double);
double ds(double);
double kr(double);
double dkr(double);
};
class Physics{
public:
double g;
double rho;
double phi;
double k0;
double nivrivsat;
double (*s)(double);
double (*ds)(double);
void (*s_ds)(double,double&,double&);
double (*kr)(double);
double (*dkr)(double);
void (*kr_dkr)(double,double&,double&);
//---------------------
// Models descriptions
//---------------------
double model_datas[6];
//------------------------
// Brooks and Corey model
//------------------------
double s_BC(double P);
double ds_BC(double P);
void (s_ds_BC)(double P,double& v,double& dv);
double kr_BC(double P);
double dkr_BC(double P);
void (kr_dkr_BC)(double P,double& v,double& dv);
};
#endif
Physics::s
double(* s)(double)
Return the saturation in function of the pressure.
Definition: physics.hpp:42
Physics
The Physics class contains all physical parameters characterising the soil.
Definition: physics.hpp:24
Physics::s_ds_BC
void() s_ds_BC(double P, double &v, double &dv)
Brooks and Corey saturation and its derivative setter.
Physics::s_ds
void(* s_ds)(double, double &, double &)
Set the saturation and its derivative in function of the pressure.
Definition: physics.hpp:46
Physics::k0
double k0
Conductivity of the saturated soil.
Definition: physics.hpp:35
Physics::phi
double phi
Porosity of the soil.
Definition: physics.hpp:33
Physics::ds_BC
double ds_BC(double P)
Brooks and Corey derivative of the saturation map.
Physics::ds
double(* ds)(double)
Return the derivtive of the saturation in function of the pressure.
Definition: physics.hpp:44
Physics::kr
double(* kr)(double)
Return the relative conductivity in function of the pressure.
Definition: physics.hpp:49
Physics::kr_dkr_BC
void() kr_dkr_BC(double P, double &v, double &dv)
Brooks and Corey relative conductivity and its derivative setter.
Physics::dkr_BC
double dkr_BC(double P)
Brooks and Corey derivative of the relative conductivity map.
Physics::rho
double rho
Fluid density.
Definition: physics.hpp:30
Model
Definition: physics.hpp:4
Physics::kr_BC
double kr_BC(double P)
Brooks and Corey relative conductivity map.
Physics::model_datas
double model_datas[6]
Datas used to define the model.
Definition: physics.hpp:61
Physics::g
double g
Gravity acceleration.
Definition: physics.hpp:28
Physics::nivrivsat
double nivrivsat
Characterise the water pressure at the bottom of the overland water.
Definition: physics.hpp:38
Physics::s_BC
double s_BC(double P)
Brooks and Corey saturation map.
Physics::dkr
double(* dkr)(double)
Return the derivtive of the relative conductivity in function of the pressure.
Definition: physics.hpp:51
Physics::kr_dkr
void(* kr_dkr)(double, double &, double &)
Set the relative conductivity and its derivative in function of the pressure.
Definition: physics.hpp:53
ModelBC
Definition: physics.hpp:14