mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
ENH: motorBike tutorial: use patchGroups
This commit is contained in:
@ -23,6 +23,9 @@ internalField uniform $flowVelocity;
|
|||||||
|
|
||||||
boundaryField
|
boundaryField
|
||||||
{
|
{
|
||||||
|
//- Set patchGroups for constraint patches
|
||||||
|
#include "${WM_PROJECT_DIR}/etc/caseDicts/setConstraintTypes"
|
||||||
|
|
||||||
#include "include/fixedInlet"
|
#include "include/fixedInlet"
|
||||||
|
|
||||||
outlet
|
outlet
|
||||||
|
|||||||
@ -22,6 +22,10 @@ internalField uniform $turbulentKE;
|
|||||||
|
|
||||||
boundaryField
|
boundaryField
|
||||||
{
|
{
|
||||||
|
//- Set patchGroups for constraint patches
|
||||||
|
#include "${WM_PROJECT_DIR}/etc/caseDicts/setConstraintTypes"
|
||||||
|
|
||||||
|
//- Define inlet conditions
|
||||||
#include "include/fixedInlet"
|
#include "include/fixedInlet"
|
||||||
|
|
||||||
outlet
|
outlet
|
||||||
|
|||||||
@ -21,6 +21,9 @@ internalField uniform 0;
|
|||||||
|
|
||||||
boundaryField
|
boundaryField
|
||||||
{
|
{
|
||||||
|
//- Set patchGroups for constraint patches
|
||||||
|
#include "${WM_PROJECT_DIR}/etc/caseDicts/setConstraintTypes"
|
||||||
|
|
||||||
frontAndBack
|
frontAndBack
|
||||||
{
|
{
|
||||||
type calculated;
|
type calculated;
|
||||||
|
|||||||
@ -22,6 +22,9 @@ internalField uniform $turbulentOmega;
|
|||||||
|
|
||||||
boundaryField
|
boundaryField
|
||||||
{
|
{
|
||||||
|
//- Set patchGroups for constraint patches
|
||||||
|
#include "${WM_PROJECT_DIR}/etc/caseDicts/setConstraintTypes"
|
||||||
|
|
||||||
#include "include/fixedInlet"
|
#include "include/fixedInlet"
|
||||||
|
|
||||||
outlet
|
outlet
|
||||||
|
|||||||
@ -22,6 +22,9 @@ internalField uniform $pressure;
|
|||||||
|
|
||||||
boundaryField
|
boundaryField
|
||||||
{
|
{
|
||||||
|
//- Set patchGroups for constraint patches
|
||||||
|
#include "${WM_PROJECT_DIR}/etc/caseDicts/setConstraintTypes"
|
||||||
|
|
||||||
inlet
|
inlet
|
||||||
{
|
{
|
||||||
type zeroGradient;
|
type zeroGradient;
|
||||||
|
|||||||
@ -7,12 +7,19 @@ cd ${0%/*} || exit 1 # run from this directory
|
|||||||
# copy motorbike surface from resources folder
|
# copy motorbike surface from resources folder
|
||||||
cp $FOAM_TUTORIALS/resources/geometry/motorBike.obj.gz constant/triSurface/
|
cp $FOAM_TUTORIALS/resources/geometry/motorBike.obj.gz constant/triSurface/
|
||||||
|
|
||||||
cp -r 0.org 0 > /dev/null 2>&1
|
|
||||||
|
|
||||||
runApplication blockMesh
|
runApplication blockMesh
|
||||||
runApplication snappyHexMesh -overwrite
|
|
||||||
|
|
||||||
runApplication potentialFoam -noFunctionObjects -writep
|
runApplication decomposePar
|
||||||
runApplication `getApplication`
|
runParallel snappyHexMesh 6 -overwrite
|
||||||
|
|
||||||
|
#- For non-parallel running
|
||||||
|
#cp -r 0.org 0 > /dev/null 2>&1
|
||||||
|
|
||||||
|
#- For parallel running
|
||||||
|
ls -d processor* | xargs -i rm -rf ./{}/0 $1
|
||||||
|
ls -d processor* | xargs -i cp -r 0.org ./{}/0 $1
|
||||||
|
|
||||||
|
runParallel potentialFoam 6 -noFunctionObjects -writep
|
||||||
|
runParallel `getApplication` 6
|
||||||
|
|
||||||
# ----------------------------------------------------------------- end-of-file
|
# ----------------------------------------------------------------- end-of-file
|
||||||
|
|||||||
Reference in New Issue
Block a user