diff --git a/applications/utilities/mesh/manipulation/createPatch/createPatch.C b/applications/utilities/mesh/manipulation/createPatch/createPatch.C index f240270b72..0270ea607d 100644 --- a/applications/utilities/mesh/manipulation/createPatch/createPatch.C +++ b/applications/utilities/mesh/manipulation/createPatch/createPatch.C @@ -195,8 +195,8 @@ void filterPatches(polyMesh& mesh, const HashSet& addedPatchNames) } -// Dump for all patches the current match -void dumpCyclicMatch(const fileName& prefix, const polyMesh& mesh) +// Write current match for all patches the as OBJ files +void writeCyclicMatchObjs(const fileName& prefix, const polyMesh& mesh) { const polyBoundaryMesh& patches = mesh.boundaryMesh(); @@ -211,10 +211,10 @@ void dumpCyclicMatch(const fileName& prefix, const polyMesh& mesh) const cyclicPolyPatch& cycPatch = refCast(patches[patchi]); - // Dump patches + // Write patches { - OFstream str(prefix+cycPatch.name()+".obj"); - Pout<< "Dumping " << cycPatch.name() + OFstream str(prefix+cycPatch.name() + ".obj"); + Pout<< "Writing " << cycPatch.name() << " faces to " << str.name() << endl; meshTools::writeOBJ ( @@ -227,7 +227,7 @@ void dumpCyclicMatch(const fileName& prefix, const polyMesh& mesh) const cyclicPolyPatch& nbrPatch = cycPatch.neighbPatch(); { OFstream str(prefix+nbrPatch.name()+".obj"); - Pout<< "Dumping " << nbrPatch.name() + Pout<< "Writing " << nbrPatch.name() << " faces to " << str.name() << endl; meshTools::writeOBJ ( @@ -242,7 +242,7 @@ void dumpCyclicMatch(const fileName& prefix, const polyMesh& mesh) OFstream str(prefix+cycPatch.name()+nbrPatch.name()+"_match.obj"); label vertI = 0; - Pout<< "Dumping cyclic match as lines between face centres to " + Pout<< "Writing cyclic match as lines between face centres to " << str.name() << endl; forAll(cycPatch, facei) @@ -532,6 +532,12 @@ int main(int argc, char *argv[]) // Whether to synchronise points const Switch pointSync(dict.lookup("pointSync")); + // Whether to write cyclic matches to .OBJ files + const Switch writeCyclicMatch + ( + dict.lookupOrDefault("writeCyclicMatch", false) + ); + const polyBoundaryMesh& patches = mesh.boundaryMesh(); @@ -539,7 +545,10 @@ int main(int argc, char *argv[]) patches.checkParallelSync(true); - dumpCyclicMatch("initial_", mesh); + if (writeCyclicMatch) + { + writeCyclicMatchObjs("initial_", mesh); + } // Read patch construct info from dictionary PtrList patchSources(dict.lookup("patches")); @@ -758,7 +767,10 @@ int main(int argc, char *argv[]) autoPtr map = meshMod.changeMesh(mesh, true); mesh.movePoints(map().preMotionPoints()); - dumpCyclicMatch("coupled_", mesh); + if (writeCyclicMatch) + { + writeCyclicMatchObjs("coupled_", mesh); + } // Synchronise points. if (!pointSync) @@ -869,7 +881,10 @@ int main(int argc, char *argv[]) filterPatches(mesh, addedPatchNames); - dumpCyclicMatch("final_", mesh); + if (writeCyclicMatch) + { + writeCyclicMatchObjs("final_", mesh); + } // Set the precision of the points data to 10 diff --git a/applications/utilities/mesh/manipulation/createPatch/createPatchDict b/applications/utilities/mesh/manipulation/createPatch/createPatchDict index 62e6cf619c..3ba00342a1 100644 --- a/applications/utilities/mesh/manipulation/createPatch/createPatchDict +++ b/applications/utilities/mesh/manipulation/createPatch/createPatchDict @@ -44,6 +44,9 @@ FoamFile // with transformations (i.e. cyclics). pointSync false; +// Optional: Write cyclic matches into .obj format; defaults to false. +writeCyclicMatch false; + // Patches to create. patches ( diff --git a/tutorials/combustion/fireFoam/LES/flameSpreadWaterSuppressionPanel/system/filmRegion/createPatchDict b/tutorials/combustion/fireFoam/LES/flameSpreadWaterSuppressionPanel/system/filmRegion/createPatchDict index 09a0c7f2dd..8124147ee8 100644 --- a/tutorials/combustion/fireFoam/LES/flameSpreadWaterSuppressionPanel/system/filmRegion/createPatchDict +++ b/tutorials/combustion/fireFoam/LES/flameSpreadWaterSuppressionPanel/system/filmRegion/createPatchDict @@ -12,9 +12,8 @@ FoamFile class dictionary; object createPatchDict; } -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // -matchTolerance 1E-3; +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // pointSync false; diff --git a/tutorials/combustion/fireFoam/LES/oppositeBurningPanels/system/createPatchDict b/tutorials/combustion/fireFoam/LES/oppositeBurningPanels/system/createPatchDict index deb72029e1..cddf451b41 100644 --- a/tutorials/combustion/fireFoam/LES/oppositeBurningPanels/system/createPatchDict +++ b/tutorials/combustion/fireFoam/LES/oppositeBurningPanels/system/createPatchDict @@ -45,6 +45,9 @@ FoamFile // with transformations (i.e. cyclics). pointSync false; +// Optional: Write cyclic matches into .obj format; defaults to false. +writeCyclicMatch false; + // Patches to create. patches ( diff --git a/tutorials/combustion/fireFoam/LES/smallPoolFire2D/system/createPatchDict b/tutorials/combustion/fireFoam/LES/smallPoolFire2D/system/createPatchDict index d8182f3300..695e5af867 100644 --- a/tutorials/combustion/fireFoam/LES/smallPoolFire2D/system/createPatchDict +++ b/tutorials/combustion/fireFoam/LES/smallPoolFire2D/system/createPatchDict @@ -45,6 +45,9 @@ FoamFile // with transformations (i.e. cyclics). pointSync false; +// Optional: Write cyclic matches into .obj format; defaults to false. +writeCyclicMatch false; + // Patches to create. patches ( diff --git a/tutorials/combustion/fireFoam/LES/smallPoolFire3D/system/createPatchDict b/tutorials/combustion/fireFoam/LES/smallPoolFire3D/system/createPatchDict index d8182f3300..695e5af867 100644 --- a/tutorials/combustion/fireFoam/LES/smallPoolFire3D/system/createPatchDict +++ b/tutorials/combustion/fireFoam/LES/smallPoolFire3D/system/createPatchDict @@ -45,6 +45,9 @@ FoamFile // with transformations (i.e. cyclics). pointSync false; +// Optional: Write cyclic matches into .obj format; defaults to false. +writeCyclicMatch false; + // Patches to create. patches ( diff --git a/tutorials/incompressible/pimpleDyMFoam/propeller/system/createPatchDict b/tutorials/incompressible/pimpleDyMFoam/propeller/system/createPatchDict index d83f0bc7c3..28021b3eb6 100644 --- a/tutorials/incompressible/pimpleDyMFoam/propeller/system/createPatchDict +++ b/tutorials/incompressible/pimpleDyMFoam/propeller/system/createPatchDict @@ -12,6 +12,7 @@ FoamFile class dictionary; object createPatchDict; } + // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // // Do a synchronisation of coupled points after creation of any patches. @@ -19,6 +20,9 @@ FoamFile // with transformations (i.e. cyclics). pointSync false; +// Optional: Write cyclic matches into .obj format; defaults to false. +writeCyclicMatch false; + // Patches to create. patches ( diff --git a/tutorials/incompressible/pimpleDyMFoam/wingMotion/wingMotion2D_simpleFoam/system/createPatchDict b/tutorials/incompressible/pimpleDyMFoam/wingMotion/wingMotion2D_simpleFoam/system/createPatchDict index 137b9a2e7b..a8b9e06c26 100644 --- a/tutorials/incompressible/pimpleDyMFoam/wingMotion/wingMotion2D_simpleFoam/system/createPatchDict +++ b/tutorials/incompressible/pimpleDyMFoam/wingMotion/wingMotion2D_simpleFoam/system/createPatchDict @@ -14,6 +14,7 @@ FoamFile } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + pointSync false; patches diff --git a/tutorials/incompressible/pimpleFoam/RAS/elipsekkLOmega/system/createPatchDict b/tutorials/incompressible/pimpleFoam/RAS/elipsekkLOmega/system/createPatchDict index 2a4e08aa12..7b83a63b88 100644 --- a/tutorials/incompressible/pimpleFoam/RAS/elipsekkLOmega/system/createPatchDict +++ b/tutorials/incompressible/pimpleFoam/RAS/elipsekkLOmega/system/createPatchDict @@ -12,6 +12,7 @@ FoamFile class dictionary; object createPatchDict; } + // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // pointSync false; diff --git a/tutorials/incompressible/pimpleFoam/laminar/planarCouette/0/U b/tutorials/incompressible/pimpleFoam/laminar/planarCouette/0/U new file mode 100644 index 0000000000..d76d835806 --- /dev/null +++ b/tutorials/incompressible/pimpleFoam/laminar/planarCouette/0/U @@ -0,0 +1,37 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: dev | +| \\ / A nd | Web: www.OpenFOAM.org | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class volVectorField; + object U; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +dimensions [0 1 -1 0 0 0 0]; + +internalField uniform (0 0 0); + +boundaryField +{ + movingWall + { + type fixedValue; + value uniform (1 0 0); + } + + bottomWall + { + type noSlip; + } + + #includeEtc "caseDicts/setConstraintTypes" +} + +// ************************************************************************* // diff --git a/tutorials/incompressible/pimpleFoam/laminar/planarCouette/0/p b/tutorials/incompressible/pimpleFoam/laminar/planarCouette/0/p new file mode 100644 index 0000000000..604b78e671 --- /dev/null +++ b/tutorials/incompressible/pimpleFoam/laminar/planarCouette/0/p @@ -0,0 +1,36 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: dev | +| \\ / A nd | Web: www.OpenFOAM.org | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class volScalarField; + object p; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +dimensions [0 2 -2 0 0 0 0]; + +internalField uniform 0; + +boundaryField +{ + movingWall + { + type zeroGradient; + } + + bottomWall + { + type zeroGradient; + } + + #includeEtc "caseDicts/setConstraintTypes" +} + +// ************************************************************************* // diff --git a/tutorials/incompressible/pimpleFoam/laminar/planarCouette/0/sigma b/tutorials/incompressible/pimpleFoam/laminar/planarCouette/0/sigma new file mode 100644 index 0000000000..17f8635b89 --- /dev/null +++ b/tutorials/incompressible/pimpleFoam/laminar/planarCouette/0/sigma @@ -0,0 +1,37 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: dev | +| \\ / A nd | Web: www.OpenFOAM.org | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class volSymmTensorField; + object R; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +dimensions [0 2 -2 0 0 0 0]; + +internalField uniform (0 0 0 0 0 0); + +boundaryField +{ + movingWall + { + type zeroGradient; + } + + bottomWall + { + type zeroGradient; + } + + #includeEtc "caseDicts/setConstraintTypes" +} + + +// ************************************************************************* // diff --git a/tutorials/incompressible/pimpleFoam/laminar/planarCouette/Allclean b/tutorials/incompressible/pimpleFoam/laminar/planarCouette/Allclean new file mode 100644 index 0000000000..bf98fa6419 --- /dev/null +++ b/tutorials/incompressible/pimpleFoam/laminar/planarCouette/Allclean @@ -0,0 +1,13 @@ +#!/bin/sh +cd ${0%/*} || exit 1 # Run from this directory + +# Source tutorial clean functions +. $WM_PROJECT_DIR/bin/tools/CleanFunctions + +cleanCase + +# Delete OBJ files that are created by createPatch, +# when 'dumpCyclicMatches' set to true. +rm -f $objFiles > /dev/null 2>&1 + +#------------------------------------------------------------------------------ diff --git a/tutorials/incompressible/pimpleFoam/laminar/planarCouette/Allrun b/tutorials/incompressible/pimpleFoam/laminar/planarCouette/Allrun new file mode 100644 index 0000000000..916e0ba582 --- /dev/null +++ b/tutorials/incompressible/pimpleFoam/laminar/planarCouette/Allrun @@ -0,0 +1,13 @@ +#!/bin/sh +cd ${0%/*} || exit 1 # Run from this directory + +# Source tutorial run functions +. $WM_PROJECT_DIR/bin/tools/RunFunctions + +runApplication blockMesh + +runApplication createPatch -overwrite + +runApplication $(getApplication) + +#------------------------------------------------------------------------------ diff --git a/tutorials/incompressible/pimpleFoam/laminar/planarCouette/constant/transportProperties b/tutorials/incompressible/pimpleFoam/laminar/planarCouette/constant/transportProperties new file mode 100644 index 0000000000..2a62bb7f6c --- /dev/null +++ b/tutorials/incompressible/pimpleFoam/laminar/planarCouette/constant/transportProperties @@ -0,0 +1,53 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: dev | +| \\ / A nd | Web: www.OpenFOAM.org | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class dictionary; + object transportProperties; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +transportModel Newtonian; + +nu [0 2 -1 0 0 0 0] 1.5e-05; + +BirdCarreauCoeffs +{ + nu0 [0 2 -1 0 0 0 0] 1e-03; + nuInf [0 2 -1 0 0 0 0] 1e-05; + k [0 0 1 0 0 0 0] 1; + n [0 0 0 0 0 0 0] 0.5; +} + +CrossPowerLawCoeffs +{ + nu0 [0 2 -1 0 0 0 0] 1e-03; + nuInf [0 2 -1 0 0 0 0] 1e-05; + m [0 0 1 0 0 0 0] 1; + n [0 0 0 0 0 0 0] 0.5; +} + +powerLawCoeffs +{ + nuMax [0 2 -1 0 0 0 0] 1e-03; + nuMin [0 2 -1 0 0 0 0] 1e-05; + k [0 2 -1 0 0 0 0] 1e-05; + n [0 0 0 0 0 0 0] 1; +} + +HerschelBulkleyCoeffs +{ + nu0 [0 2 -1 0 0 0 0] 1e-03; + tau0 [0 2 -2 0 0 0 0] 1; + k [0 2 -1 0 0 0 0] 1e-05; + n [0 0 0 0 0 0 0] 1; +} + +// ************************************************************************* // diff --git a/tutorials/incompressible/pimpleFoam/laminar/planarCouette/constant/turbulenceProperties b/tutorials/incompressible/pimpleFoam/laminar/planarCouette/constant/turbulenceProperties new file mode 100644 index 0000000000..e7cf61543f --- /dev/null +++ b/tutorials/incompressible/pimpleFoam/laminar/planarCouette/constant/turbulenceProperties @@ -0,0 +1,32 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: dev | +| \\ / A nd | Web: www.OpenFOAM.org | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class dictionary; + object turbulenceProperties; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +simulationType laminar; + +laminar +{ + laminarModel Maxwell; + + MaxwellCoeffs + { + nuM 1; + lambda 5; + } + + printCoeffs on; +} + +// ************************************************************************* // diff --git a/tutorials/incompressible/pimpleFoam/laminar/planarCouette/system/blockMeshDict b/tutorials/incompressible/pimpleFoam/laminar/planarCouette/system/blockMeshDict new file mode 100644 index 0000000000..f96ec72271 --- /dev/null +++ b/tutorials/incompressible/pimpleFoam/laminar/planarCouette/system/blockMeshDict @@ -0,0 +1,89 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: dev | +| \\ / A nd | Web: www.OpenFOAM.org | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class dictionary; + object blockMeshDict; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +convertToMeters 0.1; + +vertices +( + (0 0 0) + (1 0 0) + (1 1 0) + (0 1 0) + (0 0 0.1) + (1 0 0.1) + (1 1 0.1) + (0 1 0.1) +); + +blocks +( + hex (0 1 2 3 4 5 6 7) (20 20 1) simpleGrading (1 1 1) +); + +edges +( +); + +boundary +( + movingWall + { + type wall; + faces + ( + (3 7 6 2) + ); + } + bottomWall + { + type wall; + faces + ( + (1 5 4 0) + ); + } + left + { + type wall; + faces + ( + (0 4 7 3) + ); + } + right + { + type wall; + faces + ( + (2 6 5 1) + ); + } + frontAndBack + { + type empty; + faces + ( + (0 3 2 1) + (4 5 6 7) + ); + } +); + +mergePatchPairs +( +); + +// ************************************************************************* // diff --git a/tutorials/incompressible/pimpleFoam/laminar/planarCouette/system/controlDict b/tutorials/incompressible/pimpleFoam/laminar/planarCouette/system/controlDict new file mode 100644 index 0000000000..7d6ef2a2e8 --- /dev/null +++ b/tutorials/incompressible/pimpleFoam/laminar/planarCouette/system/controlDict @@ -0,0 +1,49 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: dev | +| \\ / A nd | Web: www.OpenFOAM.org | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class dictionary; + location "system"; + object controlDict; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +application pimpleFoam; + +startFrom startTime; + +startTime 0; + +stopAt endTime; + +endTime 25; + +deltaT 0.005; + +writeControl runTime; + +writeInterval 0.5; + +purgeWrite 0; + +writeFormat ascii; + +writePrecision 6; + +writeCompression off; + +timeFormat general; + +timePrecision 6; + +runTimeModifiable true; + + +// ************************************************************************* // diff --git a/tutorials/incompressible/pimpleFoam/laminar/planarCouette/system/createPatchDict b/tutorials/incompressible/pimpleFoam/laminar/planarCouette/system/createPatchDict new file mode 100644 index 0000000000..9082f3b540 --- /dev/null +++ b/tutorials/incompressible/pimpleFoam/laminar/planarCouette/system/createPatchDict @@ -0,0 +1,96 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: dev | +| \\ / A nd | Web: www.OpenFOAM.org | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class dictionary; + object createPatchDict; +} + +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +// This application/dictionary controls: +// - optional: create new patches from boundary faces (either given as +// a set of patches or as a faceSet) +// - always: order faces on coupled patches such that they are opposite. This +// is done for all coupled faces, not just for any patches created. +// - optional: synchronise points on coupled patches. +// - always: remove zero-sized (non-coupled) patches (that were not added) + +// 1. Create cyclic: +// - specify where the faces should come from +// - specify the type of cyclic. If a rotational specify the rotationAxis +// and centre to make matching easier +// - always create both halves in one invocation with correct 'neighbourPatch' +// setting. +// - optionally pointSync true to guarantee points to line up. + +// 2. Correct incorrect cyclic: +// This will usually fail upon loading: +// "face 0 area does not match neighbour 2 by 0.0100005%" +// " -- possible face ordering problem." +// - in polyMesh/boundary file: +// - loosen matchTolerance of all cyclics to get case to load +// - or change patch type from 'cyclic' to 'patch' +// and regenerate cyclic as above + +// Do a synchronisation of coupled points after creation of any patches. +// Note: this does not work with points that are on multiple coupled patches +// with transformations (i.e. cyclics). +pointSync true; + +// Optional: Write cyclic matches into .obj format; defaults to false. +// writeCyclicMatch false; + +// Patches to create. +patches +( + { + // Name of new patch + name cyc_half0; + + // Dictionary to construct new patch from + patchInfo + { + type cyclic; + neighbourPatch cyc_half1; + } + + // How to construct: either from 'patches' or 'set' + constructFrom patches; + + // If constructFrom = patches : names of patches. Wildcards allowed. + patches (left); + + // If constructFrom = set : name of faceSet + set f0; + } + { + // Name of new patch + name cyc_half1; + + // Dictionary to construct new patch from + patchInfo + { + type cyclic; + neighbourPatch cyc_half0; + } + + // How to construct: either from 'patches' or 'set' + constructFrom patches; + + // If constructFrom = patches : names of patches. Wildcards allowed. + patches (right); + + // If constructFrom = set : name of faceSet + set f0; + } +); + +// ************************************************************************* // diff --git a/tutorials/incompressible/pimpleFoam/laminar/planarCouette/system/fvSchemes b/tutorials/incompressible/pimpleFoam/laminar/planarCouette/system/fvSchemes new file mode 100644 index 0000000000..c7802ef935 --- /dev/null +++ b/tutorials/incompressible/pimpleFoam/laminar/planarCouette/system/fvSchemes @@ -0,0 +1,54 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: dev | +| \\ / A nd | Web: www.OpenFOAM.org | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class dictionary; + object fvSchemes; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +ddtSchemes +{ + default backward; +} + +gradSchemes +{ + default Gauss linear; +} + +divSchemes +{ + default none; + + div(phi,U) Gauss linearUpwind grad(U); + div(phi,sigma) Gauss vanAlbada; + + div(sigma) Gauss linear; + div((nu*dev2(T(grad(U))))) Gauss linear; + div((nuM*grad(U))) Gauss linear; +} + +laplacianSchemes +{ + default Gauss linear uncorrected; +} + +interpolationSchemes +{ + default linear; +} + +snGradSchemes +{ + default uncorrected; +} + +// ************************************************************************* // diff --git a/tutorials/incompressible/pimpleFoam/laminar/planarCouette/system/fvSolution b/tutorials/incompressible/pimpleFoam/laminar/planarCouette/system/fvSolution new file mode 100644 index 0000000000..c82c0fb010 --- /dev/null +++ b/tutorials/incompressible/pimpleFoam/laminar/planarCouette/system/fvSolution @@ -0,0 +1,67 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: dev | +| \\ / A nd | Web: www.OpenFOAM.org | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class dictionary; + object fvSolution; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +solvers +{ + p + { + solver GAMG; + smoother DIC; + tolerance 1e-6; + relTol 0.05; + } + + "(U|sigma)" + { + solver smoothSolver; + smoother symGaussSeidel; + tolerance 1e-6; + relTol 0.1; + } + + pFinal + { + $p; + relTol 0; + } + + "(U|sigma)Final" + { + $U; + relTol 0; + } +} + +PIMPLE +{ + momentumPredictor off; + nOuterCorrectors 15; + nCorrectors 3; + nNonOrthogonalCorrectors 0; + pRefCell 0; + pRefValue 0; + turbOnFinalIterOnly no; +} + +relaxationFactors +{ + equations + { + ".*" 1; + } +} + +// ************************************************************************* // diff --git a/tutorials/lagrangian/reactingParcelFoam/cylinder/system/createPatchDict b/tutorials/lagrangian/reactingParcelFoam/cylinder/system/createPatchDict index 7270ff3b15..d768f91678 100644 --- a/tutorials/lagrangian/reactingParcelFoam/cylinder/system/createPatchDict +++ b/tutorials/lagrangian/reactingParcelFoam/cylinder/system/createPatchDict @@ -45,6 +45,9 @@ FoamFile // with transformations (i.e. cyclics). pointSync false; +// Optional: Write cyclic matches into .obj format; defaults to false. +writeCyclicMatch false; + // Patches to create. patchInfo ( diff --git a/tutorials/lagrangian/reactingParcelFoam/rivuletPanel/system/createPatchDict b/tutorials/lagrangian/reactingParcelFoam/rivuletPanel/system/createPatchDict index cbfab2fa08..2b776d0b41 100644 --- a/tutorials/lagrangian/reactingParcelFoam/rivuletPanel/system/createPatchDict +++ b/tutorials/lagrangian/reactingParcelFoam/rivuletPanel/system/createPatchDict @@ -45,6 +45,9 @@ FoamFile // with transformations (i.e. cyclics). pointSync false; +// Optional: Write cyclic matches into .obj format; defaults to false. +writeCyclicMatch false; + // Patches to create. patches ( diff --git a/tutorials/lagrangian/reactingParcelFoam/rivuletPanel/system/wallFilmRegion/createPatchDict b/tutorials/lagrangian/reactingParcelFoam/rivuletPanel/system/wallFilmRegion/createPatchDict index c919a481fe..9cafdd0b7c 100644 --- a/tutorials/lagrangian/reactingParcelFoam/rivuletPanel/system/wallFilmRegion/createPatchDict +++ b/tutorials/lagrangian/reactingParcelFoam/rivuletPanel/system/wallFilmRegion/createPatchDict @@ -45,6 +45,9 @@ FoamFile // with transformations (i.e. cyclics). pointSync false; +// Optional: Write cyclic matches into .obj format; defaults to false. +writeCyclicMatch false; + // Patches to create. patches ( diff --git a/tutorials/lagrangian/reactingParcelFoam/splashPanel/system/createPatchDict b/tutorials/lagrangian/reactingParcelFoam/splashPanel/system/createPatchDict index cbfab2fa08..2b776d0b41 100644 --- a/tutorials/lagrangian/reactingParcelFoam/splashPanel/system/createPatchDict +++ b/tutorials/lagrangian/reactingParcelFoam/splashPanel/system/createPatchDict @@ -45,6 +45,9 @@ FoamFile // with transformations (i.e. cyclics). pointSync false; +// Optional: Write cyclic matches into .obj format; defaults to false. +writeCyclicMatch false; + // Patches to create. patches ( diff --git a/tutorials/lagrangian/reactingParcelFoam/splashPanel/system/wallFilmRegion/createPatchDict b/tutorials/lagrangian/reactingParcelFoam/splashPanel/system/wallFilmRegion/createPatchDict index c919a481fe..9cafdd0b7c 100644 --- a/tutorials/lagrangian/reactingParcelFoam/splashPanel/system/wallFilmRegion/createPatchDict +++ b/tutorials/lagrangian/reactingParcelFoam/splashPanel/system/wallFilmRegion/createPatchDict @@ -45,6 +45,9 @@ FoamFile // with transformations (i.e. cyclics). pointSync false; +// Optional: Write cyclic matches into .obj format; defaults to false. +writeCyclicMatch false; + // Patches to create. patches ( diff --git a/tutorials/mesh/foamyHexMesh/mixerVessel/system/createPatchDict b/tutorials/mesh/foamyHexMesh/mixerVessel/system/createPatchDict index 5aafd9aa4e..37f6b241ce 100644 --- a/tutorials/mesh/foamyHexMesh/mixerVessel/system/createPatchDict +++ b/tutorials/mesh/foamyHexMesh/mixerVessel/system/createPatchDict @@ -12,6 +12,7 @@ FoamFile class dictionary; object createPatchDict; } + // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // // Do a synchronisation of coupled points after creation of any patches. @@ -19,6 +20,9 @@ FoamFile // with transformations (i.e. cyclics). pointSync false; +// Optional: Write cyclic matches into .obj format; defaults to false. +writeCyclicMatch false; + // Patches to create. patches ( diff --git a/tutorials/multiphase/interPhaseChangeDyMFoam/propeller/system/createPatchDict b/tutorials/multiphase/interPhaseChangeDyMFoam/propeller/system/createPatchDict index d83f0bc7c3..28021b3eb6 100644 --- a/tutorials/multiphase/interPhaseChangeDyMFoam/propeller/system/createPatchDict +++ b/tutorials/multiphase/interPhaseChangeDyMFoam/propeller/system/createPatchDict @@ -12,6 +12,7 @@ FoamFile class dictionary; object createPatchDict; } + // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // // Do a synchronisation of coupled points after creation of any patches. @@ -19,6 +20,9 @@ FoamFile // with transformations (i.e. cyclics). pointSync false; +// Optional: Write cyclic matches into .obj format; defaults to false. +writeCyclicMatch false; + // Patches to create. patches ( diff --git a/tutorials/multiphase/potentialFreeSurfaceDyMFoam/oscillatingBox/system/createPatchDict b/tutorials/multiphase/potentialFreeSurfaceDyMFoam/oscillatingBox/system/createPatchDict index fb68e2287e..5b8955c272 100644 --- a/tutorials/multiphase/potentialFreeSurfaceDyMFoam/oscillatingBox/system/createPatchDict +++ b/tutorials/multiphase/potentialFreeSurfaceDyMFoam/oscillatingBox/system/createPatchDict @@ -12,6 +12,7 @@ FoamFile class dictionary; object createPatchDict; } + // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // // Do a synchronisation of coupled points after creation of any patches. @@ -19,6 +20,9 @@ FoamFile // with transformations (i.e. cyclics). pointSync false; +// Optional: Write cyclic matches into .obj format; defaults to false. +writeCyclicMatch false; + // Patches to create. patches (