Skip to content

Commit

Permalink
cfd: second test case added (motorbike)
Browse files Browse the repository at this point in the history
  • Loading branch information
chZehetner committed Jan 28, 2024
1 parent b140404 commit 9493396
Show file tree
Hide file tree
Showing 44 changed files with 1,588 additions and 5 deletions.
18 changes: 13 additions & 5 deletions tests/cfd/README.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,17 @@
# OpenFOAM testcase

- Lid driven cavity
- openfoam.com, OpenFOAM2312
# OpenFOAM testcases

Testcases are related to
- openfoam.com
- tested with openFOAM2312

## Lid driven cavity
Commands:
- blockMesh
- icoFoam
- icoFoam

## Motorbike
Commands:
- Allrun



File renamed without changes.
File renamed without changes.
9 changes: 9 additions & 0 deletions tests/cfd/example_cavity/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# OpenFOAM testcase

- Lid driven cavity
- openfoam.com, tested with openFOAM2312


Commands:
- blockMesh
- icoFoam
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
51 changes: 51 additions & 0 deletions tests/cfd/example_motorbike/0.orig/U
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
/*--------------------------------*- C++ -*----------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: v2312 |
| \\ / A nd | Website: www.openfoam.com |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class volVectorField;
object U;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

#include "include/initialConditions"

dimensions [0 1 -1 0 0 0 0];

internalField uniform $flowVelocity;

boundaryField
{
#includeEtc "caseDicts/setConstraintTypes"

#include "include/fixedInlet"

outlet
{
type inletOutlet;
inletValue uniform (0 0 0);
value $internalField;
}

lowerWall
{
type fixedValue;
value $internalField;
}

motorBikeGroup
{
type noSlip;
}

#include "include/frontBackUpperPatches"
}


// ************************************************************************* //
15 changes: 15 additions & 0 deletions tests/cfd/example_motorbike/0.orig/include/fixedInlet
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
/*--------------------------------*- C++ -*----------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: v2312 |
| \\ / A nd | Website: www.openfoam.com |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/

inlet
{
type fixedValue;
value $internalField;
}

// ************************************************************************* //
19 changes: 19 additions & 0 deletions tests/cfd/example_motorbike/0.orig/include/frontBackUpperPatches
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
/*--------------------------------*- C++ -*----------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: v2312 |
| \\ / A nd | Website: www.openfoam.com |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/

upperWall
{
type slip;
}

frontAndBack
{
type slip;
}

// ************************************************************************* //
14 changes: 14 additions & 0 deletions tests/cfd/example_motorbike/0.orig/include/initialConditions
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
/*--------------------------------*- C++ -*----------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: v2312 |
| \\ / A nd | Website: www.openfoam.com |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/

flowVelocity (20 0 0);
pressure 0;
turbulentKE 0.24;
turbulentOmega 1.78;

// ************************************************************************* //
53 changes: 53 additions & 0 deletions tests/cfd/example_motorbike/0.orig/k
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
/*--------------------------------*- C++ -*----------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: v2312 |
| \\ / A nd | Website: www.openfoam.com |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class volScalarField;
object k;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

#include "include/initialConditions"

dimensions [0 2 -2 0 0 0 0];

internalField uniform $turbulentKE;

boundaryField
{
#includeEtc "caseDicts/setConstraintTypes"

//- Define inlet conditions
#include "include/fixedInlet"

outlet
{
type inletOutlet;
inletValue $internalField;
value $internalField;
}

lowerWall
{
type kqRWallFunction;
value $internalField;
}

motorBikeGroup
{
type kqRWallFunction;
value $internalField;
}

#include "include/frontBackUpperPatches"
}


// ************************************************************************* //
63 changes: 63 additions & 0 deletions tests/cfd/example_motorbike/0.orig/nut
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
/*--------------------------------*- C++ -*----------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: v2312 |
| \\ / A nd | Website: www.openfoam.com |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class volScalarField;
object nut;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

dimensions [0 2 -1 0 0 0 0];

internalField uniform 0;

boundaryField
{
#includeEtc "caseDicts/setConstraintTypes"

frontAndBack
{
type calculated;
value uniform 0;
}

inlet
{
type calculated;
value uniform 0;
}

outlet
{
type calculated;
value uniform 0;
}

lowerWall
{
type nutkWallFunction;
value uniform 0;
}

upperWall
{
type calculated;
value uniform 0;
}

motorBikeGroup
{
type nutkWallFunction;
value uniform 0;
}
}


// ************************************************************************* //
52 changes: 52 additions & 0 deletions tests/cfd/example_motorbike/0.orig/omega
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
/*--------------------------------*- C++ -*----------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: v2312 |
| \\ / A nd | Website: www.openfoam.com |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class volScalarField;
object omega;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

#include "include/initialConditions"

dimensions [0 0 -1 0 0 0 0];

internalField uniform $turbulentOmega;

boundaryField
{
#includeEtc "caseDicts/setConstraintTypes"

#include "include/fixedInlet"

outlet
{
type inletOutlet;
inletValue $internalField;
value $internalField;
}

lowerWall
{
type omegaWallFunction;
value $internalField;
}

motorBikeGroup
{
type omegaWallFunction;
value $internalField;
}

#include "include/frontBackUpperPatches"
}


// ************************************************************************* //
52 changes: 52 additions & 0 deletions tests/cfd/example_motorbike/0.orig/p
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
/*--------------------------------*- C++ -*----------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: v2312 |
| \\ / A nd | Website: www.openfoam.com |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class volScalarField;
object p;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

#include "include/initialConditions"

dimensions [0 2 -2 0 0 0 0];

internalField uniform $pressure;

boundaryField
{
#includeEtc "caseDicts/setConstraintTypes"

inlet
{
type zeroGradient;
}

outlet
{
type fixedValue;
value $internalField;
}

lowerWall
{
type zeroGradient;
}

motorBikeGroup
{
type zeroGradient;
}

#include "include/frontBackUpperPatches"
}


// ************************************************************************* //
12 changes: 12 additions & 0 deletions tests/cfd/example_motorbike/Allclean
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
#!/bin/sh
cd "${0%/*}" || exit # Run from this directory
. ${WM_PROJECT_DIR:?}/bin/tools/CleanFunctions # Tutorial clean functions
#------------------------------------------------------------------------------

cleanCase0

# Remove surface and features
rm -rf constant/triSurface
rm -rf constant/extendedFeatureEdgeMesh

#------------------------------------------------------------------------------
Loading

0 comments on commit 9493396

Please sign in to comment.