NuTo
Numerics Tool
Functions | Variables
MultiPhysics2D.cpp File Reference
#include <fstream>
#include <sys/stat.h>
#include <sys/time.h>
#include <boost/progress.hpp>
#include <nuto/math/SparseMatrixCSRGeneral.h>
#include <nuto/mechanics/constitutive/multiPhysics/ConstitutiveStaticDataMultiPhysics.h>
#include <nuto/mechanics/constitutive/moistureTransport/ConstitutiveStaticDataMoistureTransport.h>
#include <nuto/mechanics/nodes/NodeDof.h>
#include <nuto/mechanics/nodes/NodeCoordinates.h>
#include <nuto/mechanics/structures/unstructured/Structure.h>
#include "nuto/mechanics/timeIntegration/CrankNicolsonEvaluate.h"
#include <nuto/metamodel/PolynomialLeastSquaresFitting.h>
#include <nuto/mechanics/structures/StructureOutputFullVectorDouble.h>
#include <nuto/mechanics/structures/StructureOutputSparseMatrix.h>

Functions

 std::cout<< "Solver not available - can't solve system of equations "<< std::endl;int main(){try{bool EnableSorptionHysteresis=false;bool EnableModiefiedTangentialStiffness=false;unsigned int NNodes;double Length=0.16;double Height=0.04;unsigned int NumElementsX=32;unsigned int NumElementsY=8;double ElementLength=Length/static_cast< double > (NumElementsX)
 
NuTo::FullVector< double, Eigen::Dynamic > x_Values_Ad ({0.1, 0.2, 0.3, 0.4, 0.5, 0.6, 0.7, 0.8, 0.9})
 
NuTo::FullVector< double, Eigen::Dynamic > y_Values_Ad ({0.017, 0.03, 0.04, 0.048, 0.056, 0.066, 0.077, 0.092, 0.114})
 
NuTo::FullVector< double, Eigen::Dynamic > x_Values_De ({0.1, 0.2, 0.3, 0.4, 0.5, 0.6, 0.7, 0.8, 0.9})
 
NuTo::FullVector< double, Eigen::Dynamic > y_Values_De ({0.022, 0.039, 0.052, 0.062, 0.072, 0.083, 0.097, 0.118, 0.145})
 
AdsorptionFit SetSupportPoints (1, 1, x_Values_Ad.Trans(), y_Values_Ad.Trans())
 
AdsorptionFit SetDegree (3)
 
AdsorptionFit AddBoundaryCondition (0.0, 0.0)
 
AdsorptionFit AddBoundaryCondition (1.0, 0.141)
 
AdsorptionFit BuildDerived ()
 
DesorptionFit SetSupportPoints (1, 1, x_Values_De.Trans(), y_Values_De.Trans())
 
NuTo::Structure myStructure (2)
 
myStructure SetNumTimeDerivatives (2)
 
myStructure SetShowTime (false)
 
myStructure UseMaximumIndependentSets (true)
 
myStructure SectionSetThickness (mySection, Thickness)
 
myStructure ElementTotalSetSection (mySection)
 
myStructure ConstitutiveLawMultiPhysicsAddConstitutiveLaw (ConstLawMultiPhysics, ConstLawDryingShrinkage)
 
myStructure ConstitutiveLawMultiPhysicsAddConstitutiveLaw (ConstLawMultiPhysics, ConstLawLinearElastic)
 
myStructure ConstitutiveLawMultiPhysicsAddConstitutiveLaw (ConstLawMultiPhysics, ConstLawMoistureTransport)
 
myStructure ConstitutiveLawSetParameterDouble (ConstLawMultiPhysics, NuTo::Constitutive::eConstitutiveParameter::YOUNGS_MODULUS, YoungsModulus)
 
myStructure ConstitutiveLawSetParameterDouble (ConstLawMultiPhysics, NuTo::Constitutive::eConstitutiveParameter::POISSONS_RATIO, PoissonRatio)
 
myStructure ConstitutiveLawSetParameterDouble (ConstLawMultiPhysics, NuTo::Constitutive::eConstitutiveParameter::DENSITY, Density)
 
myStructure ConstitutiveLawSetParameterBool (ConstLawMultiPhysics,"ENABLE_MODIFIED_TANGENTIAL_STIFFNESS", EnableModiefiedTangentialStiffness)
 
myStructure ConstitutiveLawSetParameterBool (ConstLawMultiPhysics,"enable_sorption_hysteresis", EnableSorptionHysteresis)
 
myStructure ConstitutiveLawSetParameterDouble (ConstLawMultiPhysics,"boundary_TRANSPORT_CONSTANT_GAS_PHASE", BC_Surface_Moisture_Transfer_RH)
 
myStructure ConstitutiveLawSetParameterDouble (ConstLawMultiPhysics,"BOUNDARY_TRANSPORT_CONSTANT_WATER_PHASE", BC_Surface_Moisture_Transfer_WVF)
 
myStructure ConstitutiveLawSetParameterDouble (ConstLawMultiPhysics,"DENSITY_WATER_PHASE", WaterPhaseDensity)
 
myStructure ConstitutiveLawSetParameterDouble (ConstLawMultiPhysics,"DIFFUSION_CONSTANT_GAS_PHASE", VaporPhaseDiffusionCoefficient)
 
myStructure ConstitutiveLawSetParameterDouble (ConstLawMultiPhysics,"DIFFUSION_CONSTANT_WATER_PHASE", WaterPhaseDiffusionCoefficient)
 
myStructure ConstitutiveLawSetParameterDouble (ConstLawMultiPhysics,"DIFFUSION_EXPONENT_GAS_PHASE", VaporPhaseDiffusionExponent)
 
myStructure ConstitutiveLawSetParameterDouble (ConstLawMultiPhysics,"DIFFUSION_EXPONENT_WATER_PHASE", WaterPhaseDiffusionExponent)
 
myStructure ConstitutiveLawSetParameterDouble (ConstLawMultiPhysics,"GRADIENT_CORRECTION_ADSORPTION_DESORPTION", Kd)
 
myStructure ConstitutiveLawSetParameterDouble (ConstLawMultiPhysics,"GRADIENT_CORRECTION_DESORPTION_ADSORPTION", Ka)
 
myStructure ConstitutiveLawSetParameterDouble (ConstLawMultiPhysics,"MASS_EXCHANGE_RATE", MassExchangeRate)
 
myStructure ConstitutiveLawSetParameterDouble (ConstLawMultiPhysics,"POROSITY", Porosity)
 
myStructure ConstitutiveLawSetParameterDouble (ConstLawMultiPhysics,"SATURATION_DENSITY_GAS_PHASE", VaporPhaseSaturationDensity)
 
myStructure ConstitutiveLawSetParameterFullVectorDouble (ConstLawMultiPhysics,"polynomial_COEFFICIENTS_ADSORPTION", AdsorptionFit.GetPolynomialCoefficients())
 
myStructure ConstitutiveLawSetParameterFullVectorDouble (ConstLawMultiPhysics,"POLYNOMIAL_COEFFICIENTS_DESORPTION", DesorptionFit.GetPolynomialCoefficients())
 
int NodeNum (0)
 
NuTo::FullVector< double, Eigen::Dynamic > Coordinates (2)
 
 for (unsigned int iY=0;iY< NumNodesY;iY++)
 
myStructure InterpolationTypeAdd (myInterpolationType, NuTo::Node::COORDINATES, NuTo::Interpolation::eTypeOrder::EQUIDISTANT1)
 
myStructure InterpolationTypeAdd (myInterpolationType, NuTo::Node::DISPLACEMENTS, NuTo::Interpolation::eTypeOrder::EQUIDISTANT1)
 
myStructure InterpolationTypeAdd (myInterpolationType, NuTo::Node::RELATIVEHUMIDITY, NuTo::Interpolation::eTypeOrder::EQUIDISTANT1)
 
myStructure InterpolationTypeAdd (myInterpolationType, NuTo::Node::WATERVOLUMEFRACTION, NuTo::Interpolation::eTypeOrder::EQUIDISTANT1)
 
NuTo::FullVector< int, Eigen::Dynamic > Nodes (4)
 
myStructure ElementTotalConvertToInterpolationType ()
 
myStructure GroupAddNodeCoordinateRange (GRPNodes_Left, Direction, Min, Max)
 
myStructure GroupAddNodeCoordinateRange (GRPNodes_Right, Direction, Min, Max)
 
myStructure GroupAddNodeFunction (GRPNodes_Center, PickNodeFunction)
 
myStructure GroupAddNodeFunction (GRPNodes_SingleNodeLeft, PickSingleNodeLeftFunction)
 
myStructure GroupAddNodeFunction (GRPNodes_SingleNodeRight, PickSingleNodeRightFunction)
 
myStructure GroupAddNodeFunction (nodeGroupBoundary, GetBoundaryNodesLambda)
 
myStructure GroupAddElementsFromNodes (elemGroupBoundary, nodeGroupBoundary, false)
 
myStructure BoundaryElementsCreate (elemGroupBoundary, nodeGroupBoundary, myStructure.NodeGetNodePtr(BoundaryNodeID))
 
NuTo::FullMatrix< double, Eigen::Dynamic, Eigen::Dynamic > DirectionX (2, 1)
 
DirectionX SetValue (0, 0, 1.0)
 
NuTo::FullMatrix< double, Eigen::Dynamic, Eigen::Dynamic > DirectionY (2, 1)
 
DirectionY SetValue (1, 0, 1.0)
 
myStructure ConstraintLinearSetDisplacementNodeGroup (GRPNodes_SingleNodeLeft, DirectionX, 0)
 
myStructure ConstraintLinearSetDisplacementNodeGroup (GRPNodes_SingleNodeLeft, DirectionY, 0)
 
myStructure ConstraintLinearSetDisplacementNodeGroup (GRPNodes_SingleNodeRight, DirectionY, 0)
 
myStructure SetNumProcessors (1)
 
myStructure CalculateMaximumIndependentSets ()
 
myStructure NodeBuildGlobalDofs ()
 

Variables

unsigned int NumNodesX = NumElementsX + 1
 
unsigned int NumNodesY = NumElementsY + 1
 
double Thickness = 0.04
 
double delta_t = 1.0 / 1.0 * 1.0 * 24.0 * 60.0 * 60.0
 
double SimulationTime = 1.0 / 1.0 * 1.0 * 24.0 * 60.0 * 60.0
 
double BC_TransitionTime = 24.0 * 60.0 * 60.0
 
double InitialRelativeHumidity = 0.95
 
double InitialWaterVolumeFraction = 0.03
 
double Density = 1.0
 
double PoissonRatio = 0.15
 
double YoungsModulus = 30.0 * 10e9
 
double MassExchangeRate = 3.42e-7
 
double Porosity = 0.25
 
double VaporPhaseDiffusionCoefficient = 3.9e-12
 
double VaporPhaseDiffusionExponent = 1.0
 
double VaporPhaseSaturationDensity = 0.0173
 
double WaterPhaseDensity = 999.97
 
double WaterPhaseDiffusionCoefficient = 1.17e-7
 
double WaterPhaseDiffusionExponent = 2.0
 
double BC_RelativeHumidity = 0.15
 
double BC_Surface_Moisture_Transfer_RH = 1.0e-10 * delta_t
 
double BC_Surface_Moisture_Transfer_WVF = 1.0e-7 * delta_t
 
bool SorptionHistoryDesorption = true
 
double Ka = 0.26
 
double Kd = 0.56
 
NuTo::PolynomialLeastSquaresFitting AdsorptionFit
 
NuTo::PolynomialLeastSquaresFitting DesorptionFit
 
double MaxResidual = 1.0e-6
 
int mySection = myStructure.SectionCreate("Plane_Stress")
 
int ConstLawDryingShrinkage = myStructure.ConstitutiveLawCreate("DryingShrinkage")
 
int ConstLawLinearElastic = myStructure.ConstitutiveLawCreate("LinearElasticEngineeringStress")
 
int ConstLawMoistureTransport = myStructure.ConstitutiveLawCreate("MoistureTransport")
 
int ConstLawMultiPhysics = myStructure.ConstitutiveLawCreate("MultiPhysics")
 
double DeltaX = Length / (NumNodesX - 1)
 
double DeltaY = Height / (NumNodesY - 1)
 
int myInterpolationType = myStructure.InterpolationTypeCreate("Quad2D")
 
 NNodes = myStructure.GetNumNodes()
 
int GRPNodes_Left = myStructure.GroupCreate("Nodes")
 
int Direction = 0
 
double Min = 0. - 0.01 * ElementLength
 
double Max = 0. + 0.01 * ElementLength
 
int GRPNodes_Right = myStructure.GroupCreate("Nodes")
 
auto PickNodeFunction
 
int GRPNodes_Center = myStructure.GroupCreate("Nodes")
 
auto PickSingleNodeLeftFunction
 
int GRPNodes_SingleNodeLeft = myStructure.GroupCreate("Nodes")
 
auto PickSingleNodeRightFunction
 
int GRPNodes_SingleNodeRight = myStructure.GroupCreate("Nodes")
 
int nodeGroupBoundary = myStructure.GroupCreate("NODES")
 
auto GetBoundaryNodesLambda
 
int elemGroupBoundary = myStructure.GroupCreate("ELEMENTS")
 
int BoundaryNodeID = myStructure.NodeCreateDOFs("RELATIVEHUMIDITY")
 
auto RelativeHumidityFunc
 
int BoundaryConstraint = myStructure.ConstraintLinearSetRelativeHumidityNode(BoundaryNodeID, 1.0)
 

Function Documentation

DesorptionFit AddBoundaryCondition ( 0.  0,
0.  0 
)
DesorptionFit AddBoundaryCondition ( 1.  0,
0.  141 
)
myStructure BoundaryElementsCreate ( elemGroupBoundary  ,
nodeGroupBoundary  ,
myStructure.  NodeGetNodePtrBoundaryNodeID 
)
DesorptionFit BuildDerived ( )
myStructure CalculateMaximumIndependentSets ( )
myStructure ConstitutiveLawMultiPhysicsAddConstitutiveLaw ( ConstLawMultiPhysics  ,
ConstLawDryingShrinkage   
)
myStructure ConstitutiveLawMultiPhysicsAddConstitutiveLaw ( ConstLawMultiPhysics  ,
ConstLawLinearElastic   
)
myStructure ConstitutiveLawMultiPhysicsAddConstitutiveLaw ( ConstLawMultiPhysics  ,
ConstLawMoistureTransport   
)
myStructure ConstitutiveLawSetParameterBool ( ConstLawMultiPhysics  ,
"ENABLE_MODIFIED_TANGENTIAL_STIFFNESS"  ,
EnableModiefiedTangentialStiffness   
)
myStructure ConstitutiveLawSetParameterBool ( ConstLawMultiPhysics  ,
"enable_sorption_hysteresis"  ,
EnableSorptionHysteresis   
)
myStructure ConstitutiveLawSetParameterDouble ( ConstLawMultiPhysics  ,
NuTo::Constitutive::eConstitutiveParameter::YOUNGS_MODULUS  ,
YoungsModulus   
)
myStructure ConstitutiveLawSetParameterDouble ( ConstLawMultiPhysics  ,
NuTo::Constitutive::eConstitutiveParameter::POISSONS_RATIO  ,
PoissonRatio   
)
myStructure ConstitutiveLawSetParameterDouble ( ConstLawMultiPhysics  ,
NuTo::Constitutive::eConstitutiveParameter::DENSITY  ,
Density   
)
myStructure ConstitutiveLawSetParameterDouble ( ConstLawMultiPhysics  ,
"boundary_TRANSPORT_CONSTANT_GAS_PHASE"  ,
BC_Surface_Moisture_Transfer_RH   
)
myStructure ConstitutiveLawSetParameterDouble ( ConstLawMultiPhysics  ,
"BOUNDARY_TRANSPORT_CONSTANT_WATER_PHASE"  ,
BC_Surface_Moisture_Transfer_WVF   
)
myStructure ConstitutiveLawSetParameterDouble ( ConstLawMultiPhysics  ,
"DENSITY_WATER_PHASE"  ,
WaterPhaseDensity   
)
myStructure ConstitutiveLawSetParameterDouble ( ConstLawMultiPhysics  ,
"DIFFUSION_CONSTANT_GAS_PHASE"  ,
VaporPhaseDiffusionCoefficient   
)
myStructure ConstitutiveLawSetParameterDouble ( ConstLawMultiPhysics  ,
"DIFFUSION_CONSTANT_WATER_PHASE"  ,
WaterPhaseDiffusionCoefficient   
)
myStructure ConstitutiveLawSetParameterDouble ( ConstLawMultiPhysics  ,
"DIFFUSION_EXPONENT_GAS_PHASE"  ,
VaporPhaseDiffusionExponent   
)
myStructure ConstitutiveLawSetParameterDouble ( ConstLawMultiPhysics  ,
"DIFFUSION_EXPONENT_WATER_PHASE"  ,
WaterPhaseDiffusionExponent   
)
myStructure ConstitutiveLawSetParameterDouble ( ConstLawMultiPhysics  ,
"GRADIENT_CORRECTION_ADSORPTION_DESORPTION"  ,
Kd   
)
myStructure ConstitutiveLawSetParameterDouble ( ConstLawMultiPhysics  ,
"GRADIENT_CORRECTION_DESORPTION_ADSORPTION"  ,
Ka   
)
myStructure ConstitutiveLawSetParameterDouble ( ConstLawMultiPhysics  ,
"MASS_EXCHANGE_RATE"  ,
MassExchangeRate   
)
myStructure ConstitutiveLawSetParameterDouble ( ConstLawMultiPhysics  ,
"POROSITY"  ,
Porosity   
)
myStructure ConstitutiveLawSetParameterDouble ( ConstLawMultiPhysics  ,
"SATURATION_DENSITY_GAS_PHASE"  ,
VaporPhaseSaturationDensity   
)
myStructure ConstitutiveLawSetParameterFullVectorDouble ( ConstLawMultiPhysics  ,
"polynomial_COEFFICIENTS_ADSORPTION"  ,
AdsorptionFit.  GetPolynomialCoefficients() 
)
myStructure ConstitutiveLawSetParameterFullVectorDouble ( ConstLawMultiPhysics  ,
"POLYNOMIAL_COEFFICIENTS_DESORPTION"  ,
DesorptionFit.  GetPolynomialCoefficients() 
)
myStructure ConstraintLinearSetDisplacementNodeGroup ( GRPNodes_SingleNodeLeft  ,
DirectionX  ,
 
)
myStructure ConstraintLinearSetDisplacementNodeGroup ( GRPNodes_SingleNodeLeft  ,
DirectionY  ,
 
)
myStructure ConstraintLinearSetDisplacementNodeGroup ( GRPNodes_SingleNodeRight  ,
DirectionY  ,
 
)
NuTo::FullVector<double, Eigen::Dynamic> Coordinates ( )
NuTo::FullMatrix<double, Eigen::Dynamic, Eigen::Dynamic> DirectionX ( ,
 
)
NuTo::FullMatrix<double, Eigen::Dynamic, Eigen::Dynamic> DirectionY ( ,
 
)
myStructure ElementTotalConvertToInterpolationType ( )
myStructure ElementTotalSetSection ( mySection  )
for ( )
myStructure GroupAddElementsFromNodes ( elemGroupBoundary  ,
nodeGroupBoundary  ,
false   
)
myStructure GroupAddNodeCoordinateRange ( GRPNodes_Left  ,
Direction  ,
Min  ,
Max   
)
myStructure GroupAddNodeCoordinateRange ( GRPNodes_Right  ,
Direction  ,
Min  ,
Max   
)
myStructure GroupAddNodeFunction ( GRPNodes_Center  ,
PickNodeFunction   
)
myStructure GroupAddNodeFunction ( nodeGroupBoundary  ,
GetBoundaryNodesLambda   
)
myStructure InterpolationTypeAdd ( myInterpolationType  ,
NuTo::Node::COORDINATES  ,
NuTo::Interpolation::eTypeOrder::EQUIDISTANT1   
)
myStructure InterpolationTypeAdd ( myInterpolationType  ,
NuTo::Node::DISPLACEMENTS  ,
NuTo::Interpolation::eTypeOrder::EQUIDISTANT1   
)
myStructure InterpolationTypeAdd ( myInterpolationType  ,
NuTo::Node::RELATIVEHUMIDITY  ,
NuTo::Interpolation::eTypeOrder::EQUIDISTANT1   
)
myStructure InterpolationTypeAdd ( myInterpolationType  ,
NuTo::Node::WATERVOLUMEFRACTION  ,
NuTo::Interpolation::eTypeOrder::EQUIDISTANT1   
)
NuTo::Structure myStructure ( )
myStructure NodeBuildGlobalDofs ( )
int NodeNum ( )
NuTo::FullVector<int, Eigen::Dynamic> Nodes ( )
myStructure SectionSetThickness ( mySection  ,
Thickness   
)
DesorptionFit SetDegree ( )
myStructure SetNumProcessors ( )
myStructure SetNumTimeDerivatives ( )
myStructure SetShowTime ( false  )
AdsorptionFit SetSupportPoints ( ,
,
x_Values_Ad.  Trans(),
y_Values_Ad.  Trans() 
)
DesorptionFit SetSupportPoints ( ,
,
x_Values_De.  Trans(),
y_Values_De.  Trans() 
)
DirectionX SetValue ( ,
,
1.  0 
)
DirectionY SetValue ( ,
,
1.  0 
)
std::cout<< "Solver not available - can't solve system of equations "<< std::endl;int main(){try{bool EnableSorptionHysteresis=false;bool EnableModiefiedTangentialStiffness=false;unsigned int NNodes;double Length=0.16;double Height=0.04;unsigned int NumElementsX=32;unsigned int NumElementsY=8;double ElementLength=Length/static_cast< double > ( NumElementsX  )
myStructure UseMaximumIndependentSets ( true  )
NuTo::FullVector<double, Eigen::Dynamic> x_Values_Ad ( {0.1, 0.2, 0.3, 0.4, 0.5, 0.6, 0.7, 0.8, 0.9}  )
NuTo::FullVector<double, Eigen::Dynamic> x_Values_De ( {0.1, 0.2, 0.3, 0.4, 0.5, 0.6, 0.7, 0.8, 0.9}  )
NuTo::FullVector<double, Eigen::Dynamic> y_Values_Ad ( {0.017, 0.03, 0.04, 0.048, 0.056, 0.066, 0.077, 0.092, 0.114}  )
NuTo::FullVector<double, Eigen::Dynamic> y_Values_De ( {0.022, 0.039, 0.052, 0.062, 0.072, 0.083, 0.097, 0.118, 0.145}  )

Variable Documentation

double BC_RelativeHumidity = 0.15
double BC_Surface_Moisture_Transfer_RH = 1.0e-10 * delta_t
double BC_Surface_Moisture_Transfer_WVF = 1.0e-7 * delta_t
double BC_TransitionTime = 24.0 * 60.0 * 60.0
int BoundaryConstraint = myStructure.ConstraintLinearSetRelativeHumidityNode(BoundaryNodeID, 1.0)
int BoundaryNodeID = myStructure.NodeCreateDOFs("RELATIVEHUMIDITY")
int ConstLawDryingShrinkage = myStructure.ConstitutiveLawCreate("DryingShrinkage")
int ConstLawLinearElastic = myStructure.ConstitutiveLawCreate("LinearElasticEngineeringStress")
int ConstLawMoistureTransport = myStructure.ConstitutiveLawCreate("MoistureTransport")
int ConstLawMultiPhysics = myStructure.ConstitutiveLawCreate("MultiPhysics")
double delta_t = 1.0 / 1.0 * 1.0 * 24.0 * 60.0 * 60.0
double DeltaX = Length / (NumNodesX - 1)
double DeltaY = Height / (NumNodesY - 1)
double Density = 1.0
Direction = 0
int elemGroupBoundary = myStructure.GroupCreate("ELEMENTS")
auto GetBoundaryNodesLambda
Initial value:
= [Length, Height](NuTo::NodeBase* rNodePtr) -> bool {
double Tol = 1.e-6;
if (rNodePtr->GetNum(Node::COORDINATES) > 0)
{
double x = rNodePtr->GetCoordinate(0);
double y = rNodePtr->GetCoordinate(1);
if ((x >= -Tol && x <= Tol) || (x >= Length - Tol && x <= Length + Tol) || (y >= -Tol && y <= Tol) ||
(y >= Height - Tol && y <= Height + Tol))
{
return true;
}
}
return false;
}
int GRPNodes_Center = myStructure.GroupCreate("Nodes")
int GRPNodes_Left = myStructure.GroupCreate("Nodes")
int GRPNodes_Right = myStructure.GroupCreate("Nodes")
int GRPNodes_SingleNodeLeft = myStructure.GroupCreate("Nodes")
int GRPNodes_SingleNodeRight = myStructure.GroupCreate("Nodes")
double InitialRelativeHumidity = 0.95
InitialWaterVolumeFraction = 0.03
double Ka = 0.26
double Kd = 0.56
double MassExchangeRate = 3.42e-7
Max = 0. + 0.01 * ElementLength
double MaxResidual = 1.0e-6
Min = 0. - 0.01 * ElementLength
int myInterpolationType = myStructure.InterpolationTypeCreate("Quad2D")
int mySection = myStructure.SectionCreate("Plane_Stress")
NNodes = myStructure.GetNumNodes()
int nodeGroupBoundary = myStructure.GroupCreate("NODES")
unsigned int NumNodesX = NumElementsX + 1
unsigned int NumNodesY = NumElementsY + 1
auto PickNodeFunction
Initial value:
= [Length, Height](NuTo::NodeBase* rNodePtr) -> bool {
if (rNodePtr->GetNum(Node::COORDINATES) > 0)
{
double x = rNodePtr->GetCoordinate(0);
double y = rNodePtr->GetCoordinate(1);
if (x >= Length / 2 - 0.1 && x <= Length / 2 + 0.1 && y >= Height / 2.0)
{
return true;
}
}
return false;
}
auto PickSingleNodeLeftFunction
Initial value:
= [Length, Height](NuTo::NodeBase* rNodePtr) -> bool {
if (rNodePtr->GetNum(Node::COORDINATES) > 0)
{
double x = rNodePtr->GetCoordinate(0);
double y = rNodePtr->GetCoordinate(1);
if (x >= -1e-6 && x <= 1e-6 && y >= Height / 2.0 - 1e-6 && y <= Height / 2.0 + 1e-6)
{
return true;
}
}
return false;
}
auto PickSingleNodeRightFunction
Initial value:
= [Length, Height](NuTo::NodeBase* rNodePtr) -> bool {
if (rNodePtr->GetNum(Node::COORDINATES) > 0)
{
double x = rNodePtr->GetCoordinate(0);
double y = rNodePtr->GetCoordinate(1);
if (x >= Length - 1e-6 && x <= Length + 1e-6 && y >= Height / 2.0 - 1e-6 && y <= Height / 2.0 + 1e-6)
{
return true;
}
}
return false;
}
double PoissonRatio = 0.15
double Porosity = 0.25
auto RelativeHumidityFunc
Initial value:
SimulationTime](double rTime) -> double {
if (rTime == 0.0)
{
}
else
{
if (rTime < BC_TransitionTime)
{
sin(rTime / BC_TransitionTime * 3.14 / 2.0) *
}
{
}
}
}
double BC_TransitionTime
Definition: MultiPhysics2D.cpp:70
double BC_RelativeHumidity
Definition: MultiPhysics2D.cpp:95
double InitialRelativeHumidity
Definition: MultiPhysics2D.cpp:73
double SimulationTime
Definition: MultiPhysics2D.cpp:69
double SimulationTime = 1.0 / 1.0 * 1.0 * 24.0 * 60.0 * 60.0
bool SorptionHistoryDesorption = true
double Thickness = 0.04
double VaporPhaseDiffusionCoefficient = 3.9e-12
double VaporPhaseDiffusionExponent = 1.0
double VaporPhaseSaturationDensity = 0.0173
double WaterPhaseDensity = 999.97
double WaterPhaseDiffusionCoefficient = 1.17e-7
double WaterPhaseDiffusionExponent = 2.0
double YoungsModulus = 30.0 * 10e9