From bc31ba8f5c0165cdb978a392fe3d5fdf73ce9bbf Mon Sep 17 00:00:00 2001 From: Daniels Date: Fri, 4 Apr 2025 16:40:01 +0200 Subject: [PATCH 01/11] added kOmegaSST turbulence model --- perpendicular-flap/fluid-openfoam/0/k | 60 ++++++++++++++++++ perpendicular-flap/fluid-openfoam/0/nut | 61 +++++++++++++++++++ perpendicular-flap/fluid-openfoam/0/omega | 60 ++++++++++++++++++ .../constant/transportProperties | 2 +- .../constant/turbulenceProperties | 11 +++- .../fluid-openfoam/system/fvSchemes | 10 +++ .../fluid-openfoam/system/fvSolution | 32 ++++++++++ 7 files changed, 234 insertions(+), 2 deletions(-) create mode 100644 perpendicular-flap/fluid-openfoam/0/k create mode 100644 perpendicular-flap/fluid-openfoam/0/nut create mode 100644 perpendicular-flap/fluid-openfoam/0/omega diff --git a/perpendicular-flap/fluid-openfoam/0/k b/perpendicular-flap/fluid-openfoam/0/k new file mode 100644 index 000000000..f90cd7366 --- /dev/null +++ b/perpendicular-flap/fluid-openfoam/0/k @@ -0,0 +1,60 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: v1812 | +| \\ / A nd | Web: www.OpenFOAM.com | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ +version 2.0; +format ascii; +class volScalarField; +object k; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +dimensions [ 0 2 -2 0 0 0 0 ]; + +internalField uniform 5; + +boundaryField +{ + +inlet +{ +type fixedValue; +value $internalField; +} + +outlet +{ +type inletOutlet; +inletValue $internalField; +value $internalField; +} + +flap +{ +type kqRWallFunction; +value $internalField; +} + +frontAndBack +{ +type empty; +} + +upperWall +{ +type zeroGradient; +} + +lowerWall +{ +type zeroGradient; +} + +} + +// ************************************************************************* // diff --git a/perpendicular-flap/fluid-openfoam/0/nut b/perpendicular-flap/fluid-openfoam/0/nut new file mode 100644 index 000000000..6b71631e3 --- /dev/null +++ b/perpendicular-flap/fluid-openfoam/0/nut @@ -0,0 +1,61 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: v1812 | +| \\ / A nd | Web: www.OpenFOAM.com | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ +version 2.0; +format ascii; +class volScalarField; +object k; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +dimensions [ 0 2 -1 0 0 0 0 ]; + +internalField uniform 5; + +boundaryField +{ + +inlet +{ +type calculated; +value uniform 0; +} + +outlet +{ +type calculated; +value uniform 0; +} + +flap +{ +type nutkWallFunction; +value uniform 0; +} + +frontAndBack +{ +type empty; +} + +upperWall +{ +type calculated; +value uniform 0; +} + +lowerWall +{ +type calculated; +value uniform 0; +} + +} + +// ************************************************************************* // diff --git a/perpendicular-flap/fluid-openfoam/0/omega b/perpendicular-flap/fluid-openfoam/0/omega new file mode 100644 index 000000000..3c5572838 --- /dev/null +++ b/perpendicular-flap/fluid-openfoam/0/omega @@ -0,0 +1,60 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: v1812 | +| \\ / A nd | Web: www.OpenFOAM.com | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ +version 2.0; +format ascii; +class volScalarField; +object k; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +dimensions [ 0 0 -1 0 0 0 0 ]; + +internalField uniform 10; + +boundaryField +{ + +inlet +{ +type fixedValue; +value $internalField; +} + +outlet +{ +type inletOutlet; +inletValue $internalField; +value $internalField; +} + +flap +{ +type omegaWallFunction; +value $internalField; +} + +frontAndBack +{ +type empty; +} + +upperWall +{ +type zeroGradient; +} + +lowerWall +{ +type zeroGradient; +} + +} + +// ************************************************************************* // diff --git a/perpendicular-flap/fluid-openfoam/constant/transportProperties b/perpendicular-flap/fluid-openfoam/constant/transportProperties index 5383adaad..417037381 100644 --- a/perpendicular-flap/fluid-openfoam/constant/transportProperties +++ b/perpendicular-flap/fluid-openfoam/constant/transportProperties @@ -8,4 +8,4 @@ FoamFile transportModel Newtonian; -nu nu [ 0 2 -1 0 0 0 0 ] 1; +nu nu [ 0 2 -1 0 0 0 0 ] 1e-5; diff --git a/perpendicular-flap/fluid-openfoam/constant/turbulenceProperties b/perpendicular-flap/fluid-openfoam/constant/turbulenceProperties index 592f6d52d..9651c65f6 100644 --- a/perpendicular-flap/fluid-openfoam/constant/turbulenceProperties +++ b/perpendicular-flap/fluid-openfoam/constant/turbulenceProperties @@ -6,4 +6,13 @@ FoamFile object turbulenceProperties; } -simulationType laminar; +simulationType RAS; + +RAS +{ + +RASModel kOmegaSST; + +turbulence on; +printCoeffs on; +} diff --git a/perpendicular-flap/fluid-openfoam/system/fvSchemes b/perpendicular-flap/fluid-openfoam/system/fvSchemes index 80c096192..01d7260eb 100644 --- a/perpendicular-flap/fluid-openfoam/system/fvSchemes +++ b/perpendicular-flap/fluid-openfoam/system/fvSchemes @@ -20,6 +20,9 @@ divSchemes { default none; div(phi,U) bounded Gauss upwind; + div(phi,k) bounded Gauss limitedLinear 1; + div(phi,omega) bounded Gauss upwind; + div((nuEff*dev2(T(grad(U))))) Gauss linear; } @@ -37,3 +40,10 @@ snGradSchemes { default corrected; } + +wallDist +{ + method meshWave; // Recommended method +} + +// ************************************************************************* // diff --git a/perpendicular-flap/fluid-openfoam/system/fvSolution b/perpendicular-flap/fluid-openfoam/system/fvSolution index 064d7f372..901f24578 100644 --- a/perpendicular-flap/fluid-openfoam/system/fvSolution +++ b/perpendicular-flap/fluid-openfoam/system/fvSolution @@ -54,6 +54,38 @@ solvers $U; relTol 0; } + +"(U|epsilon|k|omega)" +{ + +solver smoothSolver; +smoother symGaussSeidel; +tolerance 1e-6; +relTol 1e-3; +// minIter 100; +} +"(U|k|epsilon|omega)Final" +{ +$U; +tolerance 1e-6; +relTol 0; +minIter 2; +} + +yPsi +{ +solver PBiCGStab; +preconditioner DILU; +tolerance 1e-5; +relTol 0; +} + +yPsiFinal +{ +$yPsi +relTol 0; +} + } PIMPLE From c1afbc561b5fadfa99b1b24470e3ad64448c1de2 Mon Sep 17 00:00:00 2001 From: Gerasimos Chourdakis Date: Mon, 7 Apr 2025 11:03:15 +0200 Subject: [PATCH 02/11] Adjust indentation and remove not needed headers from new files --- perpendicular-flap/fluid-openfoam/0/k | 73 ++++++++++------------ perpendicular-flap/fluid-openfoam/0/nut | 75 ++++++++++------------- perpendicular-flap/fluid-openfoam/0/omega | 73 ++++++++++------------ 3 files changed, 97 insertions(+), 124 deletions(-) diff --git a/perpendicular-flap/fluid-openfoam/0/k b/perpendicular-flap/fluid-openfoam/0/k index f90cd7366..9a86c0eea 100644 --- a/perpendicular-flap/fluid-openfoam/0/k +++ b/perpendicular-flap/fluid-openfoam/0/k @@ -1,18 +1,10 @@ -/*--------------------------------*- C++ -*----------------------------------*\ -| ========= | | -| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | -| \\ / O peration | Version: v1812 | -| \\ / A nd | Web: www.OpenFOAM.com | -| \\/ M anipulation | | -\*---------------------------------------------------------------------------*/ FoamFile { -version 2.0; -format ascii; -class volScalarField; -object k; + version 2.0; + format ascii; + class volScalarField; + object k; } -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // dimensions [ 0 2 -2 0 0 0 0 ]; @@ -21,40 +13,39 @@ internalField uniform 5; boundaryField { -inlet -{ -type fixedValue; -value $internalField; -} + inlet + { + type fixedValue; + value $internalField; + } -outlet -{ -type inletOutlet; -inletValue $internalField; -value $internalField; -} + outlet + { + type inletOutlet; + inletValue $internalField; + value $internalField; + } -flap -{ -type kqRWallFunction; -value $internalField; -} + flap + { + type kqRWallFunction; + value $internalField; + } -frontAndBack -{ -type empty; -} + frontAndBack + { + type empty; + } -upperWall -{ -type zeroGradient; -} + upperWall + { + type zeroGradient; + } -lowerWall -{ -type zeroGradient; -} + lowerWall + { + type zeroGradient; + } } -// ************************************************************************* // diff --git a/perpendicular-flap/fluid-openfoam/0/nut b/perpendicular-flap/fluid-openfoam/0/nut index 6b71631e3..e6d815a28 100644 --- a/perpendicular-flap/fluid-openfoam/0/nut +++ b/perpendicular-flap/fluid-openfoam/0/nut @@ -1,18 +1,10 @@ -/*--------------------------------*- C++ -*----------------------------------*\ -| ========= | | -| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | -| \\ / O peration | Version: v1812 | -| \\ / A nd | Web: www.OpenFOAM.com | -| \\/ M anipulation | | -\*---------------------------------------------------------------------------*/ FoamFile { -version 2.0; -format ascii; -class volScalarField; -object k; + version 2.0; + format ascii; + class volScalarField; + object k; } -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // dimensions [ 0 2 -1 0 0 0 0 ]; @@ -21,41 +13,40 @@ internalField uniform 5; boundaryField { -inlet -{ -type calculated; -value uniform 0; -} + inlet + { + type calculated; + value uniform 0; + } -outlet -{ -type calculated; -value uniform 0; -} + outlet + { + type calculated; + value uniform 0; + } -flap -{ -type nutkWallFunction; -value uniform 0; -} + flap + { + type nutkWallFunction; + value uniform 0; + } -frontAndBack -{ -type empty; -} + frontAndBack + { + type empty; + } -upperWall -{ -type calculated; -value uniform 0; -} + upperWall + { + type calculated; + value uniform 0; + } -lowerWall -{ -type calculated; -value uniform 0; -} + lowerWall + { + type calculated; + value uniform 0; + } } -// ************************************************************************* // diff --git a/perpendicular-flap/fluid-openfoam/0/omega b/perpendicular-flap/fluid-openfoam/0/omega index 3c5572838..5ccb17bb7 100644 --- a/perpendicular-flap/fluid-openfoam/0/omega +++ b/perpendicular-flap/fluid-openfoam/0/omega @@ -1,18 +1,10 @@ -/*--------------------------------*- C++ -*----------------------------------*\ -| ========= | | -| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | -| \\ / O peration | Version: v1812 | -| \\ / A nd | Web: www.OpenFOAM.com | -| \\/ M anipulation | | -\*---------------------------------------------------------------------------*/ FoamFile { -version 2.0; -format ascii; -class volScalarField; -object k; + version 2.0; + format ascii; + class volScalarField; + object k; } -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // dimensions [ 0 0 -1 0 0 0 0 ]; @@ -21,40 +13,39 @@ internalField uniform 10; boundaryField { -inlet -{ -type fixedValue; -value $internalField; -} + inlet + { + type fixedValue; + value $internalField; + } -outlet -{ -type inletOutlet; -inletValue $internalField; -value $internalField; -} + outlet + { + type inletOutlet; + inletValue $internalField; + value $internalField; + } -flap -{ -type omegaWallFunction; -value $internalField; -} + flap + { + type omegaWallFunction; + value $internalField; + } -frontAndBack -{ -type empty; -} + frontAndBack + { + type empty; + } -upperWall -{ -type zeroGradient; -} + upperWall + { + type zeroGradient; + } -lowerWall -{ -type zeroGradient; -} + lowerWall + { + type zeroGradient; + } } -// ************************************************************************* // From 3c77aecd12f478bf1f3b8edd9ce556b6a08fcbc6 Mon Sep 17 00:00:00 2001 From: Gerasimos Chourdakis Date: Mon, 7 Apr 2025 11:04:57 +0200 Subject: [PATCH 03/11] Adjust indentation in turbulenceProperties --- .../fluid-openfoam/constant/turbulenceProperties | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/perpendicular-flap/fluid-openfoam/constant/turbulenceProperties b/perpendicular-flap/fluid-openfoam/constant/turbulenceProperties index 9651c65f6..c7daecac4 100644 --- a/perpendicular-flap/fluid-openfoam/constant/turbulenceProperties +++ b/perpendicular-flap/fluid-openfoam/constant/turbulenceProperties @@ -10,9 +10,7 @@ simulationType RAS; RAS { - -RASModel kOmegaSST; - -turbulence on; -printCoeffs on; + RASModel kOmegaSST; + turbulence on; + printCoeffs on; } From aec7dc1bb97063ce7be99d8259d304195c587ac9 Mon Sep 17 00:00:00 2001 From: Gerasimos Chourdakis Date: Mon, 7 Apr 2025 11:05:44 +0200 Subject: [PATCH 04/11] Cleanup comments in fvSchemes --- perpendicular-flap/fluid-openfoam/system/fvSchemes | 2 -- 1 file changed, 2 deletions(-) diff --git a/perpendicular-flap/fluid-openfoam/system/fvSchemes b/perpendicular-flap/fluid-openfoam/system/fvSchemes index 01d7260eb..51ebc3714 100644 --- a/perpendicular-flap/fluid-openfoam/system/fvSchemes +++ b/perpendicular-flap/fluid-openfoam/system/fvSchemes @@ -45,5 +45,3 @@ wallDist { method meshWave; // Recommended method } - -// ************************************************************************* // From 3cfd92f25f4792ada65427580725f67e2ec975fb Mon Sep 17 00:00:00 2001 From: Gerasimos Chourdakis Date: Mon, 7 Apr 2025 11:06:30 +0200 Subject: [PATCH 05/11] Fix indentation in fvSolution --- .../fluid-openfoam/system/fvSolution | 31 +++++++++---------- 1 file changed, 15 insertions(+), 16 deletions(-) diff --git a/perpendicular-flap/fluid-openfoam/system/fvSolution b/perpendicular-flap/fluid-openfoam/system/fvSolution index 901f24578..540aa0de3 100644 --- a/perpendicular-flap/fluid-openfoam/system/fvSolution +++ b/perpendicular-flap/fluid-openfoam/system/fvSolution @@ -57,33 +57,32 @@ solvers "(U|epsilon|k|omega)" { - -solver smoothSolver; -smoother symGaussSeidel; -tolerance 1e-6; -relTol 1e-3; -// minIter 100; + solver smoothSolver; + smoother symGaussSeidel; + tolerance 1e-6; + relTol 1e-3; + // minIter 100; } "(U|k|epsilon|omega)Final" { -$U; -tolerance 1e-6; -relTol 0; -minIter 2; + $U; + tolerance 1e-6; + relTol 0; + minIter 2; } yPsi { -solver PBiCGStab; -preconditioner DILU; -tolerance 1e-5; -relTol 0; + solver PBiCGStab; + preconditioner DILU; + tolerance 1e-5; + relTol 0; } yPsiFinal { -$yPsi -relTol 0; + $yPsi + relTol 0; } } From 42cb5c3f55e8c5c888d7a633269ecea824e88a61 Mon Sep 17 00:00:00 2001 From: Gerasimos Chourdakis Date: Mon, 7 Apr 2025 11:07:03 +0200 Subject: [PATCH 06/11] Fix (more) indentation in fvSolution --- .../fluid-openfoam/system/fvSolution | 61 +++++++++---------- 1 file changed, 30 insertions(+), 31 deletions(-) diff --git a/perpendicular-flap/fluid-openfoam/system/fvSolution b/perpendicular-flap/fluid-openfoam/system/fvSolution index 540aa0de3..a3ef27cc2 100644 --- a/perpendicular-flap/fluid-openfoam/system/fvSolution +++ b/perpendicular-flap/fluid-openfoam/system/fvSolution @@ -54,37 +54,36 @@ solvers $U; relTol 0; } - -"(U|epsilon|k|omega)" -{ - solver smoothSolver; - smoother symGaussSeidel; - tolerance 1e-6; - relTol 1e-3; - // minIter 100; -} -"(U|k|epsilon|omega)Final" -{ - $U; - tolerance 1e-6; - relTol 0; - minIter 2; -} - -yPsi -{ - solver PBiCGStab; - preconditioner DILU; - tolerance 1e-5; - relTol 0; -} - -yPsiFinal -{ - $yPsi - relTol 0; -} - + + "(U|epsilon|k|omega)" + { + solver smoothSolver; + smoother symGaussSeidel; + tolerance 1e-6; + relTol 1e-3; + // minIter 100; + } + "(U|k|epsilon|omega)Final" + { + $U; + tolerance 1e-6; + relTol 0; + minIter 2; + } + + yPsi + { + solver PBiCGStab; + preconditioner DILU; + tolerance 1e-5; + relTol 0; + } + + yPsiFinal + { + $yPsi + relTol 0; + } } PIMPLE From db7a45d75517283bd5d7ec622669b5fb13898a2a Mon Sep 17 00:00:00 2001 From: Daniels Vidulejs <36682359+vidulejs@users.noreply.github.com> Date: Tue, 8 Apr 2025 13:07:33 +0200 Subject: [PATCH 07/11] Use Poisson wallDist --- perpendicular-flap/fluid-openfoam/system/fvSchemes | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/perpendicular-flap/fluid-openfoam/system/fvSchemes b/perpendicular-flap/fluid-openfoam/system/fvSchemes index 51ebc3714..5d636d5d7 100644 --- a/perpendicular-flap/fluid-openfoam/system/fvSchemes +++ b/perpendicular-flap/fluid-openfoam/system/fvSchemes @@ -43,5 +43,5 @@ snGradSchemes wallDist { - method meshWave; // Recommended method + method Poisson; } From b7a4b27a0c2b6401276039647c7424a1d53a7627 Mon Sep 17 00:00:00 2001 From: Daniels Date: Tue, 27 May 2025 13:43:21 +0200 Subject: [PATCH 08/11] increase velocity 10x --- perpendicular-flap/fluid-openfoam/0/U | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/perpendicular-flap/fluid-openfoam/0/U b/perpendicular-flap/fluid-openfoam/0/U index 5ad191331..12661a122 100644 --- a/perpendicular-flap/fluid-openfoam/0/U +++ b/perpendicular-flap/fluid-openfoam/0/U @@ -8,7 +8,7 @@ FoamFile dimensions [0 1 -1 0 0 0 0]; -internalField uniform (10 0 0); +internalField uniform (100 0 0); boundaryField { From 808c41d5ebc9ef6147923069ef7de9fcd13de304 Mon Sep 17 00:00:00 2001 From: Daniels Date: Tue, 27 May 2025 13:43:57 +0200 Subject: [PATCH 09/11] fix stability issues with k and omega --- perpendicular-flap/fluid-openfoam/0/k | 29 ++++++++++---- perpendicular-flap/fluid-openfoam/0/omega | 40 ++++++++++++------- .../fluid-openfoam/system/controlDict | 12 ++++++ .../fluid-openfoam/system/fvSolution | 13 +++--- 4 files changed, 68 insertions(+), 26 deletions(-) diff --git a/perpendicular-flap/fluid-openfoam/0/k b/perpendicular-flap/fluid-openfoam/0/k index 9a86c0eea..dad3c6114 100644 --- a/perpendicular-flap/fluid-openfoam/0/k +++ b/perpendicular-flap/fluid-openfoam/0/k @@ -1,14 +1,24 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: 2406 | +| \\ / A nd | Website: www.openfoam.com | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ FoamFile { - version 2.0; - format ascii; - class volScalarField; - object k; + version 2.0; + format ascii; + arch "LSB;label=32;scalar=64"; + class volScalarField; + location "0"; + object k; } +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // -dimensions [ 0 2 -2 0 0 0 0 ]; +dimensions [0 2 -2 0 0 0 0]; -internalField uniform 5; +internalField uniform 50; boundaryField { @@ -46,6 +56,11 @@ boundaryField { type zeroGradient; } - + frontAndBack + { + type empty; + } } + +// ************************************************************************* // diff --git a/perpendicular-flap/fluid-openfoam/0/omega b/perpendicular-flap/fluid-openfoam/0/omega index 5ccb17bb7..a793a2bae 100644 --- a/perpendicular-flap/fluid-openfoam/0/omega +++ b/perpendicular-flap/fluid-openfoam/0/omega @@ -1,14 +1,24 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: 2406 | +| \\ / A nd | Website: www.openfoam.com | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ FoamFile { - version 2.0; - format ascii; - class volScalarField; - object k; + version 2.0; + format ascii; + arch "LSB;label=32;scalar=64"; + class volScalarField; + location "0"; + object omega; } +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // -dimensions [ 0 0 -1 0 0 0 0 ]; +dimensions [0 0 -1 0 0 0 0]; -internalField uniform 10; +internalField uniform 80; boundaryField { @@ -28,13 +38,10 @@ boundaryField flap { - type omegaWallFunction; - value $internalField; - } - - frontAndBack - { - type empty; + type omegaWallFunction; + blending binomial; + n 2; + value uniform 80; } upperWall @@ -46,6 +53,11 @@ boundaryField { type zeroGradient; } - + frontAndBack + { + type empty; + } } + +// ************************************************************************* // diff --git a/perpendicular-flap/fluid-openfoam/system/controlDict b/perpendicular-flap/fluid-openfoam/system/controlDict index 9d35646a2..1156ff605 100644 --- a/perpendicular-flap/fluid-openfoam/system/controlDict +++ b/perpendicular-flap/fluid-openfoam/system/controlDict @@ -37,6 +37,18 @@ timePrecision 6; functions { + limitKOmega + { + // Mandatory entries (unmodifiable) + type limitFields; + libs (fieldFunctionObjects); + + // Mandatory entries (runtime modifiable) + fields (omega k); + limit max; + max 1e7; + } + preCICE_Adapter { type preciceAdapterFunctionObject; diff --git a/perpendicular-flap/fluid-openfoam/system/fvSolution b/perpendicular-flap/fluid-openfoam/system/fvSolution index a3ef27cc2..f1bee56df 100644 --- a/perpendicular-flap/fluid-openfoam/system/fvSolution +++ b/perpendicular-flap/fluid-openfoam/system/fvSolution @@ -88,18 +88,21 @@ solvers PIMPLE { - nCorrectors 4; + nCorrectors 2; nNonOrthogonalCorrectors 1; // tolerance 1.0e-14; // relTol 5e-3; consistent true; correctPhi true; momentumPredictor true; - nOuterCorrectors 1; + nOuterCorrectors 2; } - -potentialFlow +relaxationFactors { - nNonOrthogonalCorrectors 10; + equations + { + "k.*" 0.4; + "omega.*" 0.4; + } } From 7d8d1236249492895cb80fc08217bea8397ebbee Mon Sep 17 00:00:00 2001 From: Daniels Date: Tue, 27 May 2025 13:44:38 +0200 Subject: [PATCH 10/11] refine mesh and extend domain --- perpendicular-flap/fluid-openfoam/run.sh | 2 ++ .../fluid-openfoam/system/blockMeshDict | 11 ++++--- .../fluid-openfoam/system/refineMeshDict | 32 +++++++++++++++++++ .../fluid-openfoam/system/topoSetDict | 22 +++++++++++++ 4 files changed, 62 insertions(+), 5 deletions(-) create mode 100644 perpendicular-flap/fluid-openfoam/system/refineMeshDict create mode 100644 perpendicular-flap/fluid-openfoam/system/topoSetDict diff --git a/perpendicular-flap/fluid-openfoam/run.sh b/perpendicular-flap/fluid-openfoam/run.sh index 8f55fbfa5..05309549e 100755 --- a/perpendicular-flap/fluid-openfoam/run.sh +++ b/perpendicular-flap/fluid-openfoam/run.sh @@ -5,6 +5,8 @@ set -e -u exec > >(tee --append "$LOGFILE") 2>&1 blockMesh +topoSet +refineMesh -overwrite ../../tools/run-openfoam.sh "$@" . ../../tools/openfoam-remove-empty-dirs.sh && openfoam_remove_empty_dirs diff --git a/perpendicular-flap/fluid-openfoam/system/blockMeshDict b/perpendicular-flap/fluid-openfoam/system/blockMeshDict index 875f42294..0771137f0 100644 --- a/perpendicular-flap/fluid-openfoam/system/blockMeshDict +++ b/perpendicular-flap/fluid-openfoam/system/blockMeshDict @@ -9,7 +9,7 @@ FoamFile x0 -3.; x1 -0.05; x2 0.05; -x3 3.; +x3 6.; y0 0.; y1 1.; @@ -48,8 +48,9 @@ vertices ); // Grading -h1 30; -h2 3; +h1 20; +h2 1; +h3 40; v1 15; v2 30; @@ -60,7 +61,7 @@ blocks simpleGrading (0.5 1 1) hex ( 2 3 7 6 14 15 19 18 ) - ($h1 $v1 1) + ($h3 $v1 1) simpleGrading (2 1 1) hex ( 4 5 9 8 16 17 21 20 ) @@ -72,7 +73,7 @@ blocks simpleGrading (1 2 1) hex ( 6 7 11 10 18 19 23 22 ) - ($h1 $v2 1 ) + ($h3 $v2 1 ) simpleGrading (2 2 1) ); diff --git a/perpendicular-flap/fluid-openfoam/system/refineMeshDict b/perpendicular-flap/fluid-openfoam/system/refineMeshDict new file mode 100644 index 000000000..2fa67ef7c --- /dev/null +++ b/perpendicular-flap/fluid-openfoam/system/refineMeshDict @@ -0,0 +1,32 @@ +FoamFile +{ + version 2.0; + format ascii; + class dictionary; + location "system"; + object refineMeshDict; +} + +set refinementZoneVer; + +globalCoeffs +{ + tan1 (1 0 0); + tan2 (0 1 0); +} + +directions +( + tan1 + // tan2 +); + +coordinateSystem global; +geometricCut false; + +// Whether to refine cells attached to a patch +// in the normal direction into the domain. +// refineBoundaryCells false; + +writeMesh false; +useHexTopology true; diff --git a/perpendicular-flap/fluid-openfoam/system/topoSetDict b/perpendicular-flap/fluid-openfoam/system/topoSetDict new file mode 100644 index 000000000..6937e88ee --- /dev/null +++ b/perpendicular-flap/fluid-openfoam/system/topoSetDict @@ -0,0 +1,22 @@ +FoamFile +{ + version 2.0; + format ascii; + class dictionary; + location "system"; + object topoSetDict; +} + +actions +( + { + name refinementZoneVer; + type cellSet; + action new; + source boxToCell; + sourceInfo + { + box (-0.5 0 0) (0.5 4 1); + } + } +); \ No newline at end of file From 47f0e3410517f049c698258973b3ad193a3f3ef5 Mon Sep 17 00:00:00 2001 From: Daniels Date: Tue, 27 May 2025 13:44:51 +0200 Subject: [PATCH 11/11] increase Youngs modulus 50x --- perpendicular-flap/solid-calculix/flap.inp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/perpendicular-flap/solid-calculix/flap.inp b/perpendicular-flap/solid-calculix/flap.inp index 4eda56c96..db216780c 100644 --- a/perpendicular-flap/solid-calculix/flap.inp +++ b/perpendicular-flap/solid-calculix/flap.inp @@ -3,7 +3,7 @@ *INCLUDE, INPUT=interface_beam.nam *MATERIAL, Name=EL *ELASTIC - 4000000, 0.3 + 200000000, 0.3 *DENSITY 3000 *SOLID SECTION, Elset=Eall, Material=EL