From ea0afd8a35de69217c6580b8bf0e213e24ccbbdd Mon Sep 17 00:00:00 2001 From: Kutalmis Bercin <kutalmis.bercin@esi-group.com> Date: Sat, 5 Jun 2021 14:32:03 +0100 Subject: [PATCH] ENH: lagrangian: split macros for CloudFunctionObjects three macros: - makeParcelCloudFunctionObjects for kinematic parcels - makeThermoParcelCloudFunctionObjects for thermo parcels - makeReactingParcelCloudFunctionObjects for reacting parcels --- ...asicHeterogeneousReactingParcelSubmodels.C | 6 +- ...keBasicReactingMultiphaseParcelSubmodels.C | 6 +- .../makeBasicReactingParcelSubmodels.C | 6 +- .../makeBasicThermoParcelSubmodels.C | 6 +- .../makeReactingParcelCloudFunctionObjects.H | 4 +- .../makeThermoParcelCloudFunctionObjects.H | 68 +++++++++++++++++++ .../makeBasicSprayParcelSubmodels.C | 6 +- 7 files changed, 85 insertions(+), 17 deletions(-) create mode 100644 src/lagrangian/intermediate/parcels/include/makeThermoParcelCloudFunctionObjects.H diff --git a/src/lagrangian/intermediate/parcels/derived/basicHeterogeneousReactingParcel/makeBasicHeterogeneousReactingParcelSubmodels.C b/src/lagrangian/intermediate/parcels/derived/basicHeterogeneousReactingParcel/makeBasicHeterogeneousReactingParcelSubmodels.C index c781eeb43df..6ab16be436e 100644 --- a/src/lagrangian/intermediate/parcels/derived/basicHeterogeneousReactingParcel/makeBasicHeterogeneousReactingParcelSubmodels.C +++ b/src/lagrangian/intermediate/parcels/derived/basicHeterogeneousReactingParcel/makeBasicHeterogeneousReactingParcelSubmodels.C @@ -5,7 +5,7 @@ \\ / A nd | www.openfoam.com \\/ M anipulation | ------------------------------------------------------------------------------- - Copyright (C) 2018-2020 OpenCFD Ltd. + Copyright (C) 2018-2021 OpenCFD Ltd. ------------------------------------------------------------------------------- License This file is part of OpenFOAM. @@ -27,7 +27,7 @@ License #include "basicHeterogeneousReactingCloud.H" -#include "makeParcelCloudFunctionObjects.H" +#include "makeReactingParcelCloudFunctionObjects.H" // Kinematic #include "makeThermoParcelForces.H" // thermo variant @@ -52,7 +52,7 @@ License // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // -makeParcelCloudFunctionObjects(basicHeterogeneousReactingCloud); +makeReactingParcelCloudFunctionObjects(basicHeterogeneousReactingCloud); // Kinematic sub-models makeThermoParcelForces(basicHeterogeneousReactingCloud); diff --git a/src/lagrangian/intermediate/parcels/derived/basicReactingMultiphaseParcel/makeBasicReactingMultiphaseParcelSubmodels.C b/src/lagrangian/intermediate/parcels/derived/basicReactingMultiphaseParcel/makeBasicReactingMultiphaseParcelSubmodels.C index f866646f830..5b7a3623da5 100644 --- a/src/lagrangian/intermediate/parcels/derived/basicReactingMultiphaseParcel/makeBasicReactingMultiphaseParcelSubmodels.C +++ b/src/lagrangian/intermediate/parcels/derived/basicReactingMultiphaseParcel/makeBasicReactingMultiphaseParcelSubmodels.C @@ -6,7 +6,7 @@ \\/ M anipulation | ------------------------------------------------------------------------------- Copyright (C) 2011-2015 OpenFOAM Foundation - Copyright (C) 2020 OpenCFD Ltd. + Copyright (C) 2020-2021 OpenCFD Ltd. ------------------------------------------------------------------------------- License This file is part of OpenFOAM. @@ -28,7 +28,7 @@ License #include "basicReactingMultiphaseCloud.H" -#include "makeReactingParcelCloudFunctionObjects.H" // Reacting variant +#include "makeReactingParcelCloudFunctionObjects.H" // Kinematic #include "makeThermoParcelForces.H" // thermo variant @@ -56,7 +56,7 @@ License // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // -makeParcelCloudFunctionObjects(basicReactingMultiphaseCloud); +makeReactingParcelCloudFunctionObjects(basicReactingMultiphaseCloud); // Kinematic sub-models makeThermoParcelForces(basicReactingMultiphaseCloud); diff --git a/src/lagrangian/intermediate/parcels/derived/basicReactingParcel/makeBasicReactingParcelSubmodels.C b/src/lagrangian/intermediate/parcels/derived/basicReactingParcel/makeBasicReactingParcelSubmodels.C index 9ae9230a565..bc7844de595 100644 --- a/src/lagrangian/intermediate/parcels/derived/basicReactingParcel/makeBasicReactingParcelSubmodels.C +++ b/src/lagrangian/intermediate/parcels/derived/basicReactingParcel/makeBasicReactingParcelSubmodels.C @@ -6,7 +6,7 @@ \\/ M anipulation | ------------------------------------------------------------------------------- Copyright (C) 2011-2015 OpenFOAM Foundation - Copyright (C) 2020 OpenCFD Ltd. + Copyright (C) 2020-2021 OpenCFD Ltd. ------------------------------------------------------------------------------- License This file is part of OpenFOAM. @@ -28,7 +28,7 @@ License #include "basicReactingCloud.H" -#include "makeReactingParcelCloudFunctionObjects.H" // Reacting variant +#include "makeReactingParcelCloudFunctionObjects.H" // Kinematic #include "makeThermoParcelForces.H" // thermo variant @@ -52,7 +52,7 @@ License // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // -makeParcelCloudFunctionObjects(basicReactingCloud); +makeReactingParcelCloudFunctionObjects(basicReactingCloud); // Kinematic sub-models makeThermoParcelForces(basicReactingCloud); diff --git a/src/lagrangian/intermediate/parcels/derived/basicThermoParcel/makeBasicThermoParcelSubmodels.C b/src/lagrangian/intermediate/parcels/derived/basicThermoParcel/makeBasicThermoParcelSubmodels.C index e740fad6855..1a360b94e1e 100644 --- a/src/lagrangian/intermediate/parcels/derived/basicThermoParcel/makeBasicThermoParcelSubmodels.C +++ b/src/lagrangian/intermediate/parcels/derived/basicThermoParcel/makeBasicThermoParcelSubmodels.C @@ -6,7 +6,7 @@ \\/ M anipulation | ------------------------------------------------------------------------------- Copyright (C) 2011-2015 OpenFOAM Foundation - Copyright (C) 2020 OpenCFD Ltd. + Copyright (C) 2020-2021 OpenCFD Ltd. ------------------------------------------------------------------------------- License This file is part of OpenFOAM. @@ -28,7 +28,7 @@ License #include "basicThermoCloud.H" -#include "makeParcelCloudFunctionObjects.H" +#include "makeThermoParcelCloudFunctionObjects.H" // Kinematic #include "makeThermoParcelForces.H" // thermo variant @@ -48,7 +48,7 @@ License // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // -makeParcelCloudFunctionObjects(basicThermoCloud); +makeThermoParcelCloudFunctionObjects(basicThermoCloud); // Kinematic sub-models makeThermoParcelForces(basicThermoCloud); diff --git a/src/lagrangian/intermediate/parcels/include/makeReactingParcelCloudFunctionObjects.H b/src/lagrangian/intermediate/parcels/include/makeReactingParcelCloudFunctionObjects.H index cd1eb439c96..a53731492c4 100644 --- a/src/lagrangian/intermediate/parcels/include/makeReactingParcelCloudFunctionObjects.H +++ b/src/lagrangian/intermediate/parcels/include/makeReactingParcelCloudFunctionObjects.H @@ -6,7 +6,7 @@ \\/ M anipulation | ------------------------------------------------------------------------------- Copyright (C) 2011-2018 OpenFOAM Foundation - Copyright (C) 2020 OpenCFD Ltd. + Copyright (C) 2020-2021 OpenCFD Ltd. ------------------------------------------------------------------------------- License This file is part of OpenFOAM. @@ -46,7 +46,7 @@ License // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // -#define makeParcelCloudFunctionObjects(CloudType) \ +#define makeReactingParcelCloudFunctionObjects(CloudType) \ \ makeCloudFunctionObject(CloudType); \ \ diff --git a/src/lagrangian/intermediate/parcels/include/makeThermoParcelCloudFunctionObjects.H b/src/lagrangian/intermediate/parcels/include/makeThermoParcelCloudFunctionObjects.H new file mode 100644 index 00000000000..00816ea32a0 --- /dev/null +++ b/src/lagrangian/intermediate/parcels/include/makeThermoParcelCloudFunctionObjects.H @@ -0,0 +1,68 @@ +/*---------------------------------------------------------------------------*\ + ========= | + \\ / F ield | OpenFOAM: The Open Source CFD Toolbox + \\ / O peration | + \\ / A nd | www.openfoam.com + \\/ M anipulation | +------------------------------------------------------------------------------- + Copyright (C) 2021 OpenCFD Ltd. +------------------------------------------------------------------------------- +License + This file is part of OpenFOAM. + + OpenFOAM is free software: you can redistribute it and/or modify it + under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + OpenFOAM is distributed in the hope that it will be useful, but WITHOUT + ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + for more details. + + You should have received a copy of the GNU General Public License + along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>. + +\*---------------------------------------------------------------------------*/ + +#ifndef makeThermoParcelCloudFunctionObjects_H +#define makeThermoParcelCloudFunctionObjects_H + +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +#include "FacePostProcessing.H" +#include "ParticleCollector.H" +#include "ParticleErosion.H" +#include "ParticleTracks.H" +#include "ParticleTrap.H" +#include "PatchCollisionDensity.H" +#include "PatchInteractionFields.H" +#include "PatchPostProcessing.H" +#include "PatchParticleHistogram.H" +#include "RemoveParcels.H" +#include "VoidFraction.H" + +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +#define makeThermoParcelCloudFunctionObjects(CloudType) \ + \ + makeCloudFunctionObject(CloudType); \ + \ + makeCloudFunctionObjectType(FacePostProcessing, CloudType); \ + makeCloudFunctionObjectType(ParticleCollector, CloudType); \ + makeCloudFunctionObjectType(ParticleErosion, CloudType); \ + makeCloudFunctionObjectType(ParticleTracks, CloudType); \ + makeCloudFunctionObjectType(ParticleTrap, CloudType); \ + makeCloudFunctionObjectType(PatchCollisionDensity, CloudType); \ + makeCloudFunctionObjectType(PatchInteractionFields, CloudType); \ + makeCloudFunctionObjectType(PatchPostProcessing, CloudType); \ + makeCloudFunctionObjectType(PatchParticleHistogram, CloudType); \ + makeCloudFunctionObjectType(RemoveParcels, CloudType); \ + makeCloudFunctionObjectType(VoidFraction, CloudType); + + +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +#endif + +// ************************************************************************* // diff --git a/src/lagrangian/spray/parcels/derived/basicSprayParcel/makeBasicSprayParcelSubmodels.C b/src/lagrangian/spray/parcels/derived/basicSprayParcel/makeBasicSprayParcelSubmodels.C index c49daade006..67e601d5595 100644 --- a/src/lagrangian/spray/parcels/derived/basicSprayParcel/makeBasicSprayParcelSubmodels.C +++ b/src/lagrangian/spray/parcels/derived/basicSprayParcel/makeBasicSprayParcelSubmodels.C @@ -6,7 +6,7 @@ \\/ M anipulation | ------------------------------------------------------------------------------- Copyright (C) 2011-2015 OpenFOAM Foundation - Copyright (C) 2020 OpenCFD Ltd. + Copyright (C) 2020-2021 OpenCFD Ltd. ------------------------------------------------------------------------------- License This file is part of OpenFOAM. @@ -28,7 +28,7 @@ License #include "basicSprayCloud.H" -#include "makeReactingParcelCloudFunctionObjects.H" // Reacting variant +#include "makeReactingParcelCloudFunctionObjects.H" // Kinematic #include "makeThermoParcelForces.H" // thermo variant @@ -59,7 +59,7 @@ License // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // -makeParcelCloudFunctionObjects(basicSprayCloud); +makeReactingParcelCloudFunctionObjects(basicSprayCloud); // Kinematic sub-models makeThermoParcelForces(basicSprayCloud); -- GitLab