diff --git a/applications/utilities/postProcessing/turbulence/R/R.C b/applications/utilities/postProcessing/turbulence/R/R.C index f487a13e548b6559fbdf9f222c7b3ab05f511703..490ae2eeb9bb0432d8c57871714abb69c666bb37 100644 --- a/applications/utilities/postProcessing/turbulence/R/R.C +++ b/applications/utilities/postProcessing/turbulence/R/R.C @@ -27,6 +27,10 @@ Application Description Calculates and writes the Reynolds stress R for the current time step. + Compressible modes is automatically selected based on the existence of the + "thermophysicalProperties" dictionary required to construct the + thermodynamics package. + \*---------------------------------------------------------------------------*/ #include "fvCFD.H" @@ -108,22 +112,12 @@ void calcCompressibleR int main(int argc, char *argv[]) { timeSelector::addOptions(); - #include "addRegionOption.H" - - argList::addBoolOption - ( - "compressible", - "calculate compressible R" - ); - #include "setRootCase.H" #include "createTime.H" instantList timeDirs = timeSelector::select0(runTime, args); #include "createNamedMesh.H" - const bool compressible = args.optionFound("compressible"); - forAll(timeDirs, timeI) { runTime.setTime(timeDirs[timeI], timeI); @@ -143,7 +137,15 @@ int main(int argc, char *argv[]) Info<< "Reading field " << UHeader.name() << nl << endl; volVectorField U(UHeader, mesh); - if (compressible) + if + ( + IOobject + ( + basicThermo::dictName, + runTime.constant(), + mesh + ).headerOk() + ) { calcCompressibleR(mesh, runTime, U); } diff --git a/applications/utilities/postProcessing/wall/wallShearStress/wallShearStress.C b/applications/utilities/postProcessing/wall/wallShearStress/wallShearStress.C index 3cf944ea4ca8d685d35e43cd79f54d9afa521015..958bfdc48c83e7a045243ddd583c5a56205383ce 100644 --- a/applications/utilities/postProcessing/wall/wallShearStress/wallShearStress.C +++ b/applications/utilities/postProcessing/wall/wallShearStress/wallShearStress.C @@ -28,8 +28,9 @@ Description Calculates and reports wall shear stress for all patches, for the specified times when using RAS turbulence models. - Default behaviour assumes operating in incompressible mode. - Use the -compressible option for compressible RAS cases. + Compressible modes is automatically selected based on the existence of the + "thermophysicalProperties" dictionary required to construct the + thermodynamics package. \*---------------------------------------------------------------------------*/ @@ -128,22 +129,12 @@ void calcCompressible int main(int argc, char *argv[]) { timeSelector::addOptions(); - #include "addRegionOption.H" - - argList::addBoolOption - ( - "compressible", - "calculate compressible wall shear stress" - ); - #include "setRootCase.H" #include "createTime.H" instantList timeDirs = timeSelector::select0(runTime, args); #include "createNamedMesh.H" - const bool compressible = args.optionFound("compressible"); - forAll(timeDirs, timeI) { runTime.setTime(timeDirs[timeI], timeI); @@ -183,7 +174,15 @@ int main(int argc, char *argv[]) Info<< "Reading field U\n" << endl; volVectorField U(UHeader, mesh); - if (compressible) + if + ( + IOobject + ( + basicThermo::dictName, + runTime.constant(), + mesh + ).headerOk() + ) { calcCompressible(mesh, runTime, U, wallShearStress); } diff --git a/applications/utilities/postProcessing/wall/yPlus/yPlus.C b/applications/utilities/postProcessing/wall/yPlus/yPlus.C index 5adf65869f8503dc2192f1549e2aec7b42472bd0..f2815ef8955b393418c8b9c4300a6db58947bc7e 100644 --- a/applications/utilities/postProcessing/wall/yPlus/yPlus.C +++ b/applications/utilities/postProcessing/wall/yPlus/yPlus.C @@ -32,8 +32,9 @@ Description the y+ values otherwise they are obtained directly from the near-wall velocity gradient and effective and laminar viscosities. - Default behaviour assumes operating in incompressible mode. - Use the -compressible option for compressible cases. + Compressible modes is automatically selected based on the existence of the + "thermophysicalProperties" dictionary required to construct the + thermodynamics package. \*---------------------------------------------------------------------------*/ @@ -180,22 +181,12 @@ void calcCompressibleYPlus int main(int argc, char *argv[]) { timeSelector::addOptions(); - #include "addRegionOption.H" - - argList::addBoolOption - ( - "compressible", - "calculate compressible y+" - ); - #include "setRootCase.H" #include "createTime.H" instantList timeDirs = timeSelector::select(runTime, args, "yPlus"); #include "createNamedMesh.H" - const bool compressible = args.optionFound("compressible"); - forAll(timeDirs, timeI) { runTime.setTime(timeDirs[timeI], timeI); @@ -230,7 +221,15 @@ int main(int argc, char *argv[]) Info<< "Reading field U\n" << endl; volVectorField U(UHeader, mesh); - if (compressible) + if + ( + IOobject + ( + basicThermo::dictName, + runTime.constant(), + mesh + ).headerOk() + ) { calcCompressibleYPlus(mesh, runTime, U, yPlus); }