OGS
ProcessLib::TH2M::ConstitutiveRelations::DiffusionVelocityModel< DisplacementDim > Struct Template Reference

Detailed Description

template<int DisplacementDim>
struct ProcessLib::TH2M::ConstitutiveRelations::DiffusionVelocityModel< DisplacementDim >

Definition at line 47 of file DiffusionVelocity.h.

#include <DiffusionVelocity.h>

Public Member Functions

void eval (CapillaryPressureGradientData< DisplacementDim > const &grad_p_cap, GasPressureGradientData< DisplacementDim > const &grad_p_GR, MassMoleFractionsData const &mass_mole_fractions_data, PhaseTransitionData const &phase_transition_data, PorosityData const &porosity_data, SaturationData const &S_L_data, TemperatureGradientData< DisplacementDim > const &grad_T, DiffusionVelocityData< DisplacementDim > &diffusion_velocity_data) const
 

Member Function Documentation

◆ eval()

template<int DisplacementDim>
void ProcessLib::TH2M::ConstitutiveRelations::DiffusionVelocityModel< DisplacementDim >::eval ( CapillaryPressureGradientData< DisplacementDim > const & grad_p_cap,
GasPressureGradientData< DisplacementDim > const & grad_p_GR,
MassMoleFractionsData const & mass_mole_fractions_data,
PhaseTransitionData const & phase_transition_data,
PorosityData const & porosity_data,
SaturationData const & S_L_data,
TemperatureGradientData< DisplacementDim > const & grad_T,
DiffusionVelocityData< DisplacementDim > & diffusion_velocity_data ) const

Definition at line 17 of file DiffusionVelocity.cpp.

26{
27 auto const gradxmWG = phase_transition_data.dxmWG_dpGR * grad_p_GR() +
28 phase_transition_data.dxmWG_dpCap * grad_p_cap() +
29 phase_transition_data.dxmWG_dT * grad_T();
30 auto const gradxmCG = -gradxmWG;
31
32 auto const gradxmWL = phase_transition_data.dxmWL_dpGR * grad_p_GR() +
33 phase_transition_data.dxmWL_dpCap * grad_p_cap() +
34 phase_transition_data.dxmWL_dT * grad_T();
35 auto const gradxmCL = -gradxmWL;
36
37 double const phi_L = S_L_data.S_L * porosity_data.phi;
38 double const phi_G = (1. - S_L_data.S_L) * porosity_data.phi;
39
40 double const phi_G_D_vapour =
41 phi_G * phase_transition_data.diffusion_coefficient_vapour;
42 double const phi_L_D_solute =
43 phi_L * phase_transition_data.diffusion_coefficient_solute;
44
45 if (mass_mole_fractions_data.xmCG == 0)
46 {
47 diffusion_velocity_data.d_CG = GlobalDimVector<DisplacementDim>::Zero();
48 }
49 else
50 {
51 diffusion_velocity_data.d_CG =
52 -phi_G_D_vapour / mass_mole_fractions_data.xmCG * gradxmCG;
53 }
54
55 if (mass_mole_fractions_data.xmCG == 1)
56 {
57 diffusion_velocity_data.d_WG = GlobalDimVector<DisplacementDim>::Zero();
58 }
59 else
60 {
61 diffusion_velocity_data.d_WG =
62 -phi_G_D_vapour / (1 - mass_mole_fractions_data.xmCG) * gradxmWG;
63 }
64
65 if (mass_mole_fractions_data.xmWL == 1)
66
67 {
68 diffusion_velocity_data.d_CL = GlobalDimVector<DisplacementDim>::Zero();
69 }
70 else
71 {
72 diffusion_velocity_data.d_CL =
73 -phi_L_D_solute / (1. - mass_mole_fractions_data.xmWL) * gradxmCL;
74 }
75
76 if (mass_mole_fractions_data.xmWL == 0)
77 {
78 diffusion_velocity_data.d_WL = GlobalDimVector<DisplacementDim>::Zero();
79 }
80 else
81 {
82 diffusion_velocity_data.d_WL =
83 -phi_L_D_solute / mass_mole_fractions_data.xmWL * gradxmWL;
84 }
85}

References ProcessLib::TH2M::ConstitutiveRelations::DiffusionVelocityData< DisplacementDim >::d_CG, ProcessLib::TH2M::ConstitutiveRelations::DiffusionVelocityData< DisplacementDim >::d_CL, ProcessLib::TH2M::ConstitutiveRelations::DiffusionVelocityData< DisplacementDim >::d_WG, ProcessLib::TH2M::ConstitutiveRelations::DiffusionVelocityData< DisplacementDim >::d_WL, ProcessLib::TH2M::ConstitutiveRelations::PhaseTransitionData::diffusion_coefficient_solute, ProcessLib::TH2M::ConstitutiveRelations::PhaseTransitionData::diffusion_coefficient_vapour, ProcessLib::TH2M::ConstitutiveRelations::PhaseTransitionData::dxmWG_dpCap, ProcessLib::TH2M::ConstitutiveRelations::PhaseTransitionData::dxmWG_dpGR, ProcessLib::TH2M::ConstitutiveRelations::PhaseTransitionData::dxmWG_dT, ProcessLib::TH2M::ConstitutiveRelations::PhaseTransitionData::dxmWL_dpCap, ProcessLib::TH2M::ConstitutiveRelations::PhaseTransitionData::dxmWL_dpGR, ProcessLib::TH2M::ConstitutiveRelations::PhaseTransitionData::dxmWL_dT, ProcessLib::TH2M::ConstitutiveRelations::PorosityData::phi, ProcessLib::TH2M::ConstitutiveRelations::SaturationData::S_L, ProcessLib::TH2M::ConstitutiveRelations::MassMoleFractionsData::xmCG, and ProcessLib::TH2M::ConstitutiveRelations::MassMoleFractionsData::xmWL.


The documentation for this struct was generated from the following files: