From ff2bbf9c44e413da4a87d2045db035d242cd8cf7 Mon Sep 17 00:00:00 2001 From: ignis Date: Tue, 23 Jan 2018 21:53:23 +0900 Subject: [PATCH] removed unnecessary write control logic in postSootFoam --- .../solvers/combustion/postSootFoam/createFieldRefs.H | 3 ++- applications/solvers/combustion/postSootFoam/createFields.H | 4 +++- applications/solvers/combustion/postSootFoam/postSootFoam.C | 6 +----- 3 files changed, 6 insertions(+), 7 deletions(-) diff --git a/applications/solvers/combustion/postSootFoam/createFieldRefs.H b/applications/solvers/combustion/postSootFoam/createFieldRefs.H index 502b3b423..e28f8b963 100644 --- a/applications/solvers/combustion/postSootFoam/createFieldRefs.H +++ b/applications/solvers/combustion/postSootFoam/createFieldRefs.H @@ -1 +1,2 @@ -const volScalarField& psi = thermo.psi(); +volScalarField& psi = thermo.psi(); +psi.writeOpt() = IOobject::AUTO_WRITE; diff --git a/applications/solvers/combustion/postSootFoam/createFields.H b/applications/solvers/combustion/postSootFoam/createFields.H index 5724c5315..74e136870 100644 --- a/applications/solvers/combustion/postSootFoam/createFields.H +++ b/applications/solvers/combustion/postSootFoam/createFields.H @@ -21,7 +21,9 @@ volScalarField rho ( "rho", runTime.timeName(), - mesh + mesh, + IOobject::NO_READ, + IOobject::AUTO_WRITE ), thermo.rho() ); diff --git a/applications/solvers/combustion/postSootFoam/postSootFoam.C b/applications/solvers/combustion/postSootFoam/postSootFoam.C index 44dc2371d..ba916501a 100644 --- a/applications/solvers/combustion/postSootFoam/postSootFoam.C +++ b/applications/solvers/combustion/postSootFoam/postSootFoam.C @@ -62,11 +62,7 @@ int main(int argc, char *argv[]) radiation->correct(); - if(runTime.write() == true) - { - rho.write(); - psi.write(); - } + runTime.write(); Info<< "ExecutionTime = " << runTime.elapsedCpuTime() << " s" << " ClockTime = " << runTime.elapsedClockTime() << " s"