diff --git a/doc/codingStyleGuide.org b/doc/codingStyleGuide.org index b3a80ede2c..3cde03d85d 100644 --- a/doc/codingStyleGuide.org +++ b/doc/codingStyleGuide.org @@ -3,7 +3,7 @@ #+TITLE: OpenFOAM C++ Style Guide #+AUTHOR: OpenFOAM Foundation #+DATE: 2011-2016 -#+LINK: http://OpenFOAM.org +#+LINK: http://OpenFOAM.com #+OPTIONS: author:nil ^:{} #+STARTUP: hidestars #+STARTUP: odd diff --git a/etc/caseDicts/createZeroDirectoryTemplates/boundaryConditions/fluid/buoyant/wallOptions b/etc/caseDicts/createZeroDirectoryTemplates/boundaryConditions/fluid/buoyant/wallOptions index bba8feecfb..df68b121e7 100644 --- a/etc/caseDicts/createZeroDirectoryTemplates/boundaryConditions/fluid/buoyant/wallOptions +++ b/etc/caseDicts/createZeroDirectoryTemplates/boundaryConditions/fluid/buoyant/wallOptions @@ -43,8 +43,8 @@ heatTransfer type compressible::turbulentTemperatureCoupledBaffleMixed; value ${:VALUE.T}; Tnbr T; - kappa fluidThermo; - kappaName none; + kappaMethod fluidThermo; + kappa none; } } } diff --git a/etc/caseDicts/createZeroDirectoryTemplates/boundaryConditions/fluid/compressible/wallOptions b/etc/caseDicts/createZeroDirectoryTemplates/boundaryConditions/fluid/compressible/wallOptions index 81450fc91f..fd2a703afa 100644 --- a/etc/caseDicts/createZeroDirectoryTemplates/boundaryConditions/fluid/compressible/wallOptions +++ b/etc/caseDicts/createZeroDirectoryTemplates/boundaryConditions/fluid/compressible/wallOptions @@ -60,8 +60,8 @@ heatTransfer type compressible::turbulentTemperatureCoupledBaffleMixed; value ${:VALUE.T}; Tnbr T; - kappa fluidThermo; - kappaName none; + kappaMethod fluidThermo; + kappa none; } } } diff --git a/etc/caseDicts/createZeroDirectoryTemplates/boundaryConditions/solid/wallOptions b/etc/caseDicts/createZeroDirectoryTemplates/boundaryConditions/solid/wallOptions index 9ea2973bff..e1fed46905 100644 --- a/etc/caseDicts/createZeroDirectoryTemplates/boundaryConditions/solid/wallOptions +++ b/etc/caseDicts/createZeroDirectoryTemplates/boundaryConditions/solid/wallOptions @@ -39,8 +39,8 @@ heatTransfer type compressible::turbulentTemperatureCoupledBaffleMixed; value ${:VALUE.T}; Tnbr T; - kappa solidThermo; - kappaName none; + kappaMethod solidThermo; + kappa none; } } } diff --git a/etc/caseDicts/postProcessing/fields/CourantNo b/etc/caseDicts/postProcessing/fields/CourantNo index 4204ba83df..b787de8881 100644 --- a/etc/caseDicts/postProcessing/fields/CourantNo +++ b/etc/caseDicts/postProcessing/fields/CourantNo @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Web: www.OpenFOAM.org + \\ / A nd | Web: www.OpenFOAM.com \\/ M anipulation | ------------------------------------------------------------------------------- Description diff --git a/etc/caseDicts/postProcessing/fields/MachNo b/etc/caseDicts/postProcessing/fields/MachNo index ca02b41d6d..624f914602 100644 --- a/etc/caseDicts/postProcessing/fields/MachNo +++ b/etc/caseDicts/postProcessing/fields/MachNo @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Web: www.OpenFOAM.org + \\ / A nd | Web: www.OpenFOAM.com \\/ M anipulation | ------------------------------------------------------------------------------- Description diff --git a/etc/caseDicts/postProcessing/fields/PecletNo b/etc/caseDicts/postProcessing/fields/PecletNo index 4db8558e33..49aeeed4c9 100644 --- a/etc/caseDicts/postProcessing/fields/PecletNo +++ b/etc/caseDicts/postProcessing/fields/PecletNo @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Web: www.OpenFOAM.org + \\ / A nd | Web: www.OpenFOAM.com \\/ M anipulation | ------------------------------------------------------------------------------- Description diff --git a/etc/caseDicts/postProcessing/fields/R b/etc/caseDicts/postProcessing/fields/R index c85005ddc5..bb3cb05bdb 100644 --- a/etc/caseDicts/postProcessing/fields/R +++ b/etc/caseDicts/postProcessing/fields/R @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Web: www.OpenFOAM.org + \\ / A nd | Web: www.OpenFOAM.com \\/ M anipulation | ------------------------------------------------------------------------------- Description diff --git a/etc/caseDicts/postProcessing/fields/XiReactionRate b/etc/caseDicts/postProcessing/fields/XiReactionRate index 7013a0d9e0..19f978d7df 100644 --- a/etc/caseDicts/postProcessing/fields/XiReactionRate +++ b/etc/caseDicts/postProcessing/fields/XiReactionRate @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Web: www.OpenFOAM.org + \\ / A nd | Web: www.OpenFOAM.com \\/ M anipulation | ------------------------------------------------------------------------------- Description diff --git a/etc/caseDicts/postProcessing/fields/components b/etc/caseDicts/postProcessing/fields/components index e6ee7372ae..3098e00898 100644 --- a/etc/caseDicts/postProcessing/fields/components +++ b/etc/caseDicts/postProcessing/fields/components @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Web: www.OpenFOAM.org + \\ / A nd | Web: www.OpenFOAM.com \\/ M anipulation | ------------------------------------------------------------------------------- Description diff --git a/etc/caseDicts/postProcessing/fields/div b/etc/caseDicts/postProcessing/fields/div index c13a9e694d..450a8ff987 100644 --- a/etc/caseDicts/postProcessing/fields/div +++ b/etc/caseDicts/postProcessing/fields/div @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Web: www.OpenFOAM.org + \\ / A nd | Web: www.OpenFOAM.com \\/ M anipulation | ------------------------------------------------------------------------------- Description diff --git a/etc/caseDicts/postProcessing/fields/enstrophy b/etc/caseDicts/postProcessing/fields/enstrophy index 2693f08d73..7a7fc19aa1 100644 --- a/etc/caseDicts/postProcessing/fields/enstrophy +++ b/etc/caseDicts/postProcessing/fields/enstrophy @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Web: www.OpenFOAM.org + \\ / A nd | Web: www.OpenFOAM.com \\/ M anipulation | ------------------------------------------------------------------------------- Description diff --git a/etc/caseDicts/postProcessing/fields/flowType b/etc/caseDicts/postProcessing/fields/flowType index a242afb181..44253d510b 100644 --- a/etc/caseDicts/postProcessing/fields/flowType +++ b/etc/caseDicts/postProcessing/fields/flowType @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Web: www.OpenFOAM.org + \\ / A nd | Web: www.OpenFOAM.com \\/ M anipulation | ------------------------------------------------------------------------------- Description diff --git a/etc/caseDicts/postProcessing/fields/grad b/etc/caseDicts/postProcessing/fields/grad index 9e3dab749b..64c2b278f7 100644 --- a/etc/caseDicts/postProcessing/fields/grad +++ b/etc/caseDicts/postProcessing/fields/grad @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Web: www.OpenFOAM.org + \\ / A nd | Web: www.OpenFOAM.com \\/ M anipulation | ------------------------------------------------------------------------------- Description diff --git a/etc/caseDicts/postProcessing/fields/mag b/etc/caseDicts/postProcessing/fields/mag index 5f3d448a15..8ed2e5a7cb 100644 --- a/etc/caseDicts/postProcessing/fields/mag +++ b/etc/caseDicts/postProcessing/fields/mag @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Web: www.OpenFOAM.org + \\ / A nd | Web: www.OpenFOAM.com \\/ M anipulation | ------------------------------------------------------------------------------- Description diff --git a/etc/caseDicts/postProcessing/fields/magSqr b/etc/caseDicts/postProcessing/fields/magSqr index 8a1c6c8e21..9ffe3cc1d4 100644 --- a/etc/caseDicts/postProcessing/fields/magSqr +++ b/etc/caseDicts/postProcessing/fields/magSqr @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Web: www.OpenFOAM.org + \\ / A nd | Web: www.OpenFOAM.com \\/ M anipulation | ------------------------------------------------------------------------------- Description diff --git a/etc/caseDicts/postProcessing/fields/randomise b/etc/caseDicts/postProcessing/fields/randomise index 490e2b0bc4..d6c36678a5 100644 --- a/etc/caseDicts/postProcessing/fields/randomise +++ b/etc/caseDicts/postProcessing/fields/randomise @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Web: www.OpenFOAM.org + \\ / A nd | Web: www.OpenFOAM.com \\/ M anipulation | ------------------------------------------------------------------------------- Description diff --git a/etc/caseDicts/postProcessing/fields/randomise.cfg b/etc/caseDicts/postProcessing/fields/randomise.cfg index f4a8f49f5a..bc2a0c6394 100644 --- a/etc/caseDicts/postProcessing/fields/randomise.cfg +++ b/etc/caseDicts/postProcessing/fields/randomise.cfg @@ -2,7 +2,7 @@ | ========= | | | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | | \\ / O peration | Version: dev | -| \\ / A nd | Web: www.OpenFOAM.org | +| \\ / A nd | Web: www.OpenFOAM.com | | \\/ M anipulation | | \*---------------------------------------------------------------------------*/ diff --git a/etc/caseDicts/postProcessing/fields/streamFunction b/etc/caseDicts/postProcessing/fields/streamFunction index 362e8f0dbb..125692f7aa 100644 --- a/etc/caseDicts/postProcessing/fields/streamFunction +++ b/etc/caseDicts/postProcessing/fields/streamFunction @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Web: www.OpenFOAM.org + \\ / A nd | Web: www.OpenFOAM.com \\/ M anipulation | ------------------------------------------------------------------------------- Description diff --git a/etc/caseDicts/postProcessing/fields/turbulenceFields b/etc/caseDicts/postProcessing/fields/turbulenceFields index c49d351c3e..8945cbe0ee 100644 --- a/etc/caseDicts/postProcessing/fields/turbulenceFields +++ b/etc/caseDicts/postProcessing/fields/turbulenceFields @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Web: www.OpenFOAM.org + \\ / A nd | Web: www.OpenFOAM.com \\/ M anipulation | ------------------------------------------------------------------------------- Description diff --git a/etc/caseDicts/postProcessing/fields/vorticity b/etc/caseDicts/postProcessing/fields/vorticity index 78bc976309..4edd87fc94 100644 --- a/etc/caseDicts/postProcessing/fields/vorticity +++ b/etc/caseDicts/postProcessing/fields/vorticity @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Web: www.OpenFOAM.org + \\ / A nd | Web: www.OpenFOAM.com \\/ M anipulation | ------------------------------------------------------------------------------- Description diff --git a/etc/caseDicts/postProcessing/fields/wallHeatFlux b/etc/caseDicts/postProcessing/fields/wallHeatFlux index 9e7ef4a69b..84a773e464 100644 --- a/etc/caseDicts/postProcessing/fields/wallHeatFlux +++ b/etc/caseDicts/postProcessing/fields/wallHeatFlux @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Web: www.OpenFOAM.org + \\ / A nd | Web: www.OpenFOAM.com \\/ M anipulation | ------------------------------------------------------------------------------- Description diff --git a/etc/caseDicts/postProcessing/fields/wallShearStress b/etc/caseDicts/postProcessing/fields/wallShearStress index 95d66dfac6..a1802f4fc5 100644 --- a/etc/caseDicts/postProcessing/fields/wallShearStress +++ b/etc/caseDicts/postProcessing/fields/wallShearStress @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Web: www.OpenFOAM.org + \\ / A nd | Web: www.OpenFOAM.com \\/ M anipulation | ------------------------------------------------------------------------------- Description diff --git a/etc/caseDicts/postProcessing/fields/writeCellCentres b/etc/caseDicts/postProcessing/fields/writeCellCentres index f8824910c7..c68960077b 100644 --- a/etc/caseDicts/postProcessing/fields/writeCellCentres +++ b/etc/caseDicts/postProcessing/fields/writeCellCentres @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Web: www.OpenFOAM.org + \\ / A nd | Web: www.OpenFOAM.com \\/ M anipulation | ------------------------------------------------------------------------------- Description diff --git a/etc/caseDicts/postProcessing/fields/writeCellVolumes b/etc/caseDicts/postProcessing/fields/writeCellVolumes index bff6f9ec6d..23965cd7aa 100644 --- a/etc/caseDicts/postProcessing/fields/writeCellVolumes +++ b/etc/caseDicts/postProcessing/fields/writeCellVolumes @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Web: www.OpenFOAM.org + \\ / A nd | Web: www.OpenFOAM.com \\/ M anipulation | ------------------------------------------------------------------------------- Description diff --git a/etc/caseDicts/postProcessing/fields/writeObjects b/etc/caseDicts/postProcessing/fields/writeObjects index 4d43d713cc..d0e949e339 100644 --- a/etc/caseDicts/postProcessing/fields/writeObjects +++ b/etc/caseDicts/postProcessing/fields/writeObjects @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Web: www.OpenFOAM.org + \\ / A nd | Web: www.OpenFOAM.com \\/ M anipulation | ------------------------------------------------------------------------------- Description diff --git a/etc/caseDicts/postProcessing/fields/yPlus b/etc/caseDicts/postProcessing/fields/yPlus index 894971a8e5..eeef037791 100644 --- a/etc/caseDicts/postProcessing/fields/yPlus +++ b/etc/caseDicts/postProcessing/fields/yPlus @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Web: www.OpenFOAM.org + \\ / A nd | Web: www.OpenFOAM.com \\/ M anipulation | ------------------------------------------------------------------------------- Description diff --git a/etc/caseDicts/postProcessing/solvers/scalarTransport/scalarTransport b/etc/caseDicts/postProcessing/solvers/scalarTransport/scalarTransport index d5d71b7fc7..132f56d75c 100644 --- a/etc/caseDicts/postProcessing/solvers/scalarTransport/scalarTransport +++ b/etc/caseDicts/postProcessing/solvers/scalarTransport/scalarTransport @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Web: www.OpenFOAM.org + \\ / A nd | Web: www.OpenFOAM.com \\/ M anipulation | ------------------------------------------------------------------------------- Description diff --git a/etc/caseDicts/postProcessing/solvers/scalarTransport/scalarTransport.cfg b/etc/caseDicts/postProcessing/solvers/scalarTransport/scalarTransport.cfg index 5574f2a6dd..75f0e1f282 100644 --- a/etc/caseDicts/postProcessing/solvers/scalarTransport/scalarTransport.cfg +++ b/etc/caseDicts/postProcessing/solvers/scalarTransport/scalarTransport.cfg @@ -2,7 +2,7 @@ | ========= | | | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | | \\ / O peration | Version: dev | -| \\ / A nd | Web: www.OpenFOAM.org | +| \\ / A nd | Web: www.OpenFOAM.com | | \\/ M anipulation | | \*---------------------------------------------------------------------------*/ diff --git a/etc/caseDicts/postProcessing/surfaceFieldValue/faceZone.cfg b/etc/caseDicts/postProcessing/surfaceFieldValue/faceZone.cfg index 1b6fe1dc62..420edca39d 100644 --- a/etc/caseDicts/postProcessing/surfaceFieldValue/faceZone.cfg +++ b/etc/caseDicts/postProcessing/surfaceFieldValue/faceZone.cfg @@ -2,7 +2,7 @@ | ========= | | | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | | \\ / O peration | Version: dev | -| \\ / A nd | Web: www.OpenFOAM.org | +| \\ / A nd | Web: www.OpenFOAM.com | | \\/ M anipulation | | \*---------------------------------------------------------------------------*/ diff --git a/etc/caseDicts/postProcessing/surfaceFieldValue/patch.cfg b/etc/caseDicts/postProcessing/surfaceFieldValue/patch.cfg index e84c077a29..d8a92f0c07 100644 --- a/etc/caseDicts/postProcessing/surfaceFieldValue/patch.cfg +++ b/etc/caseDicts/postProcessing/surfaceFieldValue/patch.cfg @@ -2,7 +2,7 @@ | ========= | | | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | | \\ / O peration | Version: dev | -| \\ / A nd | Web: www.OpenFOAM.org | +| \\ / A nd | Web: www.OpenFOAM.com | | \\/ M anipulation | | \*---------------------------------------------------------------------------*/ diff --git a/etc/caseDicts/postProcessing/surfaceFieldValue/patchAverage b/etc/caseDicts/postProcessing/surfaceFieldValue/patchAverage index 6ab61f5f9c..5ad1f3ca7e 100644 --- a/etc/caseDicts/postProcessing/surfaceFieldValue/patchAverage +++ b/etc/caseDicts/postProcessing/surfaceFieldValue/patchAverage @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Web: www.OpenFOAM.org + \\ / A nd | Web: www.OpenFOAM.com \\/ M anipulation | ------------------------------------------------------------------------------- Description diff --git a/etc/caseDicts/postProcessing/surfaceFieldValue/patchIntegrate b/etc/caseDicts/postProcessing/surfaceFieldValue/patchIntegrate index f2c4572468..e1e0efd904 100644 --- a/etc/caseDicts/postProcessing/surfaceFieldValue/patchIntegrate +++ b/etc/caseDicts/postProcessing/surfaceFieldValue/patchIntegrate @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Web: www.OpenFOAM.org + \\ / A nd | Web: www.OpenFOAM.com \\/ M anipulation | ------------------------------------------------------------------------------- Description diff --git a/etc/caseDicts/postProcessing/surfaceFieldValue/surfaceRegion.cfg b/etc/caseDicts/postProcessing/surfaceFieldValue/surfaceRegion.cfg index 2d8535259d..009a1bd156 100644 --- a/etc/caseDicts/postProcessing/surfaceFieldValue/surfaceRegion.cfg +++ b/etc/caseDicts/postProcessing/surfaceFieldValue/surfaceRegion.cfg @@ -2,7 +2,7 @@ | ========= | | | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | | \\ / O peration | Version: dev | -| \\ / A nd | Web: www.OpenFOAM.org | +| \\ / A nd | Web: www.OpenFOAM.com | | \\/ M anipulation | | \*---------------------------------------------------------------------------*/ diff --git a/src/OpenFOAM/db/functionObjects/functionObject/functionObject.H b/src/OpenFOAM/db/functionObjects/functionObject/functionObject.H index 40a626c30f..97d94cadfd 100644 --- a/src/OpenFOAM/db/functionObjects/functionObject/functionObject.H +++ b/src/OpenFOAM/db/functionObjects/functionObject/functionObject.H @@ -139,10 +139,10 @@ class functionObject // Private Member Functions //- Disallow default bitwise copy construct - functionObject(const functionObject&); + functionObject(const functionObject&) = delete; //- Disallow default bitwise assignment - void operator=(const functionObject&); + void operator=(const functionObject&) = delete; public: diff --git a/src/OpenFOAM/db/functionObjects/regionFunctionObject/regionFunctionObject.H b/src/OpenFOAM/db/functionObjects/regionFunctionObject/regionFunctionObject.H index 9af84c0f87..e9be6e3487 100644 --- a/src/OpenFOAM/db/functionObjects/regionFunctionObject/regionFunctionObject.H +++ b/src/OpenFOAM/db/functionObjects/regionFunctionObject/regionFunctionObject.H @@ -80,10 +80,11 @@ protected: const ObjectType& lookupObject(const word& fieldName) const; //- Store the given field in the objectRegistry under the given name + // Note: sets the fieldName to tfield().name() if not already set template bool store ( - const word& fieldName, + word& fieldName, const tmp& tfield, bool cacheable = false ); diff --git a/src/OpenFOAM/db/functionObjects/regionFunctionObject/regionFunctionObjectTemplates.C b/src/OpenFOAM/db/functionObjects/regionFunctionObject/regionFunctionObjectTemplates.C index 76327e4d20..5c803a73df 100644 --- a/src/OpenFOAM/db/functionObjects/regionFunctionObject/regionFunctionObjectTemplates.C +++ b/src/OpenFOAM/db/functionObjects/regionFunctionObject/regionFunctionObjectTemplates.C @@ -51,7 +51,7 @@ const ObjectType& Foam::functionObjects::regionFunctionObject::lookupObject template bool Foam::functionObjects::regionFunctionObject::store ( - const word& fieldName, + word& fieldName, const tmp& tfield, bool cacheable ) @@ -90,6 +90,10 @@ bool Foam::functionObjects::regionFunctionObject::store { tfield.ref().rename(fieldName); } + else + { + fieldName = tfield().name(); + } obr_.objectRegistry::store(tfield.ptr()); } diff --git a/src/finiteVolume/interpolation/surfaceInterpolation/limitedSchemes/filteredLinear2/filteredLinear2.H b/src/finiteVolume/interpolation/surfaceInterpolation/limitedSchemes/filteredLinear2/filteredLinear2.H index 4b36d81b97..de625085cd 100644 --- a/src/finiteVolume/interpolation/surfaceInterpolation/limitedSchemes/filteredLinear2/filteredLinear2.H +++ b/src/finiteVolume/interpolation/surfaceInterpolation/limitedSchemes/filteredLinear2/filteredLinear2.H @@ -54,7 +54,7 @@ namespace Foam { /*---------------------------------------------------------------------------*\ - Class filteredLinear2Limiter Declaration + Class filteredLinear2Limiter Declaration \*---------------------------------------------------------------------------*/ template @@ -64,7 +64,7 @@ class filteredLinear2Limiter { // Private data - // Scaling corefficient for the gradient ratio, + // Scaling coefficient for the gradient ratio, // 0 = linear // 1 = fully limited scalar k_; diff --git a/src/functionObjects/field/Q/Q.H b/src/functionObjects/field/Q/Q.H index 586fd13d12..a40e71f758 100644 --- a/src/functionObjects/field/Q/Q.H +++ b/src/functionObjects/field/Q/Q.H @@ -46,7 +46,7 @@ Usage Q1 { type Q; - functionObjectLibs ("libutilityFunctionObjects.so"); + libs ("libutilityFunctionObjects.so"); ... } \endverbatim diff --git a/src/functionObjects/field/externalCoupled/externalCoupled.C b/src/functionObjects/field/externalCoupled/externalCoupled.C index 6828d13e13..c4114c0745 100644 --- a/src/functionObjects/field/externalCoupled/externalCoupled.C +++ b/src/functionObjects/field/externalCoupled/externalCoupled.C @@ -135,19 +135,19 @@ void Foam::functionObjects::externalCoupled::removeReadFiles() const Log << type() << ": removing all read files" << endl; - forAll(regionGroupNames_, regionI) + forAll(regionGroupNames_, regioni) { - const word& compName = regionGroupNames_[regionI]; + const word& compName = regionGroupNames_[regioni]; const labelList& groups = regionToGroups_[compName]; forAll(groups, i) { - label groupI = groups[i]; - const wordRe& groupName = groupNames_[groupI]; + label groupi = groups[i]; + const wordRe& groupName = groupNames_[groupi]; - forAll(groupReadFields_[groupI], fieldI) + forAll(groupReadFields_[groupi], fieldi) { - const word& fieldName = groupReadFields_[groupI][fieldI]; + const word& fieldName = groupReadFields_[groupi][fieldi]; rm ( groupDir(commsDir_, compName, groupName) @@ -168,19 +168,19 @@ void Foam::functionObjects::externalCoupled::removeWriteFiles() const Log << type() << ": removing all write files" << endl; - forAll(regionGroupNames_, regionI) + forAll(regionGroupNames_, regioni) { - const word& compName = regionGroupNames_[regionI]; + const word& compName = regionGroupNames_[regioni]; const labelList& groups = regionToGroups_[compName]; forAll(groups, i) { - label groupI = groups[i]; - const wordRe& groupName = groupNames_[groupI]; + label groupi = groups[i]; + const wordRe& groupName = groupNames_[groupi]; - forAll(groupReadFields_[groupI], fieldI) + forAll(groupReadFields_[groupi], fieldi) { - const word& fieldName = groupReadFields_[groupI][fieldI]; + const word& fieldName = groupReadFields_[groupi][fieldi]; rm ( groupDir(commsDir_, compName, groupName) @@ -252,20 +252,20 @@ void Foam::functionObjects::externalCoupled::readColumns // Read data from file and send to destination processor - for (label procI = 0; procI < Pstream::nProcs(); procI++) + for (label proci = 0; proci < Pstream::nProcs(); proci++) { // Temporary storage List values(nColumns); - // Number of rows to read for processor procI - label procNRows = globalFaces.localSize(procI); + // Number of rows to read for processor proci + label procNRows = globalFaces.localSize(proci); - forAll(values, columnI) + forAll(values, columni) { - values[columnI].setSize(procNRows); + values[columni].setSize(procNRows); } - for (label rowI = 0; rowI < procNRows; rowI++) + for (label rowi = 0; rowi < procNRows; rowi++) { // Get a line do @@ -273,8 +273,8 @@ void Foam::functionObjects::externalCoupled::readColumns if (!masterFilePtr().good()) { FatalIOErrorInFunction(masterFilePtr()) - << "Trying to read data for processor " << procI - << " row " << rowI + << "Trying to read data for processor " << proci + << " row " << rowi << ". Does your file have as many rows as there are" << " patch faces (" << globalFaces.size() << ") ?" << exit(FatalIOError); @@ -285,14 +285,14 @@ void Foam::functionObjects::externalCoupled::readColumns IStringStream lineStr(line); - for (label columnI = 0; columnI < nColumns; columnI++) + for (label columni = 0; columni < nColumns; columni++) { - lineStr >> values[columnI][rowI]; + lineStr >> values[columni][rowi]; } } - // Send to procI - UOPstream str(procI, pBufs); + // Send to proci + UOPstream str(proci, pBufs); str << values; } } @@ -322,14 +322,14 @@ void Foam::functionObjects::externalCoupled::readLines // Read line from file and send to destination processor - for (label procI = 0; procI < Pstream::nProcs(); procI++) + for (label proci = 0; proci < Pstream::nProcs(); proci++) { - // Number of rows to read for processor procI - label procNRows = globalFaces.localSize(procI); + // Number of rows to read for processor proci + label procNRows = globalFaces.localSize(proci); - UOPstream toProc(procI, pBufs); + UOPstream toProc(proci, pBufs); - for (label rowI = 0; rowI < procNRows; rowI++) + for (label rowi = 0; rowi < procNRows; rowi++) { // Get a line do @@ -337,8 +337,8 @@ void Foam::functionObjects::externalCoupled::readLines if (!masterFilePtr().good()) { FatalIOErrorInFunction(masterFilePtr()) - << "Trying to read data for processor " << procI - << " row " << rowI + << "Trying to read data for processor " << proci + << " row " << rowi << ". Does your file have as many rows as there are" << " patch faces (" << globalFaces.size() << ") ?" << exit(FatalIOError); @@ -358,7 +358,7 @@ void Foam::functionObjects::externalCoupled::readLines // Read lines from PstreamBuffers UIPstream str(Pstream::masterNo(), pBufs); - for (label rowI = 0; rowI < nRows; rowI++) + for (label rowi = 0; rowi < nRows; rowi++) { string line(str); lines << line.c_str() << nl; @@ -399,9 +399,9 @@ void Foam::functionObjects::externalCoupled::writeGeometry DynamicList allMeshesFaces; DynamicField allMeshesPoints; - forAll(meshes, meshI) + forAll(meshes, meshi) { - const fvMesh& mesh = meshes[meshI]; + const fvMesh& mesh = meshes[meshi]; const polyBoundaryMesh& pbm = mesh.boundaryMesh(); const labelList patchIDs @@ -422,9 +422,9 @@ void Foam::functionObjects::externalCoupled::writeGeometry { const polyPatch& p = pbm[patchIDs[i]]; - forAll(p, pI) + forAll(p, pi) { - allFaceIDs.append(p.start()+pI); + allFaceIDs.append(p.start()+pi); } } @@ -445,18 +445,18 @@ void Foam::functionObjects::externalCoupled::writeGeometry uniquePointIDs ); - label procI = Pstream::myProcNo(); + label proci = Pstream::myProcNo(); List collectedPoints(Pstream::nProcs()); - collectedPoints[procI] = pointField(mesh.points(), uniquePointIDs); + collectedPoints[proci] = pointField(mesh.points(), uniquePointIDs); Pstream::gatherList(collectedPoints); List collectedFaces(Pstream::nProcs()); - faceList& patchFaces = collectedFaces[procI]; + faceList& patchFaces = collectedFaces[proci]; patchFaces = allPatch.localFaces(); - forAll(patchFaces, faceI) + forAll(patchFaces, facei) { - inplaceRenumber(pointToGlobal, patchFaces[faceI]); + inplaceRenumber(pointToGlobal, patchFaces[facei]); } Pstream::gatherList(collectedFaces); @@ -465,19 +465,19 @@ void Foam::functionObjects::externalCoupled::writeGeometry // Append and renumber label nPoints = allMeshesPoints.size(); - forAll(collectedPoints, procI) + forAll(collectedPoints, proci) { - allMeshesPoints.append(collectedPoints[procI]); + allMeshesPoints.append(collectedPoints[proci]); } face newFace; - forAll(collectedFaces, procI) + forAll(collectedFaces, proci) { - const faceList& procFaces = collectedFaces[procI]; + const faceList& procFaces = collectedFaces[proci]; - forAll(procFaces, faceI) + forAll(procFaces, facei) { - const face& f = procFaces[faceI]; + const face& f = procFaces[facei]; newFace.setSize(f.size()); forAll(f, fp) @@ -487,7 +487,7 @@ void Foam::functionObjects::externalCoupled::writeGeometry allMeshesFaces.append(newFace); } - nPoints += collectedPoints[procI].size(); + nPoints += collectedPoints[proci].size(); } } @@ -573,10 +573,10 @@ void Foam::functionObjects::externalCoupled::checkOrder void Foam::functionObjects::externalCoupled::readData() { - forAll(regionGroupNames_, regionI) + forAll(regionGroupNames_, regioni) { - const word& compName = regionGroupNames_[regionI]; - const wordList& regionNames = regionGroupRegions_[regionI]; + const word& compName = regionGroupNames_[regioni]; + const wordList& regionNames = regionGroupRegions_[regioni]; // Get the meshes for the region-group UPtrList meshes(regionNames.size()); @@ -590,13 +590,13 @@ void Foam::functionObjects::externalCoupled::readData() forAll(groups, i) { - label groupI = groups[i]; - const wordRe& groupName = groupNames_[groupI]; - const wordList& fieldNames = groupReadFields_[groupI]; + label groupi = groups[i]; + const wordRe& groupName = groupNames_[groupi]; + const wordList& fieldNames = groupReadFields_[groupi]; - forAll(fieldNames, fieldI) + forAll(fieldNames, fieldi) { - const word& fieldName = fieldNames[fieldI]; + const word& fieldName = fieldNames[fieldi]; bool ok = readData ( @@ -643,10 +643,10 @@ void Foam::functionObjects::externalCoupled::readData() void Foam::functionObjects::externalCoupled::writeData() const { - forAll(regionGroupNames_, regionI) + forAll(regionGroupNames_, regioni) { - const word& compName = regionGroupNames_[regionI]; - const wordList& regionNames = regionGroupRegions_[regionI]; + const word& compName = regionGroupNames_[regioni]; + const wordList& regionNames = regionGroupRegions_[regioni]; // Get the meshes for the region-group UPtrList meshes(regionNames.size()); @@ -660,13 +660,13 @@ void Foam::functionObjects::externalCoupled::writeData() const forAll(groups, i) { - label groupI = groups[i]; - const wordRe& groupName = groupNames_[groupI]; - const wordList& fieldNames = groupWriteFields_[groupI]; + label groupi = groups[i]; + const wordRe& groupName = groupNames_[groupi]; + const wordList& fieldNames = groupWriteFields_[groupi]; - forAll(fieldNames, fieldI) + forAll(fieldNames, fieldi) { - const word& fieldName = fieldNames[fieldI]; + const word& fieldName = fieldNames[fieldi]; bool ok = writeData ( @@ -736,8 +736,8 @@ void Foam::functionObjects::externalCoupled::initialise() forAll(groups, i) { - label groupI = groups[i]; - const wordRe& groupName = groupNames_[groupI]; + label groupi = groups[i]; + const wordRe& groupName = groupNames_[groupi]; bool exists = false; if (Pstream::master()) @@ -938,26 +938,26 @@ bool Foam::functionObjects::externalCoupled::read(const dictionary& dict) if (log) { Info<< type() << ": Communicating with regions:" << endl; - forAll(regionGroupNames_, rgI) + forAll(regionGroupNames_, rgi) { - //const wordList& regionNames = regionGroupRegions_[rgI]; - const word& compName = regionGroupNames_[rgI]; + //const wordList& regionNames = regionGroupRegions_[rgi]; + const word& compName = regionGroupNames_[rgi]; Info<< "Region: " << compName << endl << incrIndent; const labelList& groups = regionToGroups_[compName]; forAll(groups, i) { - label groupI = groups[i]; - const wordRe& groupName = groupNames_[groupI]; + label groupi = groups[i]; + const wordRe& groupName = groupNames_[groupi]; Info<< indent << "patchGroup: " << groupName << "\t" << endl << incrIndent << indent << "Reading fields: " - << groupReadFields_[groupI] + << groupReadFields_[groupi] << endl << indent << "Writing fields: " - << groupWriteFields_[groupI] + << groupWriteFields_[groupi] << endl << decrIndent; } @@ -971,15 +971,15 @@ bool Foam::functionObjects::externalCoupled::read(const dictionary& dict) // should already be written - but just make sure if (Pstream::master()) { - forAll(regionGroupNames_, rgI) + forAll(regionGroupNames_, rgi) { - const word& compName = regionGroupNames_[rgI]; + const word& compName = regionGroupNames_[rgi]; const labelList& groups = regionToGroups_[compName]; forAll(groups, i) { - label groupI = groups[i]; - const wordRe& groupName = groupNames_[groupI]; + label groupi = groups[i]; + const wordRe& groupName = groupNames_[groupi]; fileName dir(groupDir(commsDir_, compName, groupName)); if (!isDir(dir)) diff --git a/src/functionObjects/field/externalCoupled/externalCoupledMixed/externalCoupledMixedFvPatchField.C b/src/functionObjects/field/externalCoupled/externalCoupledMixed/externalCoupledMixedFvPatchField.C index 17587fc9a5..84117274b0 100644 --- a/src/functionObjects/field/externalCoupled/externalCoupledMixed/externalCoupledMixedFvPatchField.C +++ b/src/functionObjects/field/externalCoupled/externalCoupledMixed/externalCoupledMixedFvPatchField.C @@ -126,13 +126,13 @@ void Foam::externalCoupledMixedFvPatchField::writeData const Field& refGrad(this->refGrad()); const scalarField& valueFraction(this->valueFraction()); - forAll(refValue, faceI) + forAll(refValue, facei) { - os << this->operator[](faceI) << token::SPACE - << snGrad[faceI] << token::SPACE - << refValue[faceI] << token::SPACE - << refGrad[faceI] << token::SPACE - << valueFraction[faceI] << nl; + os << this->operator[](facei) << token::SPACE + << snGrad[facei] << token::SPACE + << refValue[facei] << token::SPACE + << refGrad[facei] << token::SPACE + << valueFraction[facei] << nl; } } @@ -146,7 +146,7 @@ void Foam::externalCoupledMixedFvPatchField::readData(Istream& is) string line; - forAll(*this, faceI) + forAll(*this, facei) { iss.getLine(line); IStringStream lineStr(line); @@ -158,9 +158,9 @@ void Foam::externalCoupledMixedFvPatchField::readData(Istream& is) lineStr >> value >> snGrad - >> this->refValue()[faceI] - >> this->refGrad()[faceI] - >> this->valueFraction()[faceI]; + >> this->refValue()[facei] + >> this->refGrad()[facei] + >> this->valueFraction()[facei]; } } diff --git a/src/functionObjects/field/externalCoupled/externalCoupledTemperatureMixed/externalCoupledTemperatureMixedFvPatchScalarField.C b/src/functionObjects/field/externalCoupled/externalCoupledTemperatureMixed/externalCoupledTemperatureMixedFvPatchScalarField.C index b86ada4409..70128b8800 100644 --- a/src/functionObjects/field/externalCoupled/externalCoupledTemperatureMixed/externalCoupledTemperatureMixedFvPatchScalarField.C +++ b/src/functionObjects/field/externalCoupled/externalCoupledTemperatureMixed/externalCoupledTemperatureMixedFvPatchScalarField.C @@ -145,7 +145,7 @@ void Foam::externalCoupledTemperatureMixedFvPatchScalarField::writeData Ostream& os ) const { - const label patchI = patch().index(); + const label patchi = patch().index(); // Heat flux [W/m2] scalarField qDot(this->patch().size(), 0.0); @@ -170,17 +170,17 @@ void Foam::externalCoupledTemperatureMixedFvPatchScalarField::writeData const basicThermo& thermo = turbModel.transport(); - const fvPatchScalarField& hep = thermo.he().boundaryField()[patchI]; + const fvPatchScalarField& hep = thermo.he().boundaryField()[patchi]; - qDot = turbModel.alphaEff(patchI)*hep.snGrad(); + qDot = turbModel.alphaEff(patchi)*hep.snGrad(); } else if (db().foundObject(thermoName)) { const basicThermo& thermo = db().lookupObject(thermoName); - const fvPatchScalarField& hep = thermo.he().boundaryField()[patchI]; + const fvPatchScalarField& hep = thermo.he().boundaryField()[patchi]; - qDot = thermo.alpha().boundaryField()[patchI]*hep.snGrad(); + qDot = thermo.alpha().boundaryField()[patchi]*hep.snGrad(); } else { @@ -200,12 +200,12 @@ void Foam::externalCoupledTemperatureMixedFvPatchScalarField::writeData const Field& magSf(this->patch().magSf()); - forAll(patch(), faceI) + forAll(patch(), facei) { - os << magSf[faceI] << token::SPACE - << Tp[faceI] << token::SPACE - << qDot[faceI] << token::SPACE - << htc[faceI] << token::SPACE + os << magSf[facei] << token::SPACE + << Tp[facei] << token::SPACE + << qDot[facei] << token::SPACE + << htc[facei] << token::SPACE << nl; } } @@ -222,15 +222,15 @@ void Foam::externalCoupledTemperatureMixedFvPatchScalarField::readData string line; - forAll(*this, faceI) + forAll(*this, facei) { iss.getLine(line); IStringStream lineStr(line); lineStr - >> this->refValue()[faceI] - >> this->refGrad()[faceI] - >> this->valueFraction()[faceI]; + >> this->refValue()[facei] + >> this->refGrad()[facei] + >> this->valueFraction()[facei]; } } diff --git a/src/functionObjects/field/externalCoupled/externalCoupledTemplates.C b/src/functionObjects/field/externalCoupled/externalCoupledTemplates.C index 997dfffd3e..9daa4c49df 100644 --- a/src/functionObjects/field/externalCoupled/externalCoupledTemplates.C +++ b/src/functionObjects/field/externalCoupled/externalCoupledTemplates.C @@ -110,9 +110,9 @@ bool Foam::functionObjects::externalCoupled::readData // Handle column-wise reading of patch data. Supports most easy types forAll(patchIDs, i) { - label patchI = patchIDs[i]; + label patchi = patchIDs[i]; - if (isA(bf[patchI])) + if (isA(bf[patchi])) { // Explicit handling of externalCoupledMixed bcs - they // have specialised reading routines. @@ -121,7 +121,7 @@ bool Foam::functionObjects::externalCoupled::readData ( refCast ( - bf[patchI] + bf[patchi] ) ); @@ -129,7 +129,7 @@ bool Foam::functionObjects::externalCoupled::readData OStringStream os; readLines ( - bf[patchI].size(), // number of lines to read + bf[patchi].size(), // number of lines to read masterFilePtr, os ); @@ -141,14 +141,14 @@ bool Foam::functionObjects::externalCoupled::readData // additional processing by derived type. pf.patchFieldType::evaluate(); } - else if (isA>(bf[patchI])) + else if (isA>(bf[patchi])) { // Read columns from file for // value, snGrad, refValue, refGrad, valueFraction List data; readColumns ( - bf[patchI].size(), // number of lines to read + bf[patchi].size(), // number of lines to read 4*pTraits::nComponents+1, // nColumns: 4*Type+1*scalar masterFilePtr, data @@ -159,13 +159,13 @@ bool Foam::functionObjects::externalCoupled::readData ( refCast> ( - bf[patchI] + bf[patchi] ) ); // Transfer read data to bc. // Skip value, snGrad - direction columnI = 2*pTraits::nComponents; + direction columni = 2*pTraits::nComponents; Field& refValue = pf.refValue(); for @@ -175,7 +175,7 @@ bool Foam::functionObjects::externalCoupled::readData cmpt++ ) { - refValue.replace(cmpt, data[columnI++]); + refValue.replace(cmpt, data[columni++]); } Field& refGrad = pf.refGrad(); for @@ -185,21 +185,21 @@ bool Foam::functionObjects::externalCoupled::readData cmpt++ ) { - refGrad.replace(cmpt, data[columnI++]); + refGrad.replace(cmpt, data[columni++]); } - pf.valueFraction() = data[columnI]; + pf.valueFraction() = data[columni]; // Update the value from the read coefficicient. Bypass any // additional processing by derived type. pf.mixedFvPatchField::evaluate(); } - else if (isA>(bf[patchI])) + else if (isA>(bf[patchi])) { // Read columns for value and gradient List data; readColumns ( - bf[patchI].size(), // number of lines to read + bf[patchi].size(), // number of lines to read 2*pTraits::nComponents, // nColumns: Type masterFilePtr, data @@ -210,7 +210,7 @@ bool Foam::functionObjects::externalCoupled::readData ( refCast> ( - bf[patchI] + bf[patchi] ) ); @@ -234,20 +234,20 @@ bool Foam::functionObjects::externalCoupled::readData // additional processing by derived type. pf.fixedGradientFvPatchField::evaluate(); } - else if (isA>(bf[patchI])) + else if (isA>(bf[patchi])) { // Read columns for value only List data; readColumns ( - bf[patchI].size(), // number of lines to read + bf[patchi].size(), // number of lines to read pTraits::nComponents, // number of columns to read masterFilePtr, data ); // Transfer read value to bc - Field value(bf[patchI].size()); + Field value(bf[patchi].size()); for ( direction cmpt = 0; @@ -263,7 +263,7 @@ bool Foam::functionObjects::externalCoupled::readData ( refCast> ( - bf[patchI] + bf[patchi] ) ); @@ -276,8 +276,8 @@ bool Foam::functionObjects::externalCoupled::readData else { FatalErrorInFunction - << "Unsupported boundary condition " << bf[patchI].type() - << " for patch " << bf[patchI].patch().name() + << "Unsupported boundary condition " << bf[patchi].type() + << " for patch " << bf[patchi].patch().name() << " in region " << mesh.name() << exit(FatalError); } @@ -309,24 +309,24 @@ Foam::functionObjects::externalCoupled::gatherAndCombine if (Pstream::master()) { // Combine values into single field - label globalElemI = 0; + label globalElemi = 0; - forAll(gatheredValues, lstI) + forAll(gatheredValues, lsti) { - globalElemI += gatheredValues[lstI].size(); + globalElemi += gatheredValues[lsti].size(); } - result.setSize(globalElemI); + result.setSize(globalElemi); - globalElemI = 0; + globalElemi = 0; - forAll(gatheredValues, lstI) + forAll(gatheredValues, lsti) { - const Field& sub = gatheredValues[lstI]; + const Field& sub = gatheredValues[lsti]; - forAll(sub, elemI) + forAll(sub, elemi) { - result[globalElemI++] = sub[elemI]; + result[globalElemi++] = sub[elemi]; } } } @@ -408,18 +408,18 @@ bool Foam::functionObjects::externalCoupled::writeData // Handle column-wise writing of patch data. Supports most easy types forAll(patchIDs, i) { - label patchI = patchIDs[i]; + label patchi = patchIDs[i]; - const globalIndex globalFaces(bf[patchI].size()); + const globalIndex globalFaces(bf[patchi].size()); - if (isA(bf[patchI])) + if (isA(bf[patchi])) { // Explicit handling of externalCoupledMixed bcs - they // have specialised writing routines const patchFieldType& pf = refCast ( - bf[patchI] + bf[patchi] ); OStringStream os; @@ -438,9 +438,9 @@ bool Foam::functionObjects::externalCoupled::writeData } masterFilePtr() << os.str().c_str(); - for (label procI = 1; procI < Pstream::nProcs(); procI++) + for (label proci = 1; proci < Pstream::nProcs(); proci++) { - IPstream fromSlave(Pstream::scheduled, procI); + IPstream fromSlave(Pstream::scheduled, proci); string str(fromSlave); masterFilePtr() << str.c_str(); } @@ -451,10 +451,10 @@ bool Foam::functionObjects::externalCoupled::writeData toMaster << os.str(); } } - else if (isA>(bf[patchI])) + else if (isA>(bf[patchi])) { const mixedFvPatchField& pf = - refCast>(bf[patchI]); + refCast>(bf[patchi]); Field value(gatherAndCombine(pf)); Field snGrad(gatherAndCombine(pf.snGrad()())); @@ -464,29 +464,29 @@ bool Foam::functionObjects::externalCoupled::writeData if (Pstream::master()) { - forAll(refValue, faceI) + forAll(refValue, facei) { masterFilePtr() - << value[faceI] << token::SPACE - << snGrad[faceI] << token::SPACE - << refValue[faceI] << token::SPACE - << refGrad[faceI] << token::SPACE - << valueFraction[faceI] << nl; + << value[facei] << token::SPACE + << snGrad[facei] << token::SPACE + << refValue[facei] << token::SPACE + << refGrad[facei] << token::SPACE + << valueFraction[facei] << nl; } } } else { // Output the value and snGrad - Field value(gatherAndCombine(bf[patchI])); - Field snGrad(gatherAndCombine(bf[patchI].snGrad()())); + Field value(gatherAndCombine(bf[patchi])); + Field snGrad(gatherAndCombine(bf[patchi].snGrad()())); if (Pstream::master()) { - forAll(value, faceI) + forAll(value, facei) { masterFilePtr() - << value[faceI] << token::SPACE - << snGrad[faceI] << nl; + << value[facei] << token::SPACE + << snGrad[facei] << nl; } } } diff --git a/src/functionObjects/field/fieldMinMax/fieldMinMaxTemplates.C b/src/functionObjects/field/fieldMinMax/fieldMinMaxTemplates.C index d50548bc2d..691e313821 100644 --- a/src/functionObjects/field/fieldMinMax/fieldMinMaxTemplates.C +++ b/src/functionObjects/field/fieldMinMax/fieldMinMaxTemplates.C @@ -151,18 +151,18 @@ void Foam::functionObjects::fieldMinMax::calcMinMaxFields { const vectorField& Cfp = CfBoundary[patchi]; - label minPI = findMin(mfp); - if (mfp[minPI] < minVs[proci]) + label minPi = findMin(mfp); + if (mfp[minPi] < minVs[proci]) { - minVs[proci] = mfp[minPI]; - minCs[proci] = Cfp[minPI]; + minVs[proci] = mfp[minPi]; + minCs[proci] = Cfp[minPi]; } - label maxPI = findMax(mfp); - if (mfp[maxPI] > maxVs[proci]) + label maxPi = findMax(mfp); + if (mfp[maxPi] > maxVs[proci]) { - maxVs[proci] = mfp[maxPI]; - maxCs[proci] = Cfp[maxPI]; + maxVs[proci] = mfp[maxPi]; + maxCs[proci] = Cfp[maxPi]; } } } diff --git a/src/functionObjects/field/fieldValues/volFieldValue/volFieldValue.C b/src/functionObjects/field/fieldValues/volFieldValue/volFieldValue.C index faabae815f..b2f57b2b87 100644 --- a/src/functionObjects/field/fieldValues/volFieldValue/volFieldValue.C +++ b/src/functionObjects/field/fieldValues/volFieldValue/volFieldValue.C @@ -89,21 +89,20 @@ void Foam::functionObjects::fieldValues::volFieldValue::initialise void Foam::functionObjects::fieldValues::volFieldValue::writeFileHeader ( - const label i -) + Ostream& os +) const { - volRegion::writeFileHeader(*this, file()); + volRegion::writeFileHeader(*this, os); - writeCommented(file(), "Time"); + writeCommented(os, "Time"); forAll(fields_, fieldi) { - file() - << tab << operationTypeNames_[operation_] + os << tab << operationTypeNames_[operation_] << "(" << fields_[fieldi] << ")"; } - file() << endl; + os << endl; } @@ -122,6 +121,7 @@ Foam::functionObjects::fieldValues::volFieldValue::volFieldValue weightFieldName_("none") { read(dict); + writeFileHeader(file()); } diff --git a/src/functionObjects/field/fieldValues/volFieldValue/volFieldValue.H b/src/functionObjects/field/fieldValues/volFieldValue/volFieldValue.H index 69643720d8..adb7d4dcd9 100644 --- a/src/functionObjects/field/fieldValues/volFieldValue/volFieldValue.H +++ b/src/functionObjects/field/fieldValues/volFieldValue/volFieldValue.H @@ -189,7 +189,7 @@ protected: ) const; //- Output file header information - virtual void writeFileHeader(const label i); + virtual void writeFileHeader(Ostream& os) const; public: diff --git a/src/functionObjects/field/fluxSummary/fluxSummary.C b/src/functionObjects/field/fluxSummary/fluxSummary.C index 8067807697..33facd5d13 100644 --- a/src/functionObjects/field/fluxSummary/fluxSummary.C +++ b/src/functionObjects/field/fluxSummary/fluxSummary.C @@ -81,9 +81,9 @@ void Foam::functionObjects::fluxSummary::initialiseFaceZone { const fvMesh& mesh = refCast(obr_); - label zoneI = mesh.faceZones().findZoneID(faceZoneName); + label zonei = mesh.faceZones().findZoneID(faceZoneName); - if (zoneI == -1) + if (zonei == -1) { FatalErrorInFunction << "Unable to find faceZone " << faceZoneName @@ -93,7 +93,7 @@ void Foam::functionObjects::fluxSummary::initialiseFaceZone faceZoneNames.append(faceZoneName); - const faceZone& fZone = mesh.faceZones()[zoneI]; + const faceZone& fZone = mesh.faceZones()[zonei]; DynamicList