diff --git a/applications/utilities/mesh/manipulation/mirrorMesh/mirrorFvMesh.C b/applications/utilities/mesh/manipulation/mirrorMesh/mirrorFvMesh.C index e2fc755111..4c894b2956 100644 --- a/applications/utilities/mesh/manipulation/mirrorMesh/mirrorFvMesh.C +++ b/applications/utilities/mesh/manipulation/mirrorMesh/mirrorFvMesh.C @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2017 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2018 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -29,17 +29,17 @@ License // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // -Foam::mirrorFvMesh::mirrorFvMesh(const IOobject& io) +Foam::mirrorFvMesh::mirrorFvMesh(const IOobject& io, const word& dictName) : fvMesh(io), mirrorMeshDict_ ( IOobject ( - "mirrorMeshDict", + dictName, time().system(), *this, - IOobject::MUST_READ_IF_MODIFIED, + IOobject::MUST_READ, IOobject::NO_WRITE ) ) diff --git a/applications/utilities/mesh/manipulation/mirrorMesh/mirrorFvMesh.H b/applications/utilities/mesh/manipulation/mirrorMesh/mirrorFvMesh.H index ca0f14645d..20b0614908 100644 --- a/applications/utilities/mesh/manipulation/mirrorMesh/mirrorFvMesh.H +++ b/applications/utilities/mesh/manipulation/mirrorMesh/mirrorFvMesh.H @@ -79,7 +79,7 @@ public: // Constructors //- Construct from IOobject - mirrorFvMesh(const IOobject& io); + mirrorFvMesh(const IOobject& io, const word& dictName); //- Destructor diff --git a/applications/utilities/mesh/manipulation/mirrorMesh/mirrorMesh.C b/applications/utilities/mesh/manipulation/mirrorMesh/mirrorMesh.C index 2f16e1dd05..bc5a365b43 100644 --- a/applications/utilities/mesh/manipulation/mirrorMesh/mirrorMesh.C +++ b/applications/utilities/mesh/manipulation/mirrorMesh/mirrorMesh.C @@ -42,10 +42,16 @@ using namespace Foam; int main(int argc, char *argv[]) { #include "addOverwriteOption.H" + #include "addDictOption.H" + #include "setRootCase.H" #include "createTime.H" const bool overwrite = args.optionFound("overwrite"); + const word dictName + ( + args.optionLookupOrDefault("dict", "mirrorMeshDict") + ); mirrorFvMesh mesh ( @@ -54,7 +60,8 @@ int main(int argc, char *argv[]) mirrorFvMesh::defaultRegion, runTime.constant(), runTime - ) + ), + dictName ); hexRef8Data refData diff --git a/tutorials/incompressible/pimpleFoam/RAS/elipsekkLOmega/Allrun b/tutorials/incompressible/pimpleFoam/RAS/elipsekkLOmega/Allrun index 05b7969601..290d63be27 100755 --- a/tutorials/incompressible/pimpleFoam/RAS/elipsekkLOmega/Allrun +++ b/tutorials/incompressible/pimpleFoam/RAS/elipsekkLOmega/Allrun @@ -10,14 +10,10 @@ application=$(getApplication) runApplication blockMesh runApplication transformPoints -scale '(1.6666 1 1)' -runApplication changeDictionary -instance system -dict system/changeDictionaryDict.X -runApplication mirrorMesh -overwrite +runApplication mirrorMesh -dict mirrorMeshDict.X -overwrite +rm log.mirrorMesh +runApplication mirrorMesh -dict mirrorMeshDict.Y -overwrite rm log.mirrorMesh - -rm log.changeDictionary -runApplication changeDictionary -instance system -dict system/changeDictionaryDict.Y - -runApplication mirrorMesh -overwrite runApplication topoSet runApplication createPatch -overwrite diff --git a/tutorials/incompressible/pimpleFoam/RAS/elipsekkLOmega/system/changeDictionaryDict b/tutorials/incompressible/pimpleFoam/RAS/elipsekkLOmega/system/changeDictionaryDict deleted file mode 100644 index e3de791c46..0000000000 --- a/tutorials/incompressible/pimpleFoam/RAS/elipsekkLOmega/system/changeDictionaryDict +++ /dev/null @@ -1,26 +0,0 @@ -/*--------------------------------*- 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 changeDictionaryDict; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -mirrorMeshDict -{ - pointAndNormalDict - { - point (0 0 0); - normal (0 -1 0); - } -} - -// ************************************************************************* // diff --git a/tutorials/incompressible/pimpleFoam/RAS/elipsekkLOmega/system/changeDictionaryDict.X b/tutorials/incompressible/pimpleFoam/RAS/elipsekkLOmega/system/changeDictionaryDict.X deleted file mode 100644 index 8192c88ab3..0000000000 --- a/tutorials/incompressible/pimpleFoam/RAS/elipsekkLOmega/system/changeDictionaryDict.X +++ /dev/null @@ -1,26 +0,0 @@ -/*--------------------------------*- 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 changeDictionaryDict; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -mirrorMeshDict -{ - pointAndNormalDict - { - point (0 0 0); - normal (-1 0 0); - } -} - -// ************************************************************************* // diff --git a/tutorials/incompressible/pimpleFoam/RAS/elipsekkLOmega/system/changeDictionaryDict.Y b/tutorials/incompressible/pimpleFoam/RAS/elipsekkLOmega/system/changeDictionaryDict.Y deleted file mode 100644 index e3de791c46..0000000000 --- a/tutorials/incompressible/pimpleFoam/RAS/elipsekkLOmega/system/changeDictionaryDict.Y +++ /dev/null @@ -1,26 +0,0 @@ -/*--------------------------------*- 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 changeDictionaryDict; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -mirrorMeshDict -{ - pointAndNormalDict - { - point (0 0 0); - normal (0 -1 0); - } -} - -// ************************************************************************* // diff --git a/tutorials/incompressible/pimpleFoam/RAS/elipsekkLOmega/system/mirrorMeshDict b/tutorials/incompressible/pimpleFoam/RAS/elipsekkLOmega/system/mirrorMeshDict deleted file mode 100644 index a1fb3e1277..0000000000 --- a/tutorials/incompressible/pimpleFoam/RAS/elipsekkLOmega/system/mirrorMeshDict +++ /dev/null @@ -1,29 +0,0 @@ -/*--------------------------------*- 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 mirrorMeshDict; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -planeType pointAndNormal; - -pointAndNormalDict -{ - point (0 0 0); - normal (0 -1 0); -} - -planeTolerance 1e-06; - - -// ************************************************************************* //