Template cases: automatically set relaxationFactors for steady-state and transient simulation

This commit is contained in:
Chris Greenshields
2023-08-17 09:21:39 +01:00
parent 07b434e098
commit dd23a7dbe8
4 changed files with 64 additions and 15 deletions

View File

@ -78,18 +78,32 @@ potentialFlow
nNonOrthogonalCorrectors 10;
}
// timeScheme = steadyState for a steady-state simulation; otherwise transient
timeScheme $fvSchemes!ddtSchemes/default;
#ifeq $timeScheme steadyState
relaxationFactors
{
// Steady-state relaxation factors
fields
{
p_rgh 0.7;
p 0.3;
}
equations
{
U 0.3;
e 0.5;
U 0.7;
"(k|omega|epsilon)" 0.7;
}
}
#else
relaxationFactors
{
// Transient relaxation factors
equations
{
".*" 1;
}
}
#endif
// ************************************************************************* //

View File

@ -95,22 +95,32 @@ potentialFlow
nNonOrthogonalCorrectors 10;
}
// timeScheme = steadyState for a steady-state simulation; otherwise transient
timeScheme $fvSchemes!ddtSchemes/default;
#ifeq $timeScheme steadyState
relaxationFactors
{
// Steady-state relaxation factors
fields
{
p 0.3;
p 0.3;
}
equations
{
U 0.7;
U 0.7;
"(k|omega|epsilon)" 0.7;
}
}
cache
#else
relaxationFactors
{
grad(U);
// Transient relaxation factors
equations
{
".*" 1;
}
}
#endif
// ************************************************************************* //

View File

@ -77,17 +77,32 @@ potentialFlow
nNonOrthogonalCorrectors 10;
}
// timeScheme = steadyState for a steady-state simulation; otherwise transient
timeScheme $fvSchemes!ddtSchemes/default;
#ifeq $timeScheme steadyState
relaxationFactors
{
// Steady-state relaxation factors
fields
{
p 0.3;
p 0.3;
}
equations
{
U 0.7;
U 0.7;
"(k|omega|epsilon)" 0.7;
}
}
#else
relaxationFactors
{
// Transient relaxation factors
equations
{
".*" 1;
}
}
#endif
// ************************************************************************* //

View File

@ -95,22 +95,32 @@ potentialFlow
nNonOrthogonalCorrectors 10;
}
// timeScheme = steadyState for a steady-state simulation; otherwise transient
timeScheme $fvSchemes!ddtSchemes/default;
#ifeq $timeScheme steadyState
relaxationFactors
{
// Steady-state relaxation factors
fields
{
p 0.3;
p 0.3;
}
equations
{
U 0.7;
U 0.7;
"(k|omega|epsilon)" 0.7;
}
}
cache
#else
relaxationFactors
{
grad(U);
// Transient relaxation factors
equations
{
".*" 1;
}
}
#endif
// ************************************************************************* //