Commit 405ef971 authored by Mark Olesen's avatar Mark Olesen

STYLE: combine if (log) ... Log statements

parent 2afd807f
......@@ -123,11 +123,8 @@ bool Foam::functionObjects::stabilityBlendingFactor::init(bool first)
{
scalar meanRes = gAverage(mag(*residualPtr)) + VSMALL;
if (log)
{
Log << nl << name() << " : " << nl;
Log << " Average(mag(residuals)) : " << meanRes << endl;
}
Log << nl << name() << " : " << nl
<< " Average(mag(residuals)) : " << meanRes << endl;
oldError_ = error_;
oldErrorIntegral_ = errorIntegral_;
......
......@@ -89,7 +89,7 @@ bool Foam::functionObjects::dataCloud::writeCloud
// Total number of parcels on all processes
const label nTotParcels = returnReduce(nParcels, sumOp<label>());
if (applyFilter_ && log)
if (applyFilter_)
{
// Report filtered/unfiltered count
Log << "After filtering using " << nTotParcels << '/'
......
......@@ -203,28 +203,26 @@ bool Foam::functionObjects::dsmcFields::write()
}
}
if (log)
{
Log << " mag(UMean) max/min : "
<< max(mag(UMean)).value() << " "
<< min(mag(UMean)).value() << endl;
Log << " translationalT max/min : "
<< max(translationalT).value() << " "
<< min(translationalT).value() << endl;
Log << " mag(UMean) max/min : "
<< max(mag(UMean)).value() << " "
<< min(mag(UMean)).value() << nl
Log << " internalT max/min : "
<< max(internalT).value() << " "
<< min(internalT).value() << endl;
<< " translationalT max/min : "
<< max(translationalT).value() << " "
<< min(translationalT).value() << nl
Log << " overallT max/min : "
<< max(overallT).value() << " "
<< min(overallT).value() << endl;
<< " internalT max/min : "
<< max(internalT).value() << " "
<< min(internalT).value() << nl
Log << " p max/min : "
<< max(p).value() << " "
<< min(p).value() << endl;
}
<< " overallT max/min : "
<< max(overallT).value() << " "
<< min(overallT).value() << nl
<< " p max/min : "
<< max(p).value() << " "
<< min(p).value() << endl;
UMean.write();
......
......@@ -142,7 +142,7 @@ bool Foam::functionObjects::vtkCloud::writeCloud
// Total number of parcels on all processes
const label nTotParcels = returnReduce(nParcels, sumOp<label>());
if (applyFilter_ && log)
if (applyFilter_)
{
// Report filtered/unfiltered count
Log << "After filtering using " << nTotParcels << '/'
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment