diff --git a/applications/solvers/combustion/XiFoam/XiEngineFoam/XiEngineFoam.C b/applications/solvers/combustion/XiFoam/XiEngineFoam/XiEngineFoam.C
index 4149fa9f81..e44d74a6dc 100644
--- a/applications/solvers/combustion/XiFoam/XiEngineFoam/XiEngineFoam.C
+++ b/applications/solvers/combustion/XiFoam/XiEngineFoam/XiEngineFoam.C
@@ -79,7 +79,7 @@ int main(int argc, char *argv[])
#include "createFieldRefs.H"
#include "createRhoUf.H"
#include "initContinuityErrs.H"
- #include "readEngineTimeControls.H"
+ #include "createEngineTimeControls.H"
#include "compressibleCourantNo.H"
#include "setInitialDeltaT.H"
#include "startSummary.H"
diff --git a/applications/solvers/combustion/coldEngineFoam/coldEngineFoam.C b/applications/solvers/combustion/coldEngineFoam/coldEngineFoam.C
index 2230b572ee..3783cbf21d 100644
--- a/applications/solvers/combustion/coldEngineFoam/coldEngineFoam.C
+++ b/applications/solvers/combustion/coldEngineFoam/coldEngineFoam.C
@@ -55,7 +55,7 @@ int main(int argc, char *argv[])
#include "createFieldRefs.H"
#include "createRhoUf.H"
#include "initContinuityErrs.H"
- #include "readEngineTimeControls.H"
+ #include "createEngineTimeControls.H"
#include "compressibleCourantNo.H"
#include "setInitialDeltaT.H"
#include "startSummary.H"
diff --git a/applications/solvers/combustion/fireFoam/Make/options b/applications/solvers/combustion/fireFoam/Make/options
index 85f90f3232..bddc3aa373 100644
--- a/applications/solvers/combustion/fireFoam/Make/options
+++ b/applications/solvers/combustion/fireFoam/Make/options
@@ -18,7 +18,7 @@ EXE_INC = \
-I$(LIB_SRC)/regionModels/regionModel/lnInclude \
-I$(LIB_SRC)/regionModels/surfaceFilmModels/lnInclude \
-I$(LIB_SRC)/lagrangian/basic/lnInclude \
- -I$(LIB_SRC)/lagrangian/intermediate/lnInclude \
+ -I$(LIB_SRC)/lagrangian/parcel/lnInclude \
-I$(LIB_SRC)/ODE/lnInclude
EXE_LIBS = \
@@ -40,6 +40,6 @@ EXE_LIBS = \
-lradiationModels \
-lsurfaceFilmModels \
-lsurfaceFilmDerivedFvPatchFields \
- -llagrangianIntermediate \
- -llagrangianTurbulence \
+ -llagrangianParcel \
+ -llagrangianParcelTurbulence \
-lODE
diff --git a/applications/solvers/combustion/fireFoam/createClouds.H b/applications/solvers/combustion/fireFoam/createClouds.H
index c568be12a1..8ea23b2181 100644
--- a/applications/solvers/combustion/fireFoam/createClouds.H
+++ b/applications/solvers/combustion/fireFoam/createClouds.H
@@ -1,9 +1,2 @@
-Info<< "\nConstructing reacting cloud" << endl;
-basicReactingCloud parcels
-(
- "reactingCloud1",
- rho,
- U,
- g,
- slgThermo
-);
+Info<< "\nConstructing clouds" << endl;
+parcelCloudList parcels(rho, U, g, slgThermo);
diff --git a/applications/solvers/combustion/fireFoam/fireFoam.C b/applications/solvers/combustion/fireFoam/fireFoam.C
index d8a6faa145..8234d82ae3 100644
--- a/applications/solvers/combustion/fireFoam/fireFoam.C
+++ b/applications/solvers/combustion/fireFoam/fireFoam.C
@@ -33,7 +33,7 @@ Description
#include "fvCFD.H"
#include "fluidThermoMomentumTransportModel.H"
#include "psiReactionThermophysicalTransportModel.H"
-#include "basicReactingCloud.H"
+#include "parcelCloudList.H"
#include "surfaceFilmModel.H"
#include "radiationModel.H"
#include "SLGThermo.H"
diff --git a/applications/solvers/lagrangian/DPMFoam/DPMFoam.C b/applications/solvers/lagrangian/DPMFoam/DPMFoam.C
deleted file mode 100644
index f0fb67f3ca..0000000000
--- a/applications/solvers/lagrangian/DPMFoam/DPMFoam.C
+++ /dev/null
@@ -1,171 +0,0 @@
-/*---------------------------------------------------------------------------*\
- ========= |
- \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
- \\ / O peration | Website: https://openfoam.org
- \\ / A nd | Copyright (C) 2013-2020 OpenFOAM Foundation
- \\/ M anipulation |
--------------------------------------------------------------------------------
-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 .
-
-Application
- DPMFoam
-
-Description
- Transient solver for the coupled transport of a single kinematic particle
- cloud including the effect of the volume fraction of particles on the
- continuous phase, with optional mesh motion and mesh topology changes.
-
-\*---------------------------------------------------------------------------*/
-
-#include "fvCFD.H"
-#include "dynamicFvMesh.H"
-#include "singlePhaseTransportModel.H"
-#include "PhaseIncompressibleMomentumTransportModel.H"
-#include "pimpleControl.H"
-#include "CorrectPhi.H"
-#include "fvOptions.H"
-
-#ifdef MPPIC
- #include "basicKinematicMPPICCloud.H"
- #define basicKinematicTypeCloud basicKinematicMPPICCloud
-#else
- #include "basicKinematicCollidingCloud.H"
- #define basicKinematicTypeCloud basicKinematicCollidingCloud
-#endif
-
-int main(int argc, char *argv[])
-{
- argList::addOption
- (
- "cloudName",
- "name",
- "specify alternative cloud name. default is 'kinematicCloud'"
- );
-
- #include "postProcess.H"
-
- #include "setRootCaseLists.H"
- #include "createTime.H"
- #include "createDynamicFvMesh.H"
- #include "createDyMControls.H"
- #include "createFields.H"
- #include "createUcfIfPresent.H"
- #include "initContinuityErrs.H"
-
- Info<< "\nStarting time loop\n" << endl;
-
- while (pimple.run(runTime))
- {
- #include "readDyMControls.H"
- #include "CourantNo.H"
- #include "setDeltaT.H"
-
- runTime++;
-
- Info<< "Time = " << runTime.timeName() << nl << endl;
-
- // Store the particle positions
- kinematicCloud.storeGlobalPositions();
-
- mesh.update();
-
- if (mesh.changing())
- {
- if (correctPhi)
- {
- // Calculate absolute flux from the mapped surface velocity
- phic = mesh.Sf() & Ucf();
-
- #include "correctPhic.H"
-
- // Make the flux relative to the mesh motion
- fvc::makeRelative(phic, Uc);
- }
-
- if (checkMeshCourantNo)
- {
- #include "meshCourantNo.H"
- }
- }
-
- continuousPhaseTransport.correct();
- muc = rhoc*continuousPhaseTransport.nu();
-
- Info<< "Evolving " << kinematicCloud.name() << endl;
- kinematicCloud.evolve();
-
- // Update continuous phase volume fraction field
- alphac = max(1.0 - kinematicCloud.theta(), alphacMin);
- alphac.correctBoundaryConditions();
- alphacf = fvc::interpolate(alphac);
- alphaPhic = alphacf*phic;
-
- fvVectorMatrix cloudSU(kinematicCloud.SU(Uc));
- volVectorField cloudVolSUSu
- (
- IOobject
- (
- "cloudVolSUSu",
- runTime.timeName(),
- mesh
- ),
- mesh,
- dimensionedVector
- (
- "0",
- cloudSU.dimensions()/dimVolume,
- Zero
- ),
- zeroGradientFvPatchVectorField::typeName
- );
-
- cloudVolSUSu.primitiveFieldRef() =
- (cloudSU.diag()*Uc() - cloudSU.source())/mesh.V();
- cloudVolSUSu.correctBoundaryConditions();
- cloudSU.source() = cloudSU.diag()*Uc();
-
- // --- Pressure-velocity PIMPLE corrector loop
- while (pimple.loop())
- {
- #include "UcEqn.H"
-
- // --- PISO loop
- while (pimple.correct())
- {
- #include "pEqn.H"
- }
-
- if (pimple.turbCorr())
- {
- continuousPhaseTurbulence->correct();
- }
- }
-
- runTime.write();
-
- Info<< "ExecutionTime = " << runTime.elapsedCpuTime() << " s"
- << " ClockTime = " << runTime.elapsedClockTime() << " s"
- << nl << endl;
- }
-
- Info<< "End\n" << endl;
-
- return 0;
-}
-
-
-// ************************************************************************* //
diff --git a/applications/solvers/lagrangian/DPMFoam/DPMMomentumTransportModels/Make/files b/applications/solvers/lagrangian/DPMFoam/DPMMomentumTransportModels/Make/files
deleted file mode 100644
index d7245a6438..0000000000
--- a/applications/solvers/lagrangian/DPMFoam/DPMMomentumTransportModels/Make/files
+++ /dev/null
@@ -1,3 +0,0 @@
-DPMMomentumTransportModels.C
-
-LIB = $(FOAM_LIBBIN)/libDPMMomentumTransportModels
diff --git a/applications/solvers/lagrangian/DPMFoam/MPPICFoam/MPPICFoam.C b/applications/solvers/lagrangian/DPMFoam/MPPICFoam/MPPICFoam.C
deleted file mode 100644
index eae7b96eec..0000000000
--- a/applications/solvers/lagrangian/DPMFoam/MPPICFoam/MPPICFoam.C
+++ /dev/null
@@ -1,40 +0,0 @@
-/*---------------------------------------------------------------------------*\
- ========= |
- \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
- \\ / O peration | Website: https://openfoam.org
- \\ / A nd | Copyright (C) 2013-2018 OpenFOAM Foundation
- \\/ M anipulation |
--------------------------------------------------------------------------------
-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 .
-
-Application
- MPPICFoam
-
-Description
- Transient solver for the coupled transport of a single kinematic particle
- cloud including the effect of the volume fraction of particles on the
- continuous phase. Multi-Phase Particle In Cell (MPPIC) modeling is used to
- represent collisions without resolving particle-particle interactions.
-
-\*---------------------------------------------------------------------------*/
-
-#define MPPIC
-
-#include "DPMFoam.C"
-
-
-// ************************************************************************* //
diff --git a/applications/solvers/lagrangian/DPMFoam/MPPICFoam/Make/files b/applications/solvers/lagrangian/DPMFoam/MPPICFoam/Make/files
deleted file mode 100644
index d311f5a33c..0000000000
--- a/applications/solvers/lagrangian/DPMFoam/MPPICFoam/Make/files
+++ /dev/null
@@ -1,3 +0,0 @@
-MPPICFoam.C
-
-EXE = $(FOAM_APPBIN)/MPPICFoam
diff --git a/applications/solvers/lagrangian/DPMFoam/Make/files b/applications/solvers/lagrangian/DPMFoam/Make/files
deleted file mode 100644
index c4d729205d..0000000000
--- a/applications/solvers/lagrangian/DPMFoam/Make/files
+++ /dev/null
@@ -1,3 +0,0 @@
-DPMFoam.C
-
-EXE = $(FOAM_APPBIN)/DPMFoam
diff --git a/applications/solvers/lagrangian/DPMFoam/Make/options b/applications/solvers/lagrangian/DPMFoam/Make/options
deleted file mode 100644
index 8553deca6e..0000000000
--- a/applications/solvers/lagrangian/DPMFoam/Make/options
+++ /dev/null
@@ -1,31 +0,0 @@
-EXE_INC = \
- -I./DPMMomentumTransportModels/lnInclude \
- -I$(LIB_SRC)/lagrangian/basic/lnInclude \
- -I$(LIB_SRC)/lagrangian/intermediate/lnInclude \
- -I$(LIB_SRC)/thermophysicalModels/specie/lnInclude \
- -I$(LIB_SRC)/thermophysicalModels/basic/lnInclude \
- -I$(LIB_SRC)/thermophysicalModels/reactionThermo/lnInclude \
- -I$(LIB_SRC)/radiationModels/lnInclude \
- -I$(LIB_SRC)/transportModels/lnInclude \
- -I$(LIB_SRC)/MomentumTransportModels/momentumTransportModels/lnInclude \
- -I$(LIB_SRC)/MomentumTransportModels/incompressible/lnInclude \
- -I$(LIB_SRC)/MomentumTransportModels/phaseIncompressible/lnInclude \
- -I$(LIB_SRC)/regionModels/regionModel/lnInclude \
- -I$(LIB_SRC)/regionModels/surfaceFilmModels/lnInclude \
- -I$(LIB_SRC)/finiteVolume/lnInclude \
- -I$(LIB_SRC)/dynamicFvMesh/lnInclude \
- -I$(LIB_SRC)/meshTools/lnInclude
-
-EXE_LIBS = \
- -llagrangian \
- -llagrangianIntermediate \
- -llagrangianTurbulence \
- -lincompressibleTransportModels \
- -lmomentumTransportModels \
- -lincompressibleMomentumTransportModels \
- -lDPMMomentumTransportModels \
- -lfiniteVolume \
- -ldynamicFvMesh \
- -ltopoChangerFvMesh \
- -lfvOptions \
- -lmeshTools
diff --git a/applications/solvers/lagrangian/coalChemistryFoam/EEqn.H b/applications/solvers/lagrangian/coalChemistryFoam/EEqn.H
deleted file mode 100644
index 26308cb160..0000000000
--- a/applications/solvers/lagrangian/coalChemistryFoam/EEqn.H
+++ /dev/null
@@ -1,41 +0,0 @@
-{
- volScalarField& he = thermo.he();
-
- fvScalarMatrix EEqn
- (
- fvm::ddt(rho, he) + mvConvection->fvmDiv(phi, he)
- + fvc::ddt(rho, K) + fvc::div(phi, K)
- + (
- he.name() == "e"
- ? fvc::div
- (
- fvc::absolute(phi/fvc::interpolate(rho), U),
- p,
- "div(phiv,p)"
- )
- : -dpdt
- )
- + thermophysicalTransport->divq(he)
- ==
- rho*(U&g)
- + combustion->Qdot()
- + coalParcels.Sh(he)
- + limestoneParcels.Sh(he)
- + radiation->Sh(thermo, he)
- + fvOptions(rho, he)
- );
-
- EEqn.relax();
-
- fvOptions.constrain(EEqn);
-
- EEqn.solve();
-
- fvOptions.correct(he);
-
- thermo.correct();
- radiation->correct();
-
- Info<< "T gas min/max = " << min(T).value() << ", "
- << max(T).value() << endl;
-}
diff --git a/applications/solvers/lagrangian/coalChemistryFoam/Make/files b/applications/solvers/lagrangian/coalChemistryFoam/Make/files
deleted file mode 100644
index 552d734501..0000000000
--- a/applications/solvers/lagrangian/coalChemistryFoam/Make/files
+++ /dev/null
@@ -1,3 +0,0 @@
-coalChemistryFoam.C
-
-EXE = $(FOAM_APPBIN)/coalChemistryFoam
diff --git a/applications/solvers/lagrangian/coalChemistryFoam/Make/options b/applications/solvers/lagrangian/coalChemistryFoam/Make/options
deleted file mode 100644
index b2adc8faae..0000000000
--- a/applications/solvers/lagrangian/coalChemistryFoam/Make/options
+++ /dev/null
@@ -1,49 +0,0 @@
-EXE_INC = \
- -I$(LIB_SRC)/finiteVolume/lnInclude \
- -I$(LIB_SRC)/meshTools/lnInclude \
- -I$(LIB_SRC)/MomentumTransportModels/momentumTransportModels/lnInclude \
- -I$(LIB_SRC)/MomentumTransportModels/compressible/lnInclude \
- -I$(LIB_SRC)/ThermophysicalTransportModels/lnInclude \
- -I$(LIB_SRC)/ThermophysicalTransportModels/psiReactionThermo/lnInclude \
- -I$(LIB_SRC)/lagrangian/basic/lnInclude \
- -I$(LIB_SRC)/lagrangian/intermediate/lnInclude \
- -I$(LIB_SRC)/lagrangian/coalCombustion/lnInclude \
- -I$(LIB_SRC)/lagrangian/distributionModels/lnInclude \
- -I$(LIB_SRC)/thermophysicalModels/specie/lnInclude \
- -I$(LIB_SRC)/thermophysicalModels/basic/lnInclude \
- -I$(LIB_SRC)/thermophysicalModels/thermophysicalProperties/lnInclude \
- -I$(LIB_SRC)/thermophysicalModels/reactionThermo/lnInclude \
- -I$(LIB_SRC)/thermophysicalModels/SLGThermo/lnInclude \
- -I$(LIB_SRC)/thermophysicalModels/chemistryModel/lnInclude \
- -I$(LIB_SRC)/radiationModels/lnInclude \
- -I$(LIB_SRC)/regionModels/regionModel/lnInclude \
- -I$(LIB_SRC)/regionModels/surfaceFilmModels/lnInclude \
- -I$(LIB_SRC)/ODE/lnInclude \
- -I$(LIB_SRC)/combustionModels/lnInclude \
- -I$(FOAM_SOLVERS)/combustion/reactingFoam \
- -I$(LIB_SRC)/sampling/lnInclude
-
-EXE_LIBS = \
- -lfiniteVolume \
- -lmeshTools \
- -lmomentumTransportModels \
- -lfluidThermoMomentumTransportModels \
- -lthermophysicalTransportModels \
- -lpsiReactionThermophysicalTransportModels \
- -llagrangian \
- -llagrangianIntermediate \
- -llagrangianTurbulence \
- -lcoalCombustion\
- -lspecie \
- -lfluidThermophysicalModels \
- -lthermophysicalProperties \
- -lreactionThermophysicalModels \
- -lSLGThermo \
- -lchemistryModel \
- -lradiationModels \
- -lregionModels \
- -lsurfaceFilmModels \
- -lODE \
- -lcombustionModels \
- -lfvOptions \
- -lsampling
diff --git a/applications/solvers/lagrangian/coalChemistryFoam/YEqn.H b/applications/solvers/lagrangian/coalChemistryFoam/YEqn.H
deleted file mode 100644
index 04ff49768b..0000000000
--- a/applications/solvers/lagrangian/coalChemistryFoam/YEqn.H
+++ /dev/null
@@ -1,49 +0,0 @@
-tmp> mvConvection
-(
- fv::convectionScheme::New
- (
- mesh,
- fields,
- phi,
- mesh.divScheme("div(phi,Yi_h)")
- )
-);
-
-
-{
- combustion->correct();
- volScalarField Yt(0.0*Y[0]);
-
- forAll(Y, i)
- {
- if (i != inertIndex && composition.active(i))
- {
- volScalarField& Yi = Y[i];
-
- fvScalarMatrix YiEqn
- (
- fvm::ddt(rho, Yi)
- + mvConvection->fvmDiv(phi, Yi)
- + thermophysicalTransport->divj(Yi)
- ==
- coalParcels.SYi(i, Yi)
- + combustion->R(Yi)
- + fvOptions(rho, Yi)
- );
-
- YiEqn.relax();
-
- fvOptions.constrain(YiEqn);
-
- YiEqn.solve("Yi");
-
- fvOptions.correct(Yi);
-
- Yi.max(0.0);
- Yt += Yi;
- }
- }
-
- Y[inertIndex] = scalar(1) - Yt;
- Y[inertIndex].max(0.0);
-}
diff --git a/applications/solvers/lagrangian/coalChemistryFoam/createClouds.H b/applications/solvers/lagrangian/coalChemistryFoam/createClouds.H
deleted file mode 100644
index 5dcfe1df4f..0000000000
--- a/applications/solvers/lagrangian/coalChemistryFoam/createClouds.H
+++ /dev/null
@@ -1,19 +0,0 @@
-Info<< "\nConstructing coal cloud" << endl;
-coalCloud coalParcels
-(
- "coalCloud1",
- rho,
- U,
- g,
- slgThermo
-);
-
-Info<< "\nConstructing limestone cloud" << endl;
-basicThermoCloud limestoneParcels
-(
- "limestoneCloud1",
- rho,
- U,
- g,
- slgThermo
-);
diff --git a/applications/solvers/lagrangian/coalChemistryFoam/createFieldRefs.H b/applications/solvers/lagrangian/coalChemistryFoam/createFieldRefs.H
deleted file mode 100644
index 4748421aa4..0000000000
--- a/applications/solvers/lagrangian/coalChemistryFoam/createFieldRefs.H
+++ /dev/null
@@ -1 +0,0 @@
-const label inertIndex(composition.species()[inertSpecie]);
diff --git a/applications/solvers/lagrangian/coalChemistryFoam/createFields.H b/applications/solvers/lagrangian/coalChemistryFoam/createFields.H
deleted file mode 100644
index 0c51864b8d..0000000000
--- a/applications/solvers/lagrangian/coalChemistryFoam/createFields.H
+++ /dev/null
@@ -1,141 +0,0 @@
-#include "createRDeltaT.H"
-
-#include "readGravitationalAcceleration.H"
-
-Info<< "Reading thermophysical properties\n" << endl;
-autoPtr pThermo(psiReactionThermo::New(mesh));
-psiReactionThermo& thermo = pThermo();
-thermo.validate(args.executable(), "h", "e");
-
-SLGThermo slgThermo(mesh, thermo);
-
-basicSpecieMixture& composition = thermo.composition();
-PtrList& Y = composition.Y();
-
-const word inertSpecie(thermo.lookup("inertSpecie"));
-if (!composition.species().found(inertSpecie))
-{
- FatalIOErrorIn(args.executable().c_str(), thermo)
- << "Inert specie " << inertSpecie << " not found in available species "
- << composition.species()
- << exit(FatalIOError);
-}
-
-volScalarField& p = thermo.p();
-const volScalarField& T = thermo.T();
-const volScalarField& psi = thermo.psi();
-
-multivariateSurfaceInterpolationScheme::fieldTable fields;
-
-forAll(Y, i)
-{
- fields.add(Y[i]);
-}
-fields.add(thermo.he());
-
-volScalarField rho
-(
- IOobject
- (
- "rho",
- runTime.timeName(),
- mesh,
- IOobject::NO_READ,
- IOobject::AUTO_WRITE
- ),
- thermo.rho()
-);
-
-// lagrangian effective density field - used externally (optional)
-volScalarField rhoEffLagrangian
-(
- IOobject
- (
- "rhoEffLagrangian",
- runTime.timeName(),
- mesh,
- IOobject::NO_READ,
- IOobject::AUTO_WRITE
- ),
- mesh,
- dimensionedScalar(dimDensity, 0)
-);
-
-// dynamic pressure field - used externally (optional)
-volScalarField pDyn
-(
- IOobject
- (
- "pDyn",
- runTime.timeName(),
- mesh,
- IOobject::NO_READ,
- IOobject::AUTO_WRITE
- ),
- mesh,
- dimensionedScalar(dimPressure, 0)
-);
-
-
-Info<< "\nReading field U\n" << endl;
-volVectorField U
-(
- IOobject
- (
- "U",
- runTime.timeName(),
- mesh,
- IOobject::MUST_READ,
- IOobject::AUTO_WRITE
- ),
- mesh
-);
-
-#include "compressibleCreatePhi.H"
-
-mesh.setFluxRequired(p.name());
-
-Info<< "Creating turbulence model\n" << endl;
-autoPtr turbulence
-(
- compressible::momentumTransportModel::New
- (
- rho,
- U,
- phi,
- thermo
- )
-);
-
-Info<< "Creating thermophysical transport model\n" << endl;
-autoPtr thermophysicalTransport
-(
- psiReactionThermophysicalTransportModel::New(turbulence(), thermo)
-);
-
-Info<< "Creating combustion model\n" << endl;
-autoPtr> combustion
-(
- CombustionModel::New(thermo, turbulence())
-);
-
-Info<< "Creating field dpdt\n" << endl;
-volScalarField dpdt
-(
- IOobject
- (
- "dpdt",
- runTime.timeName(),
- mesh
- ),
- mesh,
- dimensionedScalar(p.dimensions()/dimTime, 0)
-);
-
-Info<< "Creating field kinetic energy K\n" << endl;
-volScalarField K("K", 0.5*magSqr(U));
-
-#include "createMRF.H"
-#include "createClouds.H"
-#include "createRadiationModel.H"
-#include "createFvOptions.H"
diff --git a/applications/solvers/lagrangian/coalChemistryFoam/pEqn.H b/applications/solvers/lagrangian/coalChemistryFoam/pEqn.H
deleted file mode 100644
index bedd635180..0000000000
--- a/applications/solvers/lagrangian/coalChemistryFoam/pEqn.H
+++ /dev/null
@@ -1,93 +0,0 @@
-rho = thermo.rho();
-
-volScalarField rAU(1.0/UEqn.A());
-surfaceScalarField rhorAUf("rhorAUf", fvc::interpolate(rho*rAU));
-volVectorField HbyA(constrainHbyA(rAU*UEqn.H(), U, p));
-
-if (pimple.transonic())
-{
- surfaceScalarField phid
- (
- "phid",
- fvc::interpolate(psi)
- *(
- fvc::flux(HbyA)
- + MRF.zeroFilter
- (
- rhorAUf*fvc::ddtCorr(rho, U, phi)/fvc::interpolate(rho)
- )
- )
- );
-
- MRF.makeRelative(fvc::interpolate(psi), phid);
-
- while (pimple.correctNonOrthogonal())
- {
- fvScalarMatrix pEqn
- (
- fvm::ddt(psi, p)
- + fvm::div(phid, p)
- - fvm::laplacian(rhorAUf, p)
- ==
- coalParcels.Srho()
- + fvOptions(psi, p, rho.name())
- );
-
- pEqn.solve();
-
- if (pimple.finalNonOrthogonalIter())
- {
- phi == pEqn.flux();
- }
- }
-}
-else
-{
- surfaceScalarField phiHbyA
- (
- "phiHbyA",
- (
- fvc::flux(rho*HbyA)
- + MRF.zeroFilter(rhorAUf*fvc::ddtCorr(rho, U, phi))
- )
- );
-
- MRF.makeRelative(fvc::interpolate(rho), phiHbyA);
-
- // Update the pressure BCs to ensure flux consistency
- constrainPressure(p, rho, U, phiHbyA, rhorAUf, MRF);
-
- while (pimple.correctNonOrthogonal())
- {
- fvScalarMatrix pEqn
- (
- fvm::ddt(psi, p)
- + fvc::div(phiHbyA)
- - fvm::laplacian(rhorAUf, p)
- ==
- coalParcels.Srho()
- + fvOptions(psi, p, rho.name())
- );
-
- pEqn.solve();
-
- if (pimple.finalNonOrthogonalIter())
- {
- phi = phiHbyA + pEqn.flux();
- }
- }
-}
-
-#include "rhoEqn.H"
-#include "compressibleContinuityErrs.H"
-
-U = HbyA - rAU*fvc::grad(p);
-U.correctBoundaryConditions();
-fvOptions.correct(U);
-
-K = 0.5*magSqr(U);
-
-if (thermo.dpdt())
-{
- dpdt = fvc::ddt(p);
-}
diff --git a/applications/solvers/lagrangian/coalChemistryFoam/rhoEqn.H b/applications/solvers/lagrangian/coalChemistryFoam/rhoEqn.H
deleted file mode 100644
index cb1cead6c2..0000000000
--- a/applications/solvers/lagrangian/coalChemistryFoam/rhoEqn.H
+++ /dev/null
@@ -1,47 +0,0 @@
-/*---------------------------------------------------------------------------*\
- ========= |
- \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
- \\ / O peration | Website: https://openfoam.org
- \\ / A nd | Copyright (C) 2011-2018 OpenFOAM Foundation
- \\/ M anipulation |
--------------------------------------------------------------------------------
-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 .
-
-Global
- rhoEqn
-
-Description
- Solve the continuity for density.
-
-\*---------------------------------------------------------------------------*/
-
-{
- fvScalarMatrix rhoEqn
- (
- fvm::ddt(rho)
- + fvc::div(phi)
- ==
- coalParcels.Srho(rho)
- + fvOptions(rho)
- );
-
- rhoEqn.solve();
-
- fvOptions.correct(rho);
-}
-
-// ************************************************************************* //
diff --git a/applications/solvers/lagrangian/coalChemistryFoam/setRDeltaT.H b/applications/solvers/lagrangian/coalChemistryFoam/setRDeltaT.H
deleted file mode 100644
index cb7b7b9a3b..0000000000
--- a/applications/solvers/lagrangian/coalChemistryFoam/setRDeltaT.H
+++ /dev/null
@@ -1,135 +0,0 @@
-/*---------------------------------------------------------------------------*\
- ========= |
- \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
- \\ / O peration | Website: https://openfoam.org
- \\ / A nd | Copyright (C) 2011-2020 OpenFOAM Foundation
- \\/ M anipulation |
--------------------------------------------------------------------------------
-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 .
-
-\*---------------------------------------------------------------------------*/
-
-{
- volScalarField& rDeltaT = trDeltaT.ref();
-
- const dictionary& pimpleDict = pimple.dict();
-
- // Maximum flow Courant number
- scalar maxCo(pimpleDict.lookup("maxCo"));
-
- // Maximum time scale
- scalar maxDeltaT(pimpleDict.lookupOrDefault("maxDeltaT", great));
-
- // Smoothing parameter (0-1) when smoothing iterations > 0
- scalar rDeltaTSmoothingCoeff
- (
- pimpleDict.lookupOrDefault("rDeltaTSmoothingCoeff", 0.1)
- );
-
- // Damping coefficient (1-0)
- scalar rDeltaTDampingCoeff
- (
- pimpleDict.lookupOrDefault("rDeltaTDampingCoeff", 0.2)
- );
-
- // Maximum change in cell temperature per iteration
- // (relative to previous value)
- scalar alphaTemp(pimpleDict.lookupOrDefault("alphaTemp", 0.05));
-
-
- Info<< "Time scales min/max:" << endl;
-
- // Cache old reciprocal time scale field
- volScalarField rDeltaT0("rDeltaT0", rDeltaT);
-
- // Flow time scale
- {
- rDeltaT.ref() =
- (
- fvc::surfaceSum(mag(phi))()()
- /((2*maxCo)*mesh.V()*rho())
- );
-
- // Limit the largest time scale
- rDeltaT.max(1/maxDeltaT);
-
- Info<< " Flow = "
- << gMin(1/rDeltaT.primitiveField()) << ", "
- << gMax(1/rDeltaT.primitiveField()) << endl;
- }
-
- // Reaction source time scale
- {
- volScalarField::Internal rDeltaTT
- (
- mag
- (
- (coalParcels.hsTrans() + limestoneParcels.hsTrans())
- /(mesh.V()*runTime.deltaT())
- + combustion->Qdot()()
- )
- /(
- alphaTemp
- *rho()
- *thermo.Cp()()()
- *T()
- )
- );
-
- Info<< " Temperature = "
- << gMin(1/(rDeltaTT.field() + vSmall)) << ", "
- << gMax(1/(rDeltaTT.field() + vSmall)) << endl;
-
- rDeltaT.ref() = max
- (
- rDeltaT(),
- rDeltaTT
- );
- }
-
- // Update the boundary values of the reciprocal time-step
- rDeltaT.correctBoundaryConditions();
-
- // Spatially smooth the time scale field
- if (rDeltaTSmoothingCoeff < 1.0)
- {
- fvc::smooth(rDeltaT, rDeltaTSmoothingCoeff);
- }
-
- // Limit rate of change of time scale
- // - reduce as much as required
- // - only increase at a fraction of old time scale
- if
- (
- rDeltaTDampingCoeff < 1.0
- && runTime.timeIndex() > runTime.startTimeIndex() + 1
- )
- {
- rDeltaT = max
- (
- rDeltaT,
- (scalar(1) - rDeltaTDampingCoeff)*rDeltaT0
- );
- }
-
- Info<< " Overall = "
- << gMin(1/rDeltaT.primitiveField())
- << ", " << gMax(1/rDeltaT.primitiveField()) << endl;
-}
-
-
-// ************************************************************************* //
diff --git a/applications/solvers/lagrangian/DPMFoam/Allwclean b/applications/solvers/lagrangian/denseParticleFoam/Allwclean
similarity index 76%
rename from applications/solvers/lagrangian/DPMFoam/Allwclean
rename to applications/solvers/lagrangian/denseParticleFoam/Allwclean
index 4575cd0537..a5c588e6f9 100755
--- a/applications/solvers/lagrangian/DPMFoam/Allwclean
+++ b/applications/solvers/lagrangian/denseParticleFoam/Allwclean
@@ -1,7 +1,7 @@
#!/bin/sh
cd ${0%/*} || exit 1 # Run from this directory
-wclean libso DPMMomentumTransportModels
+wclean libso denseParticleMomentumTransportModels
wclean
wclean MPPICFoam
diff --git a/applications/solvers/lagrangian/DPMFoam/Allwmake b/applications/solvers/lagrangian/denseParticleFoam/Allwmake
similarity index 78%
rename from applications/solvers/lagrangian/DPMFoam/Allwmake
rename to applications/solvers/lagrangian/denseParticleFoam/Allwmake
index 5ccc25ffe8..d01195794f 100755
--- a/applications/solvers/lagrangian/DPMFoam/Allwmake
+++ b/applications/solvers/lagrangian/denseParticleFoam/Allwmake
@@ -4,9 +4,8 @@ cd ${0%/*} || exit 1 # Run from this directory
# Parse arguments for library compilation
. $WM_PROJECT_DIR/wmake/scripts/AllwmakeParseArguments
-wmake $targetType DPMMomentumTransportModels
+wmake $targetType denseParticleMomentumTransportModels
wmake $targetType
-wmake $targetType MPPICFoam
#------------------------------------------------------------------------------
diff --git a/applications/solvers/lagrangian/DPMFoam/CourantNo.H b/applications/solvers/lagrangian/denseParticleFoam/CourantNo.H
similarity index 96%
rename from applications/solvers/lagrangian/DPMFoam/CourantNo.H
rename to applications/solvers/lagrangian/denseParticleFoam/CourantNo.H
index 504ac90b73..f0ef70106c 100644
--- a/applications/solvers/lagrangian/DPMFoam/CourantNo.H
+++ b/applications/solvers/lagrangian/denseParticleFoam/CourantNo.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration | Website: https://openfoam.org
- \\ / A nd | Copyright (C) 2013-2018 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2013-2020 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
diff --git a/applications/solvers/lagrangian/denseParticleFoam/Make/files b/applications/solvers/lagrangian/denseParticleFoam/Make/files
new file mode 100644
index 0000000000..2bd83594aa
--- /dev/null
+++ b/applications/solvers/lagrangian/denseParticleFoam/Make/files
@@ -0,0 +1,3 @@
+denseParticleFoam.C
+
+EXE = $(FOAM_APPBIN)/denseParticleFoam
diff --git a/applications/solvers/lagrangian/DPMFoam/MPPICFoam/Make/options b/applications/solvers/lagrangian/denseParticleFoam/Make/options
similarity index 83%
rename from applications/solvers/lagrangian/DPMFoam/MPPICFoam/Make/options
rename to applications/solvers/lagrangian/denseParticleFoam/Make/options
index 74755c40b2..a258cd1f13 100644
--- a/applications/solvers/lagrangian/DPMFoam/MPPICFoam/Make/options
+++ b/applications/solvers/lagrangian/denseParticleFoam/Make/options
@@ -1,8 +1,7 @@
EXE_INC = \
- -I.. \
- -I../DPMMomentumTransportModels/lnInclude \
+ -I./denseParticleMomentumTransportModels/lnInclude \
-I$(LIB_SRC)/lagrangian/basic/lnInclude \
- -I$(LIB_SRC)/lagrangian/intermediate/lnInclude \
+ -I$(LIB_SRC)/lagrangian/parcel/lnInclude \
-I$(LIB_SRC)/thermophysicalModels/specie/lnInclude \
-I$(LIB_SRC)/thermophysicalModels/basic/lnInclude \
-I$(LIB_SRC)/thermophysicalModels/reactionThermo/lnInclude \
@@ -19,12 +18,12 @@ EXE_INC = \
EXE_LIBS = \
-llagrangian \
- -llagrangianIntermediate \
- -llagrangianTurbulence \
+ -llagrangianParcel \
+ -llagrangianParcelTurbulence \
-lincompressibleTransportModels \
-lmomentumTransportModels \
-lincompressibleMomentumTransportModels \
- -lDPMMomentumTransportModels \
+ -ldenseParticleMomentumTransportModels \
-lfiniteVolume \
-ldynamicFvMesh \
-ltopoChangerFvMesh \
diff --git a/applications/solvers/lagrangian/DPMFoam/UcEqn.H b/applications/solvers/lagrangian/denseParticleFoam/UcEqn.H
similarity index 51%
rename from applications/solvers/lagrangian/DPMFoam/UcEqn.H
rename to applications/solvers/lagrangian/denseParticleFoam/UcEqn.H
index 12c6f8fbab..829fdca9b9 100644
--- a/applications/solvers/lagrangian/DPMFoam/UcEqn.H
+++ b/applications/solvers/lagrangian/denseParticleFoam/UcEqn.H
@@ -12,11 +12,17 @@ UcEqn.relax();
fvOptions.constrain(UcEqn);
volScalarField rAUc(1.0/UcEqn.A());
-surfaceScalarField rAUcf("Dp", fvc::interpolate(rAUc));
+volScalarField rASpUc(1.0/(UcEqn.A() - cloudSUp/rhoc));
+surfaceScalarField rASpUcf("Dp", fvc::interpolate(rASpUc));
-surfaceScalarField phicForces
+surfaceScalarField phicSUSu
(
- fvc::flux(rAUc*cloudVolSUSu/rhoc) + rAUcf*(g & mesh.Sf())
+ fvc::flux(rASpUc*cloudSUu/rhoc)
+ + rASpUcf*(g & mesh.Sf())
+);
+surfaceScalarField phicSUSp
+(
+ fvc::interpolate(rASpUc*cloudSUp/rhoc)
);
if (pimple.momentumPredictor())
@@ -27,8 +33,10 @@ if (pimple.momentumPredictor())
==
fvc::reconstruct
(
- phicForces/rAUcf - fvc::snGrad(p)*mesh.magSf()
+ (phicSUSu + phicSUSp*phic)/rASpUcf
+ - fvc::snGrad(p)*mesh.magSf()
)
+ + (1.0/rhoc)*(fvm::Sp(cloudSUp, Uc) - cloudSUp*Uc)
);
fvOptions.correct(Uc);
diff --git a/applications/solvers/lagrangian/DPMFoam/continuityErrs.H b/applications/solvers/lagrangian/denseParticleFoam/continuityErrs.H
similarity index 96%
rename from applications/solvers/lagrangian/DPMFoam/continuityErrs.H
rename to applications/solvers/lagrangian/denseParticleFoam/continuityErrs.H
index 980f9919f6..792b8a6aad 100644
--- a/applications/solvers/lagrangian/DPMFoam/continuityErrs.H
+++ b/applications/solvers/lagrangian/denseParticleFoam/continuityErrs.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration | Website: https://openfoam.org
- \\ / A nd | Copyright (C) 2013-2018 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2013-2020 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
diff --git a/applications/solvers/lagrangian/DPMFoam/correctPhic.H b/applications/solvers/lagrangian/denseParticleFoam/correctPhic.H
similarity index 100%
rename from applications/solvers/lagrangian/DPMFoam/correctPhic.H
rename to applications/solvers/lagrangian/denseParticleFoam/correctPhic.H
diff --git a/applications/solvers/lagrangian/DPMFoam/createFields.H b/applications/solvers/lagrangian/denseParticleFoam/createFields.H
similarity index 87%
rename from applications/solvers/lagrangian/DPMFoam/createFields.H
rename to applications/solvers/lagrangian/denseParticleFoam/createFields.H
index eefdfd0576..55aac63f32 100644
--- a/applications/solvers/lagrangian/DPMFoam/createFields.H
+++ b/applications/solvers/lagrangian/denseParticleFoam/createFields.H
@@ -122,29 +122,17 @@ volScalarField alphac
dimensionedScalar(dimless, 0)
);
-word kinematicCloudName("kinematicCloud");
-args.optionReadIfPresent("cloudName", kinematicCloudName);
-
-Info<< "Constructing kinematicCloud " << kinematicCloudName << endl;
-basicKinematicTypeCloud kinematicCloud
-(
- kinematicCloudName,
- rhoc,
- Uc,
- muc,
- g
-);
+Info<< "Constructing clouds" << endl;
+parcelCloudList clouds(rhoc, Uc, muc, g);
// Particle fraction upper limit
scalar alphacMin
(
- 1.0
- - kinematicCloud.particleProperties().subDict("constantProperties")
- .lookup("alphaMax")
+ 1 - mesh.solverDict(alphac.name()).lookup("max")
);
// Update alphac from the particle locations
-alphac = max(1.0 - kinematicCloud.theta(), alphacMin);
+alphac = max(1.0 - clouds.theta(), alphacMin);
alphac.correctBoundaryConditions();
surfaceScalarField alphacf("alphacf", fvc::interpolate(alphac));
diff --git a/applications/solvers/lagrangian/DPMFoam/createUcf.H b/applications/solvers/lagrangian/denseParticleFoam/createUcf.H
similarity index 96%
rename from applications/solvers/lagrangian/DPMFoam/createUcf.H
rename to applications/solvers/lagrangian/denseParticleFoam/createUcf.H
index 730250cf52..10d84b25a9 100644
--- a/applications/solvers/lagrangian/DPMFoam/createUcf.H
+++ b/applications/solvers/lagrangian/denseParticleFoam/createUcf.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration | Website: https://openfoam.org
- \\ / A nd | Copyright (C) 2017-2018 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2017-2020 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
diff --git a/applications/solvers/lagrangian/DPMFoam/createUcfIfPresent.H b/applications/solvers/lagrangian/denseParticleFoam/createUcfIfPresent.H
similarity index 96%
rename from applications/solvers/lagrangian/DPMFoam/createUcfIfPresent.H
rename to applications/solvers/lagrangian/denseParticleFoam/createUcfIfPresent.H
index 61231b1030..5c822ec16f 100644
--- a/applications/solvers/lagrangian/DPMFoam/createUcfIfPresent.H
+++ b/applications/solvers/lagrangian/denseParticleFoam/createUcfIfPresent.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration | Website: https://openfoam.org
- \\ / A nd | Copyright (C) 2017-2018 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2017-2020 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
diff --git a/applications/solvers/lagrangian/denseParticleFoam/denseParticleFoam.C b/applications/solvers/lagrangian/denseParticleFoam/denseParticleFoam.C
new file mode 100644
index 0000000000..6cdd89e17f
--- /dev/null
+++ b/applications/solvers/lagrangian/denseParticleFoam/denseParticleFoam.C
@@ -0,0 +1,241 @@
+/*---------------------------------------------------------------------------*\
+ ========= |
+ \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
+ \\ / O peration | Website: https://openfoam.org
+ \\ / A nd | Copyright (C) 2013-2020 OpenFOAM Foundation
+ \\/ M anipulation |
+-------------------------------------------------------------------------------
+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 .
+
+Application
+ denseParticleFoam
+
+Description
+ Transient solver for the coupled transport of particle clouds including the
+ effect of the volume fraction of particles on the continuous phase, with
+ optional mesh motion and mesh topology changes.
+
+\*---------------------------------------------------------------------------*/
+
+#include "NamedEnum.H"
+
+namespace Foam
+{
+ enum class cloudForceSplit
+ {
+ faceExplicitCellImplicit, // Implicit part of the cloud force added to
+ // the cell momentum equation. Explicit part
+ // to the face momentum equation. This is the
+ // least likely to create staggering patterns
+ // in the velocity field, but it can create
+ // unphysical perturbations in cell
+ // velocities even when particles and flow
+ // have the similar velocities.
+
+ faceExplicitCellLagged, // Entire cloud force evaluated explicitly
+ // and added to the face momentum equation.
+ // Lagged correction (i.e.,
+ // fvm::Sp(cloudSU.diag(), Uc) -
+ // cloudSU.diag()*Uc) added to the cell
+ // momentum equation. This creates physical
+ // cell velocities when particles and flow
+ // have the same velocity, but can also
+ // result in staggering patterns in packed
+ // beds. Unsuitable for MPPIC.
+
+ faceImplicit // Implicit and explicit parts of the force
+ // both added to the face momentum equation.
+ // Behaves somewhere between the other two.
+ };
+
+ template<>
+ const char* NamedEnum::names[] =
+ {
+ "faceExplicitCellImplicit",
+ "faceExplicitCellLagged",
+ "faceImplicit"
+ };
+
+ const NamedEnum cloudForceSplitNames;
+}
+
+// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
+
+#include "fvCFD.H"
+#include "dynamicFvMesh.H"
+#include "singlePhaseTransportModel.H"
+#include "PhaseIncompressibleMomentumTransportModel.H"
+#include "pimpleControl.H"
+#include "CorrectPhi.H"
+#include "fvOptions.H"
+#include "parcelCloudList.H"
+
+// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
+
+int main(int argc, char *argv[])
+{
+ #include "postProcess.H"
+
+ #include "setRootCaseLists.H"
+ #include "createTime.H"
+ #include "createDynamicFvMesh.H"
+ #include "createDyMControls.H"
+ #include "createFields.H"
+ #include "createUcfIfPresent.H"
+ #include "initContinuityErrs.H"
+
+ Info<< "\nStarting time loop\n" << endl;
+
+ while (pimple.run(runTime))
+ {
+ #include "readDyMControls.H"
+ #include "CourantNo.H"
+ #include "setDeltaT.H"
+
+ runTime++;
+
+ Info<< "Time = " << runTime.timeName() << nl << endl;
+
+ // Store the particle positions
+ clouds.storeGlobalPositions();
+
+ mesh.update();
+
+ if (mesh.changing())
+ {
+ if (correctPhi)
+ {
+ // Calculate absolute flux from the mapped surface velocity
+ phic = mesh.Sf() & Ucf();
+
+ #include "correctPhic.H"
+
+ // Make the flux relative to the mesh motion
+ fvc::makeRelative(phic, Uc);
+ }
+
+ if (checkMeshCourantNo)
+ {
+ #include "meshCourantNo.H"
+ }
+ }
+
+ continuousPhaseTransport.correct();
+ muc = rhoc*continuousPhaseTransport.nu();
+
+ clouds.evolve();
+
+ // Update continuous phase volume fraction field
+ alphac = max(1.0 - clouds.theta(), alphacMin);
+ alphac.correctBoundaryConditions();
+ alphacf = fvc::interpolate(alphac);
+ alphaPhic = alphacf*phic;
+
+ // Cloud forces
+ fvVectorMatrix cloudSU(clouds.SU(Uc));
+ volVectorField cloudSUu
+ (
+ IOobject
+ (
+ "cloudSUu",
+ runTime.timeName(),
+ mesh
+ ),
+ mesh,
+ dimensionedVector(dimForce/dimVolume, Zero),
+ zeroGradientFvPatchVectorField::typeName
+ );
+ volScalarField cloudSUp
+ (
+ IOobject
+ (
+ "cloudSUp",
+ runTime.timeName(),
+ mesh
+ ),
+ mesh,
+ dimensionedScalar(dimForce/dimVelocity/dimVolume, Zero),
+ zeroGradientFvPatchVectorField::typeName
+ );
+
+ const cloudForceSplit cloudSUSplit =
+ pimple.dict().found("cloudForceSplit")
+ ? cloudForceSplitNames.read(pimple.dict().lookup("cloudForceSplit"))
+ : cloudForceSplit::faceExplicitCellImplicit;
+
+ switch (cloudSUSplit)
+ {
+ case cloudForceSplit::faceExplicitCellImplicit:
+ cloudSUu.primitiveFieldRef() = -cloudSU.source()/mesh.V();
+ cloudSUu.correctBoundaryConditions();
+ cloudSUp.primitiveFieldRef() = Zero;
+ cloudSUp.correctBoundaryConditions();
+ //cloudSU.diag() = cloudSU.diag();
+ cloudSU.source() = Zero;
+ break;
+
+ case cloudForceSplit::faceExplicitCellLagged:
+ cloudSUu.primitiveFieldRef() =
+ (cloudSU.diag()*Uc() - cloudSU.source())/mesh.V();
+ cloudSUu.correctBoundaryConditions();
+ cloudSUp.primitiveFieldRef() = Zero;
+ cloudSUp.correctBoundaryConditions();
+ //cloudSU.diag() = cloudSU.diag();
+ cloudSU.source() = cloudSU.diag()*Uc();
+ break;
+
+ case cloudForceSplit::faceImplicit:
+ cloudSUu.primitiveFieldRef() = -cloudSU.source()/mesh.V();
+ cloudSUu.correctBoundaryConditions();
+ cloudSUp.primitiveFieldRef() = cloudSU.diag()/mesh.V();
+ cloudSUp.correctBoundaryConditions();
+ cloudSU.diag() = Zero;
+ cloudSU.source() = Zero;
+ break;
+ }
+
+ // --- Pressure-velocity PIMPLE corrector loop
+ while (pimple.loop())
+ {
+ #include "UcEqn.H"
+
+ // --- PISO loop
+ while (pimple.correct())
+ {
+ #include "pEqn.H"
+ }
+
+ if (pimple.turbCorr())
+ {
+ continuousPhaseTurbulence->correct();
+ }
+ }
+
+ runTime.write();
+
+ Info<< "ExecutionTime = " << runTime.elapsedCpuTime() << " s"
+ << " ClockTime = " << runTime.elapsedClockTime() << " s"
+ << nl << endl;
+ }
+
+ Info<< "End\n" << endl;
+
+ return 0;
+}
+
+
+// ************************************************************************* //
diff --git a/applications/solvers/lagrangian/denseParticleFoam/denseParticleMomentumTransportModels/Make/files b/applications/solvers/lagrangian/denseParticleFoam/denseParticleMomentumTransportModels/Make/files
new file mode 100644
index 0000000000..c2020ca982
--- /dev/null
+++ b/applications/solvers/lagrangian/denseParticleFoam/denseParticleMomentumTransportModels/Make/files
@@ -0,0 +1,3 @@
+denseParticleMomentumTransportModels.C
+
+LIB = $(FOAM_LIBBIN)/libdenseParticleMomentumTransportModels
diff --git a/applications/solvers/lagrangian/DPMFoam/DPMMomentumTransportModels/Make/options b/applications/solvers/lagrangian/denseParticleFoam/denseParticleMomentumTransportModels/Make/options
similarity index 100%
rename from applications/solvers/lagrangian/DPMFoam/DPMMomentumTransportModels/Make/options
rename to applications/solvers/lagrangian/denseParticleFoam/denseParticleMomentumTransportModels/Make/options
diff --git a/applications/solvers/lagrangian/DPMFoam/DPMMomentumTransportModels/DPMMomentumTransportModels.C b/applications/solvers/lagrangian/denseParticleFoam/denseParticleMomentumTransportModels/denseParticleMomentumTransportModels.C
similarity index 100%
rename from applications/solvers/lagrangian/DPMFoam/DPMMomentumTransportModels/DPMMomentumTransportModels.C
rename to applications/solvers/lagrangian/denseParticleFoam/denseParticleMomentumTransportModels/denseParticleMomentumTransportModels.C
diff --git a/applications/solvers/lagrangian/DPMFoam/pEqn.H b/applications/solvers/lagrangian/denseParticleFoam/pEqn.H
similarity index 50%
rename from applications/solvers/lagrangian/DPMFoam/pEqn.H
rename to applications/solvers/lagrangian/denseParticleFoam/pEqn.H
index 7c3206ee99..9f60a24628 100644
--- a/applications/solvers/lagrangian/DPMFoam/pEqn.H
+++ b/applications/solvers/lagrangian/denseParticleFoam/pEqn.H
@@ -1,35 +1,37 @@
{
volVectorField HbyA(constrainHbyA(rAUc*UcEqn.H(), Uc, p));
+ volVectorField HbyASp(rASpUc/rAUc*HbyA);
- surfaceScalarField phiHbyA
+ surfaceScalarField phiHbyASp
(
- "phiHbyA",
+ "phiHbyASp",
(
- fvc::flux(HbyA)
- + alphacf*rAUcf*fvc::ddtCorr(Uc, phic, Ucf)
+ fvc::flux(HbyASp)
+ + alphacf*rASpUcf*fvc::ddtCorr(Uc, phic, Ucf)
)
);
if (p.needReference())
{
- fvc::makeRelative(phiHbyA, Uc);
- adjustPhi(phiHbyA, Uc, p);
- fvc::makeAbsolute(phiHbyA, Uc);
+ fvc::makeRelative(phiHbyASp, Uc);
+ adjustPhi(phiHbyASp, Uc, p);
+ fvc::makeAbsolute(phiHbyASp, Uc);
}
- phiHbyA += phicForces;
+ phiHbyASp += phicSUSu;
// Update the pressure BCs to ensure flux consistency
- constrainPressure(p, Uc, phiHbyA, rAUcf);
+ constrainPressure(p, Uc, phiHbyASp, rASpUcf);
// Non-orthogonal pressure corrector loop
while (pimple.correctNonOrthogonal())
{
fvScalarMatrix pEqn
(
- fvm::laplacian(alphacf*rAUcf, p)
+ fvm::laplacian(alphacf*rASpUcf, p)
==
- fvc::ddt(alphac) + fvc::div(alphacf*phiHbyA)
+ fvc::ddt(alphac)
+ + fvc::div(alphacf*phiHbyASp)
);
pEqn.setReference(pRefCell, pRefValue);
@@ -38,13 +40,18 @@
if (pimple.finalNonOrthogonalIter())
{
- phic = phiHbyA - pEqn.flux()/alphacf;
+ phic = phiHbyASp - pEqn.flux()/alphacf;
+ // Explicitly relax pressure for momentum corrector
p.relax();
- Uc = HbyA
- + rAUc
- *fvc::reconstruct((phicForces - pEqn.flux()/alphacf)/rAUcf);
+ Uc =
+ HbyA
+ + rAUc
+ *fvc::reconstruct
+ (
+ (phicSUSu + phicSUSp*phic - pEqn.flux()/alphacf)/rASpUcf
+ );
Uc.correctBoundaryConditions();
fvOptions.correct(Uc);
diff --git a/applications/solvers/lagrangian/particleFoam/Make/options b/applications/solvers/lagrangian/particleFoam/Make/options
index 78af970334..992e22cfb5 100644
--- a/applications/solvers/lagrangian/particleFoam/Make/options
+++ b/applications/solvers/lagrangian/particleFoam/Make/options
@@ -1,6 +1,6 @@
EXE_INC = \
-I$(LIB_SRC)/lagrangian/basic/lnInclude \
- -I$(LIB_SRC)/lagrangian/intermediate/lnInclude \
+ -I$(LIB_SRC)/lagrangian/parcel/lnInclude \
-I$(LIB_SRC)/MomentumTransportModels/momentumTransportModels/lnInclude \
-I$(LIB_SRC)/MomentumTransportModels/incompressible/lnInclude \
-I$(LIB_SRC)/transportModels/lnInclude \
@@ -12,8 +12,8 @@ EXE_INC = \
EXE_LIBS = \
-llagrangian \
- -llagrangianIntermediate \
- -llagrangianTurbulence \
+ -llagrangianParcel \
+ -llagrangianParcelTurbulence \
-lmomentumTransportModels \
-lincompressibleMomentumTransportModels \
-lincompressibleTransportModels \
diff --git a/applications/solvers/lagrangian/particleFoam/createFields.H b/applications/solvers/lagrangian/particleFoam/createFields.H
index 116163ab20..f64dcca81a 100644
--- a/applications/solvers/lagrangian/particleFoam/createFields.H
+++ b/applications/solvers/lagrangian/particleFoam/createFields.H
@@ -57,18 +57,8 @@ volScalarField mu
laminarTransport.nu()*rhoInfValue
);
-word kinematicCloudName("kinematicCloud");
-args.optionReadIfPresent("cloudName", kinematicCloudName);
-
-Info<< "Constructing kinematicCloud " << kinematicCloudName << endl;
-basicKinematicCollidingCloud kinematicCloud
-(
- kinematicCloudName,
- rhoInf,
- U,
- mu,
- g
-);
+Info<< "Constructing clouds" << endl;
+parcelCloudList clouds(rhoInf, U, mu, g);
IOobject Hheader
(
diff --git a/applications/solvers/lagrangian/particleFoam/particleFoam.C b/applications/solvers/lagrangian/particleFoam/particleFoam.C
index 8d455d2793..e8b6c6c96f 100644
--- a/applications/solvers/lagrangian/particleFoam/particleFoam.C
+++ b/applications/solvers/lagrangian/particleFoam/particleFoam.C
@@ -36,19 +36,12 @@ Description
#include "dynamicFvMesh.H"
#include "singlePhaseTransportModel.H"
#include "kinematicMomentumTransportModel.H"
-#include "basicKinematicCollidingCloud.H"
+#include "parcelCloudList.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
int main(int argc, char *argv[])
{
- argList::addOption
- (
- "cloudName",
- "name",
- "specify alternative cloud name. default is 'kinematicCloud'"
- );
-
#define NO_CONTROL
#include "postProcess.H"
@@ -66,7 +59,7 @@ int main(int argc, char *argv[])
{
Info<< "Time = " << runTime.timeName() << nl << endl;
- kinematicCloud.storeGlobalPositions();
+ clouds.storeGlobalPositions();
mesh.update();
@@ -76,11 +69,9 @@ int main(int argc, char *argv[])
}
laminarTransport.correct();
-
- Info<< "Evolving " << kinematicCloud.name() << endl;
mu = laminarTransport.nu()*rhoInfValue;
- kinematicCloud.evolve();
+ clouds.evolve();
runTime.write();
diff --git a/applications/solvers/lagrangian/reactingParcelFoam/Make/files b/applications/solvers/lagrangian/reactingParcelFoam/Make/files
deleted file mode 100644
index 3710ca4e2d..0000000000
--- a/applications/solvers/lagrangian/reactingParcelFoam/Make/files
+++ /dev/null
@@ -1,3 +0,0 @@
-reactingParcelFoam.C
-
-EXE = $(FOAM_APPBIN)/reactingParcelFoam
diff --git a/applications/solvers/lagrangian/reactingParcelFoam/createClouds.H b/applications/solvers/lagrangian/reactingParcelFoam/createClouds.H
deleted file mode 100644
index 954b74e069..0000000000
--- a/applications/solvers/lagrangian/reactingParcelFoam/createClouds.H
+++ /dev/null
@@ -1,9 +0,0 @@
-Info<< "\nConstructing reacting cloud" << endl;
-basicReactingMultiphaseCloud parcels
-(
- "reactingCloud1",
- rho,
- U,
- g,
- slgThermo
-);
diff --git a/applications/solvers/lagrangian/reactingParcelFoam/reactingParcelFoam.C b/applications/solvers/lagrangian/reactingParcelFoam/reactingParcelFoam.C
deleted file mode 100644
index 69307f5314..0000000000
--- a/applications/solvers/lagrangian/reactingParcelFoam/reactingParcelFoam.C
+++ /dev/null
@@ -1,139 +0,0 @@
-/*---------------------------------------------------------------------------*\
- ========= |
- \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
- \\ / O peration | Website: https://openfoam.org
- \\ / A nd | Copyright (C) 2011-2020 OpenFOAM Foundation
- \\/ M anipulation |
--------------------------------------------------------------------------------
-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 .
-
-Application
- reactingParcelFoam
-
-Description
- Transient solver for compressible, turbulent flow with a reacting,
- multiphase particle cloud, and surface film modelling.
-
-\*---------------------------------------------------------------------------*/
-
-#include "fvCFD.H"
-#include "fluidThermoMomentumTransportModel.H"
-#include "rhoReactionThermophysicalTransportModel.H"
-#include "basicReactingMultiphaseCloud.H"
-#include "surfaceFilmModel.H"
-#include "rhoReactionThermo.H"
-#include "CombustionModel.H"
-#include "radiationModel.H"
-#include "SLGThermo.H"
-#include "fvOptions.H"
-#include "pimpleControl.H"
-#include "pressureControl.H"
-#include "localEulerDdtScheme.H"
-#include "fvcSmooth.H"
-
-// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
-
-int main(int argc, char *argv[])
-{
- #include "postProcess.H"
-
- #include "setRootCaseLists.H"
- #include "createTime.H"
- #include "createMesh.H"
- #include "createControl.H"
- #include "createTimeControls.H"
- #include "createFields.H"
- #include "createFieldRefs.H"
- #include "initContinuityErrs.H"
-
- turbulence->validate();
-
- if (!LTS)
- {
- #include "compressibleCourantNo.H"
- #include "setInitialDeltaT.H"
- }
-
- // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
-
- Info<< "\nStarting time loop\n" << endl;
-
- while (pimple.run(runTime))
- {
- #include "readTimeControls.H"
-
- if (LTS)
- {
- #include "setRDeltaT.H"
- }
- else
- {
- #include "compressibleCourantNo.H"
- #include "setMultiRegionDeltaT.H"
- }
-
- runTime++;
-
- Info<< "Time = " << runTime.timeName() << nl << endl;
-
- parcels.evolve();
- surfaceFilm.evolve();
-
- if (solvePrimaryRegion)
- {
- if (pimple.firstPimpleIter() && !pimple.simpleRho())
- {
- #include "rhoEqn.H"
- }
-
- // --- PIMPLE loop
- while (pimple.loop())
- {
- #include "UEqn.H"
- #include "YEqn.H"
- #include "EEqn.H"
-
- // --- Pressure corrector loop
- while (pimple.correct())
- {
- #include "pEqn.H"
- }
-
- if (pimple.turbCorr())
- {
- turbulence->correct();
- thermophysicalTransport->correct();
- }
- }
- }
-
- rho = thermo.rho();
-
- runTime.write();
-
- Info<< "ExecutionTime = " << runTime.elapsedCpuTime() << " s"
- << " ClockTime = " << runTime.elapsedClockTime() << " s"
- << nl << endl;
- }
-
- Info<< "End" << endl;
-
- return 0;
-}
-
-
-// ************************************************************************* //
diff --git a/applications/solvers/lagrangian/reactingParcelFoam/simpleReactingParcelFoam/Make/files b/applications/solvers/lagrangian/reactingParcelFoam/simpleReactingParcelFoam/Make/files
deleted file mode 100644
index 4a202fcd4d..0000000000
--- a/applications/solvers/lagrangian/reactingParcelFoam/simpleReactingParcelFoam/Make/files
+++ /dev/null
@@ -1,3 +0,0 @@
-simpleReactingParcelFoam.C
-
-EXE = $(FOAM_APPBIN)/simpleReactingParcelFoam
diff --git a/applications/solvers/lagrangian/reactingParcelFoam/simpleReactingParcelFoam/createClouds.H b/applications/solvers/lagrangian/reactingParcelFoam/simpleReactingParcelFoam/createClouds.H
deleted file mode 100644
index 954b74e069..0000000000
--- a/applications/solvers/lagrangian/reactingParcelFoam/simpleReactingParcelFoam/createClouds.H
+++ /dev/null
@@ -1,9 +0,0 @@
-Info<< "\nConstructing reacting cloud" << endl;
-basicReactingMultiphaseCloud parcels
-(
- "reactingCloud1",
- rho,
- U,
- g,
- slgThermo
-);
diff --git a/applications/solvers/lagrangian/reactingParcelFoam/EEqn.H b/applications/solvers/lagrangian/reactingParticleFoam/EEqn.H
similarity index 97%
rename from applications/solvers/lagrangian/reactingParcelFoam/EEqn.H
rename to applications/solvers/lagrangian/reactingParticleFoam/EEqn.H
index 5de37eb37a..d69d145b57 100644
--- a/applications/solvers/lagrangian/reactingParcelFoam/EEqn.H
+++ b/applications/solvers/lagrangian/reactingParticleFoam/EEqn.H
@@ -18,7 +18,7 @@
+ thermophysicalTransport->divq(he)
==
rho*(U&g)
- + parcels.Sh(he)
+ + clouds.Sh(he)
+ surfaceFilm.Sh()
+ radiation->Sh(thermo, he)
+ combustion->Qdot()
diff --git a/applications/solvers/lagrangian/reactingParticleFoam/Make/files b/applications/solvers/lagrangian/reactingParticleFoam/Make/files
new file mode 100644
index 0000000000..9d992cc1fc
--- /dev/null
+++ b/applications/solvers/lagrangian/reactingParticleFoam/Make/files
@@ -0,0 +1,3 @@
+reactingParticleFoam.C
+
+EXE = $(FOAM_APPBIN)/reactingParticleFoam
diff --git a/applications/solvers/lagrangian/reactingParcelFoam/Make/options b/applications/solvers/lagrangian/reactingParticleFoam/Make/options
similarity index 87%
rename from applications/solvers/lagrangian/reactingParcelFoam/Make/options
rename to applications/solvers/lagrangian/reactingParticleFoam/Make/options
index 04b9bb80f7..417e6b8353 100644
--- a/applications/solvers/lagrangian/reactingParcelFoam/Make/options
+++ b/applications/solvers/lagrangian/reactingParticleFoam/Make/options
@@ -1,9 +1,9 @@
EXE_INC = \
-I. \
- -I../reactingParcelFoam \
-I$(LIB_SRC)/finiteVolume/lnInclude \
-I$(LIB_SRC)/sampling/lnInclude \
-I$(LIB_SRC)/meshTools/lnInclude \
+ -I$(LIB_SRC)/dynamicFvMesh/lnInclude \
-I$(LIB_SRC)/MomentumTransportModels/momentumTransportModels/lnInclude \
-I$(LIB_SRC)/MomentumTransportModels/compressible/lnInclude \
-I$(LIB_SRC)/ThermophysicalTransportModels/lnInclude \
@@ -19,16 +19,16 @@ EXE_INC = \
-I$(LIB_SRC)/regionModels/regionModel/lnInclude \
-I$(LIB_SRC)/regionModels/surfaceFilmModels/lnInclude \
-I$(LIB_SRC)/lagrangian/basic/lnInclude \
- -I$(LIB_SRC)/lagrangian/intermediate/lnInclude \
+ -I$(LIB_SRC)/lagrangian/parcel/lnInclude \
-I$(LIB_SRC)/ODE/lnInclude \
- -I$(LIB_SRC)/combustionModels/lnInclude \
- -I$(FOAM_SOLVERS)/combustion/reactingFoam
+ -I$(LIB_SRC)/combustionModels/lnInclude
EXE_LIBS = \
-lfiniteVolume \
-lfvOptions \
-lsampling \
-lmeshTools \
+ -ldynamicFvMesh \
-lmomentumTransportModels \
-lfluidThermoMomentumTransportModels \
-lthermophysicalTransportModels \
@@ -43,7 +43,7 @@ EXE_LIBS = \
-lsurfaceFilmModels \
-lsurfaceFilmDerivedFvPatchFields \
-llagrangian \
- -llagrangianIntermediate \
- -llagrangianTurbulence \
+ -llagrangianParcel \
+ -llagrangianParcelTurbulence \
-lODE \
-lcombustionModels
diff --git a/applications/solvers/lagrangian/coalChemistryFoam/UEqn.H b/applications/solvers/lagrangian/reactingParticleFoam/UEqn.H
similarity index 88%
rename from applications/solvers/lagrangian/coalChemistryFoam/UEqn.H
rename to applications/solvers/lagrangian/reactingParticleFoam/UEqn.H
index 9230617cde..6d7901fbf5 100644
--- a/applications/solvers/lagrangian/coalChemistryFoam/UEqn.H
+++ b/applications/solvers/lagrangian/reactingParticleFoam/UEqn.H
@@ -7,8 +7,7 @@
+ turbulence->divDevTau(U)
==
rho()*g
- + coalParcels.SU(U)
- + limestoneParcels.SU(U)
+ + clouds.SU(U)
+ fvOptions(rho, U)
);
diff --git a/applications/solvers/lagrangian/reactingParcelFoam/YEqn.H b/applications/solvers/lagrangian/reactingParticleFoam/YEqn.H
similarity index 96%
rename from applications/solvers/lagrangian/reactingParcelFoam/YEqn.H
rename to applications/solvers/lagrangian/reactingParticleFoam/YEqn.H
index 1f97c7236d..86c2463d7a 100644
--- a/applications/solvers/lagrangian/reactingParcelFoam/YEqn.H
+++ b/applications/solvers/lagrangian/reactingParticleFoam/YEqn.H
@@ -9,7 +9,6 @@ tmp> mvConvection
)
);
-
{
combustion->correct();
volScalarField Yt(0.0*Y[0]);
@@ -26,7 +25,7 @@ tmp> mvConvection
+ mvConvection->fvmDiv(phi, Yi)
+ thermophysicalTransport->divj(Yi)
==
- parcels.SYi(i, Yi)
+ clouds.SYi(i, Yi)
+ fvOptions(rho, Yi)
+ combustion->R(Yi)
+ surfaceFilm.Srho(i)
diff --git a/applications/solvers/lagrangian/reactingParticleFoam/buoyantReactingParticleFoam/Make/files b/applications/solvers/lagrangian/reactingParticleFoam/buoyantReactingParticleFoam/Make/files
new file mode 100644
index 0000000000..317e887d97
--- /dev/null
+++ b/applications/solvers/lagrangian/reactingParticleFoam/buoyantReactingParticleFoam/Make/files
@@ -0,0 +1,3 @@
+buoyantReactingParticleFoam.C
+
+EXE = $(FOAM_APPBIN)/buoyantReactingParticleFoam
diff --git a/applications/solvers/lagrangian/sprayFoam/engineFoam/Make/options b/applications/solvers/lagrangian/reactingParticleFoam/buoyantReactingParticleFoam/Make/options
similarity index 78%
rename from applications/solvers/lagrangian/sprayFoam/engineFoam/Make/options
rename to applications/solvers/lagrangian/reactingParticleFoam/buoyantReactingParticleFoam/Make/options
index 7955e92863..b455411139 100644
--- a/applications/solvers/lagrangian/sprayFoam/engineFoam/Make/options
+++ b/applications/solvers/lagrangian/reactingParticleFoam/buoyantReactingParticleFoam/Make/options
@@ -1,17 +1,14 @@
EXE_INC = \
-I. \
-I.. \
- -I../../reactingParcelFoam \
-I$(LIB_SRC)/finiteVolume/lnInclude \
- -I$(LIB_SRC)/meshTools/lnInclude \
-I$(LIB_SRC)/sampling/lnInclude \
+ -I$(LIB_SRC)/meshTools/lnInclude \
+ -I$(LIB_SRC)/dynamicFvMesh/lnInclude \
-I$(LIB_SRC)/MomentumTransportModels/momentumTransportModels/lnInclude \
-I$(LIB_SRC)/MomentumTransportModels/compressible/lnInclude \
-I$(LIB_SRC)/ThermophysicalTransportModels/lnInclude \
- -I$(LIB_SRC)/ThermophysicalTransportModels/psiReactionThermo/lnInclude \
- -I$(LIB_SRC)/lagrangian/basic/lnInclude \
- -I$(LIB_SRC)/lagrangian/intermediate/lnInclude \
- -I$(LIB_SRC)/lagrangian/spray/lnInclude \
+ -I$(LIB_SRC)/ThermophysicalTransportModels/rhoReactionThermo/lnInclude \
-I$(LIB_SRC)/lagrangian/distributionModels/lnInclude \
-I$(LIB_SRC)/thermophysicalModels/specie/lnInclude \
-I$(LIB_SRC)/thermophysicalModels/basic/lnInclude \
@@ -20,35 +17,34 @@ EXE_INC = \
-I$(LIB_SRC)/thermophysicalModels/SLGThermo/lnInclude \
-I$(LIB_SRC)/thermophysicalModels/chemistryModel/lnInclude \
-I$(LIB_SRC)/radiationModels/lnInclude \
- -I$(LIB_SRC)/ODE/lnInclude \
- -I$(LIB_SRC)/engine/lnInclude \
-I$(LIB_SRC)/regionModels/regionModel/lnInclude \
-I$(LIB_SRC)/regionModels/surfaceFilmModels/lnInclude \
+ -I$(LIB_SRC)/lagrangian/basic/lnInclude \
+ -I$(LIB_SRC)/lagrangian/parcel/lnInclude \
+ -I$(LIB_SRC)/ODE/lnInclude \
-I$(LIB_SRC)/combustionModels/lnInclude
-
EXE_LIBS = \
-lfiniteVolume \
- -lmeshTools \
+ -lfvOptions \
-lsampling \
+ -lmeshTools \
+ -ldynamicFvMesh \
-lmomentumTransportModels \
-lfluidThermoMomentumTransportModels \
-lthermophysicalTransportModels \
- -lpsiReactionThermophysicalTransportModels \
- -llagrangian \
- -llagrangianIntermediate \
- -llagrangianTurbulence \
- -llagrangianSpray \
+ -lrhoReactionThermophysicalTransportModels \
-lspecie \
-lfluidThermophysicalModels \
- -lthermophysicalProperties \
-lreactionThermophysicalModels \
-lSLGThermo \
-lchemistryModel \
- -lradiationModels \
- -lODE \
- -lengine \
-lregionModels \
+ -lradiationModels \
-lsurfaceFilmModels \
- -lfvOptions \
+ -lsurfaceFilmDerivedFvPatchFields \
+ -llagrangian \
+ -llagrangianParcel \
+ -llagrangianParcelTurbulence \
+ -lODE \
-lcombustionModels
diff --git a/applications/solvers/lagrangian/reactingParcelFoam/UEqn.H b/applications/solvers/lagrangian/reactingParticleFoam/buoyantReactingParticleFoam/UEqn.H
similarity index 96%
rename from applications/solvers/lagrangian/reactingParcelFoam/UEqn.H
rename to applications/solvers/lagrangian/reactingParticleFoam/buoyantReactingParticleFoam/UEqn.H
index f6a9d58ef9..9701aa1dc4 100644
--- a/applications/solvers/lagrangian/reactingParcelFoam/UEqn.H
+++ b/applications/solvers/lagrangian/reactingParticleFoam/buoyantReactingParticleFoam/UEqn.H
@@ -6,7 +6,7 @@
+ MRF.DDt(rho, U)
+ turbulence->divDevTau(U)
==
- parcels.SU(U)
+ clouds.SU(U)
+ fvOptions(rho, U)
);
diff --git a/applications/solvers/lagrangian/coalChemistryFoam/coalChemistryFoam.C b/applications/solvers/lagrangian/reactingParticleFoam/buoyantReactingParticleFoam/buoyantReactingParticleFoam.C
similarity index 58%
rename from applications/solvers/lagrangian/coalChemistryFoam/coalChemistryFoam.C
rename to applications/solvers/lagrangian/reactingParticleFoam/buoyantReactingParticleFoam/buoyantReactingParticleFoam.C
index 652dda5124..b79289ebfc 100644
--- a/applications/solvers/lagrangian/coalChemistryFoam/coalChemistryFoam.C
+++ b/applications/solvers/lagrangian/reactingParticleFoam/buoyantReactingParticleFoam/buoyantReactingParticleFoam.C
@@ -22,26 +22,27 @@ License
along with OpenFOAM. If not, see .
Application
- coalChemistryFoam
+ buoyantReactingParticleFoam
Description
- Transient solver for compressible, turbulent flow, with coal and limestone
- particle clouds, an energy source, and combustion.
+ Transient solver for buoyant, compressible, turbulent flow with a particle
+ cloud and surface film modelling.
\*---------------------------------------------------------------------------*/
#include "fvCFD.H"
+#include "dynamicFvMesh.H"
#include "fluidThermoMomentumTransportModel.H"
-#include "psiReactionThermophysicalTransportModel.H"
-#include "basicThermoCloud.H"
-#include "coalCloud.H"
-#include "psiReactionThermo.H"
+#include "rhoReactionThermophysicalTransportModel.H"
+#include "parcelCloudList.H"
+#include "surfaceFilmModel.H"
#include "CombustionModel.H"
-#include "fvOptions.H"
#include "radiationModel.H"
#include "SLGThermo.H"
+#include "fvOptions.H"
#include "pimpleControl.H"
#include "pressureControl.H"
+#include "CorrectPhi.H"
#include "localEulerDdtScheme.H"
#include "fvcSmooth.H"
@@ -53,12 +54,12 @@ int main(int argc, char *argv[])
#include "setRootCaseLists.H"
#include "createTime.H"
- #include "createMesh.H"
- #include "createControl.H"
- #include "createTimeControls.H"
+ #include "createDynamicFvMesh.H"
+ #include "createDyMControls.H"
+ #include "initContinuityErrs.H"
#include "createFields.H"
#include "createFieldRefs.H"
- #include "initContinuityErrs.H"
+ #include "createRhoUfIfPresent.H"
turbulence->validate();
@@ -74,7 +75,20 @@ int main(int argc, char *argv[])
while (pimple.run(runTime))
{
- #include "readTimeControls.H"
+ #include "readDyMControls.H"
+
+ // Store divrhoU from the previous mesh so that it can be mapped
+ // and used in correctPhi to ensure the corrected phi has the
+ // same divergence
+ autoPtr divrhoU;
+ if (solvePrimaryRegion && correctPhi)
+ {
+ divrhoU = new volScalarField
+ (
+ "divrhoU",
+ fvc::div(fvc::absolute(phi, rho, U))
+ );
+ }
if (LTS)
{
@@ -83,24 +97,62 @@ int main(int argc, char *argv[])
else
{
#include "compressibleCourantNo.H"
- #include "setDeltaT.H"
+ #include "setMultiRegionDeltaT.H"
}
runTime++;
Info<< "Time = " << runTime.timeName() << nl << endl;
- rhoEffLagrangian = coalParcels.rhoEff() + limestoneParcels.rhoEff();
- pDyn = 0.5*rho*magSqr(U);
+ // Store momentum to set rhoUf for introduced faces.
+ autoPtr rhoU;
+ if (solvePrimaryRegion && rhoUf.valid())
+ {
+ rhoU = new volVectorField("rhoU", rho*U);
+ }
- coalParcels.evolve();
+ // Store the particle positions
+ clouds.storeGlobalPositions();
- limestoneParcels.evolve();
+ // Do any mesh changes
+ mesh.update();
- #include "rhoEqn.H"
+ if (solvePrimaryRegion && mesh.changing())
+ {
+ gh = (g & mesh.C()) - ghRef;
+ ghf = (g & mesh.Cf()) - ghRef;
- // --- Pressure-velocity PIMPLE corrector loop
- while (pimple.loop())
+
+ MRF.update();
+
+ if (correctPhi)
+ {
+ // Calculate absolute flux
+ // from the mapped surface velocity
+ phi = mesh.Sf() & rhoUf();
+
+ #include "../../compressible/rhoPimpleFoam/correctPhi.H"
+
+ // Make the fluxes relative to the mesh-motion
+ fvc::makeRelative(phi, rho, U);
+ }
+
+ if (checkMeshCourantNo)
+ {
+ #include "meshCourantNo.H"
+ }
+ }
+
+ clouds.evolve();
+ surfaceFilm.evolve();
+
+ if (solvePrimaryRegion && !pimple.simpleRho())
+ {
+ #include "rhoEqn.H"
+ }
+
+ // --- PIMPLE loop
+ while (solvePrimaryRegion && pimple.loop())
{
#include "UEqn.H"
#include "YEqn.H"
@@ -128,7 +180,7 @@ int main(int argc, char *argv[])
<< nl << endl;
}
- Info<< "End\n" << endl;
+ Info<< "End" << endl;
return 0;
}
diff --git a/applications/solvers/lagrangian/reactingParcelFoam/createFields.H b/applications/solvers/lagrangian/reactingParticleFoam/buoyantReactingParticleFoam/createFields.H
similarity index 96%
rename from applications/solvers/lagrangian/reactingParcelFoam/createFields.H
rename to applications/solvers/lagrangian/reactingParticleFoam/buoyantReactingParticleFoam/createFields.H
index f406c50700..e14202b476 100644
--- a/applications/solvers/lagrangian/reactingParcelFoam/createFields.H
+++ b/applications/solvers/lagrangian/reactingParticleFoam/buoyantReactingParticleFoam/createFields.H
@@ -94,12 +94,10 @@ volScalarField dpdt
Info<< "Creating field kinetic energy K\n" << endl;
volScalarField K("K", 0.5*magSqr(U));
-
#include "readGravitationalAcceleration.H"
#include "readhRef.H"
#include "gh.H"
-
volScalarField p_rgh
(
IOobject
@@ -116,7 +114,14 @@ volScalarField p_rgh
// Force p_rgh to be consistent with p
p_rgh = p - rho*gh;
-pressureControl pressureControl(p, rho, pimple.dict(), false);
+pressureControl pressureControl
+(
+ p,
+ p_rgh,
+ rho,
+ pimple.dict(),
+ thermo.incompressible()
+);
mesh.setFluxRequired(p_rgh.name());
diff --git a/applications/solvers/lagrangian/reactingParcelFoam/pEqn.H b/applications/solvers/lagrangian/reactingParticleFoam/buoyantReactingParticleFoam/pEqn.H
similarity index 90%
rename from applications/solvers/lagrangian/reactingParcelFoam/pEqn.H
rename to applications/solvers/lagrangian/reactingParticleFoam/buoyantReactingParticleFoam/pEqn.H
index d798132f1f..e4a55c95ab 100644
--- a/applications/solvers/lagrangian/reactingParcelFoam/pEqn.H
+++ b/applications/solvers/lagrangian/reactingParticleFoam/buoyantReactingParticleFoam/pEqn.H
@@ -33,7 +33,7 @@ fvScalarMatrix p_rghDDtEqn
fvc::ddt(rho) + psi*correction(fvm::ddt(p_rgh))
+ fvc::div(phiHbyA)
==
- parcels.Srho()
+ clouds.Srho()
+ surfaceFilm.Srho()
+ fvOptions(psi, p_rgh, rho.name())
);
@@ -87,7 +87,15 @@ if (pimple.simpleRho())
rho = thermo.rho();
}
+// Correct rhoUf if the mesh is moving
+fvc::correctRhoUf(rhoUf, rho, U, phi);
+
if (thermo.dpdt())
{
dpdt = fvc::ddt(p);
+
+ if (mesh.moving())
+ {
+ dpdt -= fvc::div(fvc::meshPhi(rho, U), p);
+ }
}
diff --git a/applications/solvers/lagrangian/reactingParticleFoam/createClouds.H b/applications/solvers/lagrangian/reactingParticleFoam/createClouds.H
new file mode 100644
index 0000000000..afdbf46543
--- /dev/null
+++ b/applications/solvers/lagrangian/reactingParticleFoam/createClouds.H
@@ -0,0 +1,2 @@
+Info<< "\nConstructing clouds" << endl;
+parcelCloudList clouds(rho, U, g, slgThermo);
diff --git a/applications/solvers/lagrangian/reactingParcelFoam/createFieldRefs.H b/applications/solvers/lagrangian/reactingParticleFoam/createFieldRefs.H
similarity index 100%
rename from applications/solvers/lagrangian/reactingParcelFoam/createFieldRefs.H
rename to applications/solvers/lagrangian/reactingParticleFoam/createFieldRefs.H
diff --git a/applications/solvers/lagrangian/sprayFoam/createFields.H b/applications/solvers/lagrangian/reactingParticleFoam/createFields.H
similarity index 72%
rename from applications/solvers/lagrangian/sprayFoam/createFields.H
rename to applications/solvers/lagrangian/reactingParticleFoam/createFields.H
index 1c7a456ded..0b47c7a365 100644
--- a/applications/solvers/lagrangian/sprayFoam/createFields.H
+++ b/applications/solvers/lagrangian/reactingParticleFoam/createFields.H
@@ -1,8 +1,8 @@
-#include "readGravitationalAcceleration.H"
+#include "createRDeltaT.H"
Info<< "Reading thermophysical properties\n" << endl;
-autoPtr pThermo(psiReactionThermo::New(mesh));
-psiReactionThermo& thermo = pThermo();
+autoPtr pThermo(rhoReactionThermo::New(mesh));
+rhoReactionThermo& thermo = pThermo();
thermo.validate(args.executable(), "h", "e");
SLGThermo slgThermo(mesh, thermo);
@@ -19,21 +19,20 @@ if (!composition.species().found(inertSpecie))
<< exit(FatalIOError);
}
-volScalarField& p = thermo.p();
-
+Info<< "Creating field rho\n" << endl;
volScalarField rho
(
IOobject
(
"rho",
runTime.timeName(),
- mesh,
- IOobject::READ_IF_PRESENT,
- IOobject::AUTO_WRITE
+ mesh
),
thermo.rho()
);
+volScalarField& p = thermo.p();
+
Info<< "\nReading field U\n" << endl;
volVectorField U
(
@@ -50,30 +49,6 @@ volVectorField U
#include "compressibleCreatePhi.H"
-mesh.setFluxRequired(p.name());
-
-dimensionedScalar rhoMax
-(
- dimensionedScalar::lookupOrDefault
- (
- "rhoMax",
- pimple.dict(),
- dimDensity,
- great
- )
-);
-
-dimensionedScalar rhoMin
-(
- dimensionedScalar::lookupOrDefault
- (
- "rhoMin",
- pimple.dict(),
- dimDensity,
- 0
- )
-);
-
Info<< "Creating turbulence model\n" << endl;
autoPtr turbulence
(
@@ -87,15 +62,20 @@ autoPtr turbulence
);
Info<< "Creating thermophysical transport model\n" << endl;
-autoPtr thermophysicalTransport
+autoPtr
+thermophysicalTransport
(
- psiReactionThermophysicalTransportModel::New(turbulence(), thermo)
+ rhoReactionThermophysicalTransportModel::New
+ (
+ turbulence(),
+ thermo
+ )
);
Info<< "Creating combustion model\n" << endl;
-autoPtr> combustion
+autoPtr> combustion
(
- CombustionModel::New(thermo, turbulence())
+ CombustionModel::New(thermo, turbulence())
);
Info<< "Creating field dpdt\n" << endl;
@@ -113,6 +93,19 @@ volScalarField dpdt
Info<< "Creating field kinetic energy K\n" << endl;
volScalarField K("K", 0.5*magSqr(U));
+
+#include "readGravitationalAcceleration.H"
+
+pressureControl pressureControl
+(
+ p,
+ rho,
+ pimple.dict(),
+ thermo.incompressible()
+);
+
+mesh.setFluxRequired(p.name());
+
multivariateSurfaceInterpolationScheme::fieldTable fields;
forAll(Y, i)
@@ -122,6 +115,7 @@ forAll(Y, i)
fields.add(thermo.he());
#include "createMRF.H"
-#include "createClouds.H"
#include "createRadiationModel.H"
+#include "createClouds.H"
+#include "createSurfaceFilmModel.H"
#include "createFvOptions.H"
diff --git a/applications/solvers/lagrangian/reactingParcelFoam/createSurfaceFilmModel.H b/applications/solvers/lagrangian/reactingParticleFoam/createSurfaceFilmModel.H
similarity index 100%
rename from applications/solvers/lagrangian/reactingParcelFoam/createSurfaceFilmModel.H
rename to applications/solvers/lagrangian/reactingParticleFoam/createSurfaceFilmModel.H
diff --git a/applications/solvers/lagrangian/sprayFoam/engineFoam/Make/files b/applications/solvers/lagrangian/reactingParticleFoam/engineFoam/Make/files
similarity index 100%
rename from applications/solvers/lagrangian/sprayFoam/engineFoam/Make/files
rename to applications/solvers/lagrangian/reactingParticleFoam/engineFoam/Make/files
diff --git a/applications/solvers/lagrangian/sprayFoam/Make/options b/applications/solvers/lagrangian/reactingParticleFoam/engineFoam/Make/options
similarity index 76%
rename from applications/solvers/lagrangian/sprayFoam/Make/options
rename to applications/solvers/lagrangian/reactingParticleFoam/engineFoam/Make/options
index 0459d9c2b5..f72db3fc08 100644
--- a/applications/solvers/lagrangian/sprayFoam/Make/options
+++ b/applications/solvers/lagrangian/reactingParticleFoam/engineFoam/Make/options
@@ -1,17 +1,14 @@
EXE_INC = \
-I. \
- -I../reactingParcelFoam \
- -I../../compressible/rhoPimpleFoam \
+ -I.. \
-I$(LIB_SRC)/finiteVolume/lnInclude \
- -I$(LIB_SRC)/meshTools/lnInclude \
-I$(LIB_SRC)/sampling/lnInclude \
+ -I$(LIB_SRC)/meshTools/lnInclude \
+ -I$(LIB_SRC)/dynamicFvMesh/lnInclude \
-I$(LIB_SRC)/MomentumTransportModels/momentumTransportModels/lnInclude \
-I$(LIB_SRC)/MomentumTransportModels/compressible/lnInclude \
-I$(LIB_SRC)/ThermophysicalTransportModels/lnInclude \
- -I$(LIB_SRC)/ThermophysicalTransportModels/psiReactionThermo/lnInclude \
- -I$(LIB_SRC)/lagrangian/basic/lnInclude \
- -I$(LIB_SRC)/lagrangian/intermediate/lnInclude \
- -I$(LIB_SRC)/lagrangian/spray/lnInclude \
+ -I$(LIB_SRC)/ThermophysicalTransportModels/rhoReactionThermo/lnInclude \
-I$(LIB_SRC)/lagrangian/distributionModels/lnInclude \
-I$(LIB_SRC)/thermophysicalModels/specie/lnInclude \
-I$(LIB_SRC)/thermophysicalModels/basic/lnInclude \
@@ -20,36 +17,36 @@ EXE_INC = \
-I$(LIB_SRC)/thermophysicalModels/SLGThermo/lnInclude \
-I$(LIB_SRC)/thermophysicalModels/chemistryModel/lnInclude \
-I$(LIB_SRC)/radiationModels/lnInclude \
- -I$(LIB_SRC)/ODE/lnInclude \
-I$(LIB_SRC)/regionModels/regionModel/lnInclude \
-I$(LIB_SRC)/regionModels/surfaceFilmModels/lnInclude \
+ -I$(LIB_SRC)/lagrangian/basic/lnInclude \
+ -I$(LIB_SRC)/lagrangian/parcel/lnInclude \
+ -I$(LIB_SRC)/ODE/lnInclude \
-I$(LIB_SRC)/combustionModels/lnInclude \
- -I$(LIB_SRC)/dynamicFvMesh/lnInclude \
- -I$(LIB_SRC)/meshTools/lnInclude
+ -I$(LIB_SRC)/engine/lnInclude
EXE_LIBS = \
+ -lfiniteVolume \
+ -lfvOptions \
+ -lsampling \
+ -lmeshTools \
+ -ldynamicFvMesh \
-lmomentumTransportModels \
-lfluidThermoMomentumTransportModels \
-lthermophysicalTransportModels \
- -lpsiReactionThermophysicalTransportModels \
- -llagrangian \
- -llagrangianIntermediate \
- -llagrangianTurbulence \
- -llagrangianSpray \
+ -lrhoReactionThermophysicalTransportModels \
-lspecie \
-lfluidThermophysicalModels \
- -lthermophysicalProperties \
-lreactionThermophysicalModels \
-lSLGThermo \
-lchemistryModel \
- -lradiationModels \
- -lODE \
-lregionModels \
+ -lradiationModels \
-lsurfaceFilmModels \
+ -lsurfaceFilmDerivedFvPatchFields \
+ -llagrangian \
+ -llagrangianParcel \
+ -llagrangianParcelTurbulence \
+ -lODE \
-lcombustionModels \
- -lfiniteVolume \
- -ldynamicFvMesh \
- -ltopoChangerFvMesh \
- -lfvOptions \
- -lmeshTools \
- -lsampling
+ -lengine
diff --git a/applications/solvers/lagrangian/sprayFoam/engineFoam/engineFoam.C b/applications/solvers/lagrangian/reactingParticleFoam/engineFoam/engineFoam.C
similarity index 59%
rename from applications/solvers/lagrangian/sprayFoam/engineFoam/engineFoam.C
rename to applications/solvers/lagrangian/reactingParticleFoam/engineFoam/engineFoam.C
index d58c9740ef..e74b12fcc0 100644
--- a/applications/solvers/lagrangian/sprayFoam/engineFoam/engineFoam.C
+++ b/applications/solvers/lagrangian/reactingParticleFoam/engineFoam/engineFoam.C
@@ -31,17 +31,20 @@ Description
\*---------------------------------------------------------------------------*/
#include "fvCFD.H"
-#include "engineTime.H"
#include "engineMesh.H"
#include "fluidThermoMomentumTransportModel.H"
-#include "psiReactionThermophysicalTransportModel.H"
-#include "basicSprayCloud.H"
-#include "psiReactionThermo.H"
+#include "rhoReactionThermophysicalTransportModel.H"
+#include "parcelCloudList.H"
+#include "surfaceFilmModel.H"
#include "CombustionModel.H"
#include "radiationModel.H"
#include "SLGThermo.H"
-#include "pimpleControl.H"
#include "fvOptions.H"
+#include "pimpleControl.H"
+#include "pressureControl.H"
+#include "CorrectPhi.H"
+#include "localEulerDdtScheme.H"
+#include "fvcSmooth.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
@@ -54,40 +57,101 @@ int main(int argc, char *argv[])
#include "setRootCaseLists.H"
#include "createEngineTime.H"
#include "createEngineMesh.H"
- #include "createControl.H"
- #include "readEngineTimeControls.H"
+ #include "createEngineControls.H"
+ #include "initContinuityErrs.H"
#include "createFields.H"
#include "createFieldRefs.H"
- #include "compressibleCourantNo.H"
- #include "setInitialDeltaT.H"
- #include "initContinuityErrs.H"
#include "createRhoUfIfPresent.H"
#include "startSummary.H"
turbulence->validate();
+ if (!LTS)
+ {
+ #include "compressibleCourantNo.H"
+ #include "setInitialDeltaT.H"
+ }
+
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
Info<< "\nStarting time loop\n" << endl;
while (pimple.run(runTime))
{
- #include "readEngineTimeControls.H"
- #include "compressibleCourantNo.H"
- #include "setDeltaT.H"
+ #include "readEngineControls.H"
+
+ // Store divrhoU from the previous mesh so that it can be mapped
+ // and used in correctPhi to ensure the corrected phi has the
+ // same divergence
+ autoPtr divrhoU;
+ if (solvePrimaryRegion && correctPhi)
+ {
+ divrhoU = new volScalarField
+ (
+ "divrhoU",
+ fvc::div(fvc::absolute(phi, rho, U))
+ );
+ }
+
+ if (LTS)
+ {
+ #include "setRDeltaT.H"
+ }
+ else
+ {
+ #include "compressibleCourantNo.H"
+ #include "setMultiRegionDeltaT.H"
+ }
runTime++;
Info<< "Engine time = " << runTime.theta() << runTime.unit() << endl;
+ // Store momentum to set rhoUf for introduced faces.
+ autoPtr rhoU;
+ if (solvePrimaryRegion && rhoUf.valid())
+ {
+ rhoU = new volVectorField("rhoU", rho*U);
+ }
+
+ // Store the particle positions
+ clouds.storeGlobalPositions();
+
+ // Do any mesh changes
mesh.move();
- parcels.evolve();
+ if (solvePrimaryRegion && mesh.changing())
+ {
+ MRF.update();
- #include "rhoEqn.H"
+ if (correctPhi)
+ {
+ // Calculate absolute flux
+ // from the mapped surface velocity
+ phi = mesh.Sf() & rhoUf();
- // --- Pressure-velocity PIMPLE corrector loop
- while (pimple.loop())
+ #include "../../compressible/rhoPimpleFoam/correctPhi.H"
+
+ // Make the fluxes relative to the mesh-motion
+ fvc::makeRelative(phi, rho, U);
+ }
+
+ if (checkMeshCourantNo)
+ {
+ #include "meshCourantNo.H"
+ }
+ }
+
+ clouds.evolve();
+ surfaceFilm.evolve();
+
+ if (solvePrimaryRegion && !pimple.simpleRho())
+ {
+ #include "rhoEqn.H"
+ }
+
+ // --- PIMPLE loop
+ while (solvePrimaryRegion && pimple.loop())
{
#include "UEqn.H"
#include "YEqn.H"
@@ -117,7 +181,7 @@ int main(int argc, char *argv[])
<< nl << endl;
}
- Info<< "End\n" << endl;
+ Info<< "End" << endl;
return 0;
}
diff --git a/applications/solvers/lagrangian/sprayFoam/engineFoam/logSummary.H b/applications/solvers/lagrangian/reactingParticleFoam/engineFoam/logSummary.H
similarity index 100%
rename from applications/solvers/lagrangian/sprayFoam/engineFoam/logSummary.H
rename to applications/solvers/lagrangian/reactingParticleFoam/engineFoam/logSummary.H
diff --git a/applications/solvers/lagrangian/sprayFoam/engineFoam/startSummary.H b/applications/solvers/lagrangian/reactingParticleFoam/engineFoam/startSummary.H
similarity index 100%
rename from applications/solvers/lagrangian/sprayFoam/engineFoam/startSummary.H
rename to applications/solvers/lagrangian/reactingParticleFoam/engineFoam/startSummary.H
diff --git a/applications/solvers/lagrangian/reactingParticleFoam/pEqn.H b/applications/solvers/lagrangian/reactingParticleFoam/pEqn.H
new file mode 100644
index 0000000000..f30bea2576
--- /dev/null
+++ b/applications/solvers/lagrangian/reactingParticleFoam/pEqn.H
@@ -0,0 +1,90 @@
+if (!pimple.simpleRho())
+{
+ rho = thermo.rho();
+}
+
+// Thermodynamic density needs to be updated by psi*d(p) after the
+// pressure solution
+const volScalarField psip0(psi*p);
+
+volScalarField rAU(1.0/UEqn.A());
+surfaceScalarField rhorAUf("rhorAUf", fvc::interpolate(rho*rAU));
+volVectorField HbyA(constrainHbyA(rAU*UEqn.H(), U, p));
+surfaceScalarField phiHbyA
+(
+ "phiHbyA",
+ (
+ fvc::interpolate(rho)*fvc::flux(HbyA)
+ + MRF.zeroFilter(rhorAUf*fvc::ddtCorr(rho, U, phi, rhoUf))
+ )
+);
+
+fvc::makeRelative(phiHbyA, rho, U);
+MRF.makeRelative(fvc::interpolate(rho), phiHbyA);
+
+// Update the pressure BCs to ensure flux consistency
+constrainPressure(p, rho, U, phiHbyA, rhorAUf, MRF);
+
+fvScalarMatrix pDDtEqn
+(
+ fvc::ddt(rho) + psi*correction(fvm::ddt(p))
+ + fvc::div(phiHbyA)
+ ==
+ clouds.Srho()
+ + surfaceFilm.Srho()
+ + fvOptions(psi, p, rho.name())
+);
+
+while (pimple.correctNonOrthogonal())
+{
+ fvScalarMatrix pEqn
+ (
+ pDDtEqn
+ - fvm::laplacian(rhorAUf, p)
+ );
+
+ pEqn.solve();
+
+ if (pimple.finalNonOrthogonalIter())
+ {
+ phi = phiHbyA + pEqn.flux();
+ }
+}
+
+p.relax();
+
+U = HbyA - rAU*fvc::grad(p);
+U.correctBoundaryConditions();
+fvOptions.correct(U);
+K = 0.5*magSqr(U);
+
+bool limitedp = pressureControl.limit(p);
+
+// Thermodynamic density update
+thermo.correctRho(psi*p - psip0);
+
+if (limitedp)
+{
+ rho = thermo.rho();
+}
+
+#include "rhoEqn.H"
+#include "compressibleContinuityErrs.H"
+
+if (pimple.simpleRho())
+{
+ rho = thermo.rho();
+}
+
+// Correct rhoUf if the mesh is moving
+fvc::correctRhoUf(rhoUf, rho, U, phi);
+
+if (thermo.dpdt())
+{
+ dpdt = fvc::ddt(p);
+
+ if (mesh.moving())
+ {
+ dpdt -= fvc::div(fvc::meshPhi(rho, U), p);
+ }
+}
diff --git a/applications/solvers/lagrangian/sprayFoam/sprayFoam.C b/applications/solvers/lagrangian/reactingParticleFoam/reactingParticleFoam.C
similarity index 75%
rename from applications/solvers/lagrangian/sprayFoam/sprayFoam.C
rename to applications/solvers/lagrangian/reactingParticleFoam/reactingParticleFoam.C
index 95d48bf813..1d60b82640 100644
--- a/applications/solvers/lagrangian/sprayFoam/sprayFoam.C
+++ b/applications/solvers/lagrangian/reactingParticleFoam/reactingParticleFoam.C
@@ -22,27 +22,29 @@ License
along with OpenFOAM. If not, see .
Application
- sprayFoam
+ reactingParticleFoam
Description
- Transient solver for compressible, turbulent flow with a spray particle
- cloud, with optional mesh motion and mesh topology changes.
+ Transient solver for compressible, turbulent flow with a particle cloud
+ and surface film modelling.
\*---------------------------------------------------------------------------*/
#include "fvCFD.H"
#include "dynamicFvMesh.H"
-#include "momentumTransportModel.H"
-#include "fluidThermophysicalTransportModel.H"
-#include "psiReactionThermophysicalTransportModel.H"
-#include "basicSprayCloud.H"
-#include "psiReactionThermo.H"
+#include "fluidThermoMomentumTransportModel.H"
+#include "rhoReactionThermophysicalTransportModel.H"
+#include "parcelCloudList.H"
+#include "surfaceFilmModel.H"
#include "CombustionModel.H"
#include "radiationModel.H"
#include "SLGThermo.H"
-#include "pimpleControl.H"
-#include "CorrectPhi.H"
#include "fvOptions.H"
+#include "pimpleControl.H"
+#include "pressureControl.H"
+#include "CorrectPhi.H"
+#include "localEulerDdtScheme.H"
+#include "fvcSmooth.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
@@ -54,15 +56,19 @@ int main(int argc, char *argv[])
#include "createTime.H"
#include "createDynamicFvMesh.H"
#include "createDyMControls.H"
+ #include "initContinuityErrs.H"
#include "createFields.H"
#include "createFieldRefs.H"
- #include "compressibleCourantNo.H"
- #include "setInitialDeltaT.H"
- #include "initContinuityErrs.H"
#include "createRhoUfIfPresent.H"
turbulence->validate();
+ if (!LTS)
+ {
+ #include "compressibleCourantNo.H"
+ #include "setInitialDeltaT.H"
+ }
+
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
Info<< "\nStarting time loop\n" << endl;
@@ -75,7 +81,7 @@ int main(int argc, char *argv[])
// and used in correctPhi to ensure the corrected phi has the
// same divergence
autoPtr divrhoU;
- if (correctPhi)
+ if (solvePrimaryRegion && correctPhi)
{
divrhoU = new volScalarField
(
@@ -84,8 +90,15 @@ int main(int argc, char *argv[])
);
}
- #include "compressibleCourantNo.H"
- #include "setDeltaT.H"
+ if (LTS)
+ {
+ #include "setRDeltaT.H"
+ }
+ else
+ {
+ #include "compressibleCourantNo.H"
+ #include "setMultiRegionDeltaT.H"
+ }
runTime++;
@@ -93,27 +106,28 @@ int main(int argc, char *argv[])
// Store momentum to set rhoUf for introduced faces.
autoPtr rhoU;
- if (rhoUf.valid())
+ if (solvePrimaryRegion && rhoUf.valid())
{
rhoU = new volVectorField("rhoU", rho*U);
}
// Store the particle positions
- parcels.storeGlobalPositions();
+ clouds.storeGlobalPositions();
// Do any mesh changes
mesh.update();
- if (mesh.changing())
+ if (solvePrimaryRegion && mesh.changing())
{
MRF.update();
if (correctPhi)
{
- // Calculate absolute flux from the mapped surface velocity
+ // Calculate absolute flux
+ // from the mapped surface velocity
phi = mesh.Sf() & rhoUf();
- #include "correctPhi.H"
+ #include "../../compressible/rhoPimpleFoam/correctPhi.H"
// Make the fluxes relative to the mesh-motion
fvc::makeRelative(phi, rho, U);
@@ -125,12 +139,16 @@ int main(int argc, char *argv[])
}
}
- parcels.evolve();
+ clouds.evolve();
+ surfaceFilm.evolve();
- #include "rhoEqn.H"
+ if (solvePrimaryRegion && !pimple.simpleRho())
+ {
+ #include "rhoEqn.H"
+ }
- // --- Pressure-velocity PIMPLE corrector loop
- while (pimple.loop())
+ // --- PIMPLE loop
+ while (solvePrimaryRegion && pimple.loop())
{
#include "UEqn.H"
#include "YEqn.H"
@@ -158,7 +176,7 @@ int main(int argc, char *argv[])
<< nl << endl;
}
- Info<< "End\n" << endl;
+ Info<< "End" << endl;
return 0;
}
diff --git a/applications/solvers/lagrangian/reactingParcelFoam/rhoEqn.H b/applications/solvers/lagrangian/reactingParticleFoam/rhoEqn.H
similarity index 94%
rename from applications/solvers/lagrangian/reactingParcelFoam/rhoEqn.H
rename to applications/solvers/lagrangian/reactingParticleFoam/rhoEqn.H
index f51ab88cde..4805dbed8f 100644
--- a/applications/solvers/lagrangian/reactingParcelFoam/rhoEqn.H
+++ b/applications/solvers/lagrangian/reactingParticleFoam/rhoEqn.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration | Website: https://openfoam.org
- \\ / A nd | Copyright (C) 2011-2018 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2020 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -35,7 +35,7 @@ Description
fvm::ddt(rho)
+ fvc::div(phi)
==
- parcels.Srho(rho)
+ clouds.Srho(rho)
+ surfaceFilm.Srho()
+ fvOptions(rho)
);
diff --git a/applications/solvers/lagrangian/reactingParcelFoam/setMultiRegionDeltaT.H b/applications/solvers/lagrangian/reactingParticleFoam/setMultiRegionDeltaT.H
similarity index 96%
rename from applications/solvers/lagrangian/reactingParcelFoam/setMultiRegionDeltaT.H
rename to applications/solvers/lagrangian/reactingParticleFoam/setMultiRegionDeltaT.H
index dc42e70770..5c7e38848d 100644
--- a/applications/solvers/lagrangian/reactingParcelFoam/setMultiRegionDeltaT.H
+++ b/applications/solvers/lagrangian/reactingParticleFoam/setMultiRegionDeltaT.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration | Website: https://openfoam.org
- \\ / A nd | Copyright (C) 2011-2018 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2020 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
diff --git a/applications/solvers/lagrangian/reactingParcelFoam/setRDeltaT.H b/applications/solvers/lagrangian/reactingParticleFoam/setRDeltaT.H
similarity index 98%
rename from applications/solvers/lagrangian/reactingParcelFoam/setRDeltaT.H
rename to applications/solvers/lagrangian/reactingParticleFoam/setRDeltaT.H
index a7dce60cf2..9c8c8dd2a7 100644
--- a/applications/solvers/lagrangian/reactingParcelFoam/setRDeltaT.H
+++ b/applications/solvers/lagrangian/reactingParticleFoam/setRDeltaT.H
@@ -78,7 +78,7 @@ License
(
mag
(
- parcels.hsTrans()/(mesh.V()*runTime.deltaT())
+ clouds.hsTrans()/(mesh.V()*runTime.deltaT())
+ combustion->Qdot()()
)
/(
diff --git a/applications/solvers/lagrangian/rhoParticleFoam/Make/options b/applications/solvers/lagrangian/rhoParticleFoam/Make/options
index ca7fbfcb72..46144ebabf 100644
--- a/applications/solvers/lagrangian/rhoParticleFoam/Make/options
+++ b/applications/solvers/lagrangian/rhoParticleFoam/Make/options
@@ -1,6 +1,6 @@
EXE_INC = \
-I$(LIB_SRC)/lagrangian/basic/lnInclude \
- -I$(LIB_SRC)/lagrangian/intermediate/lnInclude \
+ -I$(LIB_SRC)/lagrangian/parcel/lnInclude \
-I$(LIB_SRC)/thermophysicalModels/specie/lnInclude \
-I$(LIB_SRC)/thermophysicalModels/basic/lnInclude \
-I$(LIB_SRC)/thermophysicalModels/reactionThermo/lnInclude \
@@ -15,8 +15,8 @@ EXE_INC = \
EXE_LIBS = \
-llagrangian \
- -llagrangianIntermediate \
- -llagrangianTurbulence \
+ -llagrangianParcel \
+ -llagrangianParcelTurbulence \
-lfluidThermophysicalModels \
-lspecie \
-lradiationModels \
diff --git a/applications/solvers/lagrangian/rhoParticleFoam/createFields.H b/applications/solvers/lagrangian/rhoParticleFoam/createFields.H
index a3215faf6d..39e091c9b3 100644
--- a/applications/solvers/lagrangian/rhoParticleFoam/createFields.H
+++ b/applications/solvers/lagrangian/rhoParticleFoam/createFields.H
@@ -49,17 +49,5 @@ autoPtr turbulence
)
);
-const word kinematicCloudName
-(
- args.optionLookupOrDefault("cloudName", "kinematicCloud")
-);
-
-Info<< "Constructing kinematicCloud " << kinematicCloudName << endl;
-basicKinematicCloud kinematicCloud
-(
- kinematicCloudName,
- rho,
- U,
- thermo.mu(),
- g
-);
+Info<< "Constructing clouds" << endl;
+parcelCloudList clouds(rho, U, thermo.mu(), g);
diff --git a/applications/solvers/lagrangian/rhoParticleFoam/rhoParticleFoam.C b/applications/solvers/lagrangian/rhoParticleFoam/rhoParticleFoam.C
index 738916add4..5863d280f9 100644
--- a/applications/solvers/lagrangian/rhoParticleFoam/rhoParticleFoam.C
+++ b/applications/solvers/lagrangian/rhoParticleFoam/rhoParticleFoam.C
@@ -35,19 +35,12 @@ Description
#include "dynamicFvMesh.H"
#include "psiThermo.H"
#include "fluidThermoMomentumTransportModel.H"
-#include "basicKinematicCloud.H"
+#include "parcelCloudList.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
int main(int argc, char *argv[])
{
- argList::addOption
- (
- "cloudName",
- "name",
- "specify alternative cloud name. default is 'kinematicCloud'"
- );
-
#define NO_CONTROL
#include "postProcess.H"
@@ -65,7 +58,7 @@ int main(int argc, char *argv[])
{
Info<< "Time = " << runTime.timeName() << nl << endl;
- kinematicCloud.storeGlobalPositions();
+ clouds.storeGlobalPositions();
mesh.update();
@@ -74,8 +67,7 @@ int main(int argc, char *argv[])
U.correctBoundaryConditions();
}
- Info<< "Evolving " << kinematicCloud.name() << endl;
- kinematicCloud.evolve();
+ clouds.evolve();
runTime.write();
diff --git a/applications/solvers/lagrangian/reactingParcelFoam/simpleReactingParcelFoam/EEqn.H b/applications/solvers/lagrangian/simpleReactingParticleFoam/EEqn.H
similarity index 96%
rename from applications/solvers/lagrangian/reactingParcelFoam/simpleReactingParcelFoam/EEqn.H
rename to applications/solvers/lagrangian/simpleReactingParticleFoam/EEqn.H
index 4507b5817c..31d4828a45 100644
--- a/applications/solvers/lagrangian/reactingParcelFoam/simpleReactingParcelFoam/EEqn.H
+++ b/applications/solvers/lagrangian/simpleReactingParticleFoam/EEqn.H
@@ -12,7 +12,7 @@
+ thermophysicalTransport->divq(he)
==
rho*(U&g)
- + parcels.Sh(he)
+ + clouds.Sh(he)
+ radiation->Sh(thermo, he)
+ combustion->Qdot()
+ fvOptions(rho, he)
diff --git a/applications/solvers/lagrangian/simpleReactingParticleFoam/Make/files b/applications/solvers/lagrangian/simpleReactingParticleFoam/Make/files
new file mode 100644
index 0000000000..8d061ab3d0
--- /dev/null
+++ b/applications/solvers/lagrangian/simpleReactingParticleFoam/Make/files
@@ -0,0 +1,3 @@
+simpleReactingParticleFoam.C
+
+EXE = $(FOAM_APPBIN)/simpleReactingParticleFoam
diff --git a/applications/solvers/lagrangian/reactingParcelFoam/simpleReactingParcelFoam/Make/options b/applications/solvers/lagrangian/simpleReactingParticleFoam/Make/options
similarity index 86%
rename from applications/solvers/lagrangian/reactingParcelFoam/simpleReactingParcelFoam/Make/options
rename to applications/solvers/lagrangian/simpleReactingParticleFoam/Make/options
index 1dde5a705b..d8f8d49b5b 100644
--- a/applications/solvers/lagrangian/reactingParcelFoam/simpleReactingParcelFoam/Make/options
+++ b/applications/solvers/lagrangian/simpleReactingParticleFoam/Make/options
@@ -7,8 +7,7 @@ EXE_INC = \
-I$(LIB_SRC)/ThermophysicalTransportModels/lnInclude \
-I$(LIB_SRC)/ThermophysicalTransportModels/rhoReactionThermo/lnInclude \
-I$(LIB_SRC)/lagrangian/basic/lnInclude \
- -I$(LIB_SRC)/lagrangian/intermediate/lnInclude \
- -I$(LIB_SRC)/lagrangian/coalCombustion/lnInclude \
+ -I$(LIB_SRC)/lagrangian/parcel/lnInclude \
-I$(LIB_SRC)/lagrangian/distributionModels/lnInclude \
-I$(LIB_SRC)/thermophysicalModels/specie/lnInclude \
-I$(LIB_SRC)/thermophysicalModels/basic/lnInclude \
@@ -21,8 +20,7 @@ EXE_INC = \
-I$(LIB_SRC)/regionModels/regionModel/lnInclude \
-I$(LIB_SRC)/regionModels/surfaceFilmModels/lnInclude \
-I$(LIB_SRC)/combustionModels/lnInclude \
- -I$(LIB_SRC)/sampling/lnInclude \
- -I$(FOAM_SOLVERS)/combustion/reactingFoam
+ -I$(LIB_SRC)/sampling/lnInclude
EXE_LIBS = \
@@ -33,8 +31,8 @@ EXE_LIBS = \
-lthermophysicalTransportModels \
-lrhoReactionThermophysicalTransportModels \
-llagrangian \
- -llagrangianIntermediate \
- -llagrangianTurbulence \
+ -llagrangianParcel \
+ -llagrangianParcelTurbulence \
-lspecie \
-lfluidThermophysicalModels \
-lthermophysicalProperties \
diff --git a/applications/solvers/lagrangian/reactingParcelFoam/simpleReactingParcelFoam/UEqn.H b/applications/solvers/lagrangian/simpleReactingParticleFoam/UEqn.H
similarity index 94%
rename from applications/solvers/lagrangian/reactingParcelFoam/simpleReactingParcelFoam/UEqn.H
rename to applications/solvers/lagrangian/simpleReactingParticleFoam/UEqn.H
index 15257112f9..467692cd3f 100644
--- a/applications/solvers/lagrangian/reactingParcelFoam/simpleReactingParcelFoam/UEqn.H
+++ b/applications/solvers/lagrangian/simpleReactingParticleFoam/UEqn.H
@@ -7,7 +7,7 @@
+ turbulence->divDevTau(U)
==
rho()*g
- + parcels.SU(U)
+ + clouds.SU(U)
+ fvOptions(rho, U)
);
fvVectorMatrix& UEqn = tUEqn.ref();
diff --git a/applications/solvers/lagrangian/reactingParcelFoam/simpleReactingParcelFoam/YEqn.H b/applications/solvers/lagrangian/simpleReactingParticleFoam/YEqn.H
similarity index 96%
rename from applications/solvers/lagrangian/reactingParcelFoam/simpleReactingParcelFoam/YEqn.H
rename to applications/solvers/lagrangian/simpleReactingParticleFoam/YEqn.H
index 35b68bcc07..df6fb70471 100644
--- a/applications/solvers/lagrangian/reactingParcelFoam/simpleReactingParcelFoam/YEqn.H
+++ b/applications/solvers/lagrangian/simpleReactingParticleFoam/YEqn.H
@@ -24,7 +24,7 @@ tmp> mvConvection
mvConvection->fvmDiv(phi, Yi)
+ thermophysicalTransport->divj(Yi)
==
- parcels.SYi(i, Yi)
+ clouds.SYi(i, Yi)
+ combustion->R(Yi)
+ fvOptions(rho, Yi)
);
diff --git a/applications/solvers/lagrangian/simpleReactingParticleFoam/createClouds.H b/applications/solvers/lagrangian/simpleReactingParticleFoam/createClouds.H
new file mode 100644
index 0000000000..afdbf46543
--- /dev/null
+++ b/applications/solvers/lagrangian/simpleReactingParticleFoam/createClouds.H
@@ -0,0 +1,2 @@
+Info<< "\nConstructing clouds" << endl;
+parcelCloudList clouds(rho, U, g, slgThermo);
diff --git a/applications/solvers/lagrangian/sprayFoam/createFieldRefs.H b/applications/solvers/lagrangian/simpleReactingParticleFoam/createFieldRefs.H
similarity index 100%
rename from applications/solvers/lagrangian/sprayFoam/createFieldRefs.H
rename to applications/solvers/lagrangian/simpleReactingParticleFoam/createFieldRefs.H
index e7f76d8456..fdc479bc23 100644
--- a/applications/solvers/lagrangian/sprayFoam/createFieldRefs.H
+++ b/applications/solvers/lagrangian/simpleReactingParticleFoam/createFieldRefs.H
@@ -1,3 +1,3 @@
-const volScalarField& T = thermo.T();
const volScalarField& psi = thermo.psi();
+const volScalarField& T = thermo.T();
const label inertIndex(composition.species()[inertSpecie]);
diff --git a/applications/solvers/lagrangian/reactingParcelFoam/simpleReactingParcelFoam/createFields.H b/applications/solvers/lagrangian/simpleReactingParticleFoam/createFields.H
similarity index 100%
rename from applications/solvers/lagrangian/reactingParcelFoam/simpleReactingParcelFoam/createFields.H
rename to applications/solvers/lagrangian/simpleReactingParticleFoam/createFields.H
diff --git a/applications/solvers/lagrangian/reactingParcelFoam/simpleReactingParcelFoam/pEqn.H b/applications/solvers/lagrangian/simpleReactingParticleFoam/pEqn.H
similarity index 98%
rename from applications/solvers/lagrangian/reactingParcelFoam/simpleReactingParcelFoam/pEqn.H
rename to applications/solvers/lagrangian/simpleReactingParticleFoam/pEqn.H
index 1ce5db0ec8..e434a84acd 100644
--- a/applications/solvers/lagrangian/reactingParcelFoam/simpleReactingParcelFoam/pEqn.H
+++ b/applications/solvers/lagrangian/simpleReactingParticleFoam/pEqn.H
@@ -24,7 +24,7 @@ while (simple.correctNonOrthogonal())
fvc::div(phiHbyA)
- fvm::laplacian(rhorAUf, p)
==
- parcels.Srho()
+ clouds.Srho()
+ fvOptions(psi, p, rho.name())
);
diff --git a/applications/solvers/lagrangian/reactingParcelFoam/simpleReactingParcelFoam/simpleReactingParcelFoam.C b/applications/solvers/lagrangian/simpleReactingParticleFoam/simpleReactingParticleFoam.C
similarity index 96%
rename from applications/solvers/lagrangian/reactingParcelFoam/simpleReactingParcelFoam/simpleReactingParcelFoam.C
rename to applications/solvers/lagrangian/simpleReactingParticleFoam/simpleReactingParticleFoam.C
index 3c9631a652..0b0388afcc 100644
--- a/applications/solvers/lagrangian/reactingParcelFoam/simpleReactingParcelFoam/simpleReactingParcelFoam.C
+++ b/applications/solvers/lagrangian/simpleReactingParticleFoam/simpleReactingParticleFoam.C
@@ -22,7 +22,7 @@ License
along with OpenFOAM. If not, see .
Application
- simpleReactingParcelFoam
+ simpleReactingParticleFoam
Description
Steady state solver for compressible, turbulent flow with reacting,
@@ -33,7 +33,7 @@ Description
#include "fvCFD.H"
#include "fluidThermoMomentumTransportModel.H"
#include "rhoReactionThermophysicalTransportModel.H"
-#include "basicReactingMultiphaseCloud.H"
+#include "parcelCloudList.H"
#include "rhoReactionThermo.H"
#include "CombustionModel.H"
#include "radiationModel.H"
@@ -66,7 +66,7 @@ int main(int argc, char *argv[])
{
Info<< "Time = " << runTime.timeName() << nl << endl;
- parcels.evolve();
+ clouds.evolve();
// --- Pressure-velocity SIMPLE corrector loop
{
diff --git a/applications/solvers/lagrangian/sprayFoam/EEqn.H b/applications/solvers/lagrangian/sprayFoam/EEqn.H
deleted file mode 100644
index 7baab51647..0000000000
--- a/applications/solvers/lagrangian/sprayFoam/EEqn.H
+++ /dev/null
@@ -1,40 +0,0 @@
-{
- volScalarField& he = thermo.he();
-
- fvScalarMatrix EEqn
- (
- fvm::ddt(rho, he) + mvConvection->fvmDiv(phi, he)
- + fvc::ddt(rho, K) + fvc::div(phi, K)
- + (
- he.name() == "e"
- ? fvc::div
- (
- fvc::absolute(phi/fvc::interpolate(rho), U),
- p,
- "div(phiv,p)"
- )
- : -dpdt
- )
- + thermophysicalTransport->divq(he)
- ==
- rho*(U&g)
- + parcels.Sh(he)
- + radiation->Sh(thermo, he)
- + combustion->Qdot()
- + fvOptions(rho, he)
- );
-
- EEqn.relax();
-
- fvOptions.constrain(EEqn);
-
- EEqn.solve();
-
- fvOptions.correct(he);
-
- thermo.correct();
- radiation->correct();
-
- Info<< "T gas min/max " << min(T).value() << ", "
- << max(T).value() << endl;
-}
diff --git a/applications/solvers/lagrangian/sprayFoam/Make/files b/applications/solvers/lagrangian/sprayFoam/Make/files
deleted file mode 100644
index 893038ce0a..0000000000
--- a/applications/solvers/lagrangian/sprayFoam/Make/files
+++ /dev/null
@@ -1,3 +0,0 @@
-sprayFoam.C
-
-EXE = $(FOAM_APPBIN)/sprayFoam
diff --git a/applications/solvers/lagrangian/sprayFoam/UEqn.H b/applications/solvers/lagrangian/sprayFoam/UEqn.H
deleted file mode 100644
index cf97416e0b..0000000000
--- a/applications/solvers/lagrangian/sprayFoam/UEqn.H
+++ /dev/null
@@ -1,27 +0,0 @@
-// Solve the Momentum equation
-
-MRF.correctBoundaryVelocity(U);
-
-tmp tUEqn
-(
- fvm::ddt(rho, U) + fvm::div(phi, U)
- + MRF.DDt(rho, U)
- + turbulence->divDevTau(U)
- ==
- rho()*g
- + parcels.SU(U)
- + fvOptions(rho, U)
-);
-fvVectorMatrix& UEqn = tUEqn.ref();
-
-UEqn.relax();
-
-fvOptions.constrain(UEqn);
-
-if (pimple.momentumPredictor())
-{
- solve(UEqn == -fvc::grad(p));
-
- fvOptions.correct(U);
- K = 0.5*magSqr(U);
-}
diff --git a/applications/solvers/lagrangian/sprayFoam/YEqn.H b/applications/solvers/lagrangian/sprayFoam/YEqn.H
deleted file mode 100644
index b365b0bc4a..0000000000
--- a/applications/solvers/lagrangian/sprayFoam/YEqn.H
+++ /dev/null
@@ -1,48 +0,0 @@
-tmp> mvConvection
-(
- fv::convectionScheme::New
- (
- mesh,
- fields,
- phi,
- mesh.divScheme("div(phi,Yi_h)")
- )
-);
-
-{
- combustion->correct();
- volScalarField Yt(0.0*Y[0]);
-
- forAll(Y, i)
- {
- if (i != inertIndex && composition.active(i))
- {
- volScalarField& Yi = Y[i];
-
- fvScalarMatrix YEqn
- (
- fvm::ddt(rho, Yi)
- + mvConvection->fvmDiv(phi, Yi)
- + thermophysicalTransport->divj(Yi)
- ==
- parcels.SYi(i, Yi)
- + combustion->R(Yi)
- + fvOptions(rho, Yi)
- );
-
- YEqn.relax();
-
- fvOptions.constrain(YEqn);
-
- YEqn.solve("Yi");
-
- fvOptions.correct(Yi);
-
- Yi.max(0.0);
- Yt += Yi;
- }
- }
-
- Y[inertIndex] = scalar(1) - Yt;
- Y[inertIndex].max(0.0);
-}
diff --git a/applications/solvers/lagrangian/sprayFoam/createClouds.H b/applications/solvers/lagrangian/sprayFoam/createClouds.H
deleted file mode 100644
index ee0985ff70..0000000000
--- a/applications/solvers/lagrangian/sprayFoam/createClouds.H
+++ /dev/null
@@ -1,9 +0,0 @@
-Info<< "\nConstructing reacting cloud" << endl;
-basicSprayCloud parcels
-(
- "sprayCloud",
- rho,
- U,
- g,
- slgThermo
-);
diff --git a/applications/solvers/lagrangian/sprayFoam/pEqn.H b/applications/solvers/lagrangian/sprayFoam/pEqn.H
deleted file mode 100644
index 131a881486..0000000000
--- a/applications/solvers/lagrangian/sprayFoam/pEqn.H
+++ /dev/null
@@ -1,119 +0,0 @@
-rho = thermo.rho();
-rho = max(rho, rhoMin);
-rho = min(rho, rhoMax);
-rho.relax();
-
-volScalarField rAU(1.0/UEqn.A());
-surfaceScalarField rhorAUf("rhorAUf", fvc::interpolate(rho*rAU));
-volVectorField HbyA(constrainHbyA(rAU*UEqn.H(), U, p));
-
-if (pimple.nCorrPiso() <= 1)
-{
- tUEqn.clear();
-}
-
-if (pimple.transonic())
-{
- surfaceScalarField phid
- (
- "phid",
- fvc::interpolate(psi)
- *(
- fvc::flux(HbyA)
- + MRF.zeroFilter
- (
- rhorAUf*fvc::ddtCorr(rho, U, phi, rhoUf)/fvc::interpolate(rho)
- )
- )
- );
-
- fvc::makeRelative(phid, psi, U);
- MRF.makeRelative(fvc::interpolate(psi), phid);
-
- while (pimple.correctNonOrthogonal())
- {
- fvScalarMatrix pEqn
- (
- fvm::ddt(psi, p)
- + fvm::div(phid, p)
- - fvm::laplacian(rhorAUf, p)
- ==
- parcels.Srho()
- + fvOptions(psi, p, rho.name())
- );
-
- pEqn.solve();
-
- if (pimple.finalNonOrthogonalIter())
- {
- phi == pEqn.flux();
- }
- }
-}
-else
-{
- surfaceScalarField phiHbyA
- (
- "phiHbyA",
- fvc::interpolate(rho)*fvc::flux(HbyA)
- + MRF.zeroFilter(rhorAUf*fvc::ddtCorr(rho, U, phi, rhoUf))
- );
-
- fvc::makeRelative(phiHbyA, rho, U);
- MRF.makeRelative(fvc::interpolate(rho), phiHbyA);
-
- // Update the pressure BCs to ensure flux consistency
- constrainPressure(p, rho, U, phiHbyA, rhorAUf, MRF);
-
- while (pimple.correctNonOrthogonal())
- {
- fvScalarMatrix pEqn
- (
- fvm::ddt(psi, p)
- + fvc::div(phiHbyA)
- - fvm::laplacian(rhorAUf, p)
- ==
- parcels.Srho()
- + fvOptions(psi, p, rho.name())
- );
-
- pEqn.solve();
-
- if (pimple.finalNonOrthogonalIter())
- {
- phi = phiHbyA + pEqn.flux();
- }
- }
-}
-
-#include "rhoEqn.H"
-#include "compressibleContinuityErrs.H"
-
-// Explicitly relax pressure for momentum corrector
-p.relax();
-
-// Recalculate density from the relaxed pressure
-rho = thermo.rho();
-rho = max(rho, rhoMin);
-rho = min(rho, rhoMax);
-rho.relax();
-Info<< "rho max/min : " << max(rho).value()
- << " " << min(rho).value() << endl;
-
-U = HbyA - rAU*fvc::grad(p);
-U.correctBoundaryConditions();
-fvOptions.correct(U);
-K = 0.5*magSqr(U);
-
-// Correct rhoUf if the mesh is moving
-fvc::correctRhoUf(rhoUf, rho, U, phi);
-
-if (thermo.dpdt())
-{
- dpdt = fvc::ddt(p);
-
- if (mesh.moving())
- {
- dpdt -= fvc::div(fvc::meshPhi(rho, U), p);
- }
-}
diff --git a/applications/solvers/lagrangian/sprayFoam/rhoEqn.H b/applications/solvers/lagrangian/sprayFoam/rhoEqn.H
deleted file mode 100644
index e8c2e12473..0000000000
--- a/applications/solvers/lagrangian/sprayFoam/rhoEqn.H
+++ /dev/null
@@ -1,47 +0,0 @@
-/*---------------------------------------------------------------------------*\
- ========= |
- \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
- \\ / O peration | Website: https://openfoam.org
- \\ / A nd | Copyright (C) 2011-2018 OpenFOAM Foundation
- \\/ M anipulation |
--------------------------------------------------------------------------------
-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 .
-
-Global
- rhoEqn
-
-Description
- Solve the continuity for density.
-
-\*---------------------------------------------------------------------------*/
-
-{
- fvScalarMatrix rhoEqn
- (
- fvm::ddt(rho)
- + fvc::div(phi)
- ==
- parcels.Srho(rho)
- + fvOptions(rho)
- );
-
- rhoEqn.solve();
-
- fvOptions.correct(rho);
-}
-
-// ************************************************************************* //
diff --git a/applications/test/Function1/Make/options b/applications/test/Function1/Make/options
index 5854e1004e..e69de29bb2 100644
--- a/applications/test/Function1/Make/options
+++ b/applications/test/Function1/Make/options
@@ -1,14 +0,0 @@
-EXE_INC = \
- -DFULLDEBUG -g -O0 \
- -I$(LIB_SRC)/lagrangian/intermediate/lnInclude \
- -I$(LIB_SRC)/radiationModels/lnInclude \
- -I$(LIB_SRC)/finiteVolume/lnInclude \
- -I$(LIB_SRC)/meshTools/lnInclude
-
-EXE_LIBS = \
- -llagrangianIntermediate \
- -lradiationModels \
- -lregionModels \
- -lfiniteVolume \
- -lmeshTools \
- -lsampling
diff --git a/bin/DPMFoam b/bin/DPMFoam
new file mode 100755
index 0000000000..9a7d32a55b
--- /dev/null
+++ b/bin/DPMFoam
@@ -0,0 +1,58 @@
+#!/bin/sh
+#------------------------------------------------------------------------------
+# ========= |
+# \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
+# \\ / O peration | Website: https://openfoam.org
+# \\ / A nd | Copyright (C) 2020 OpenFOAM Foundation
+# \\/ M anipulation |
+#------------------------------------------------------------------------------
+# 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 .
+#
+# Script
+# DPMFoam
+#
+# Description
+# Script to inform the user that DPMFoam has been replaced by the more
+# general denseParticleFoam solver.
+#
+#------------------------------------------------------------------------------
+
+cat << EOF
+
+The DPMFoam solver has solver has been replaced by the more general
+denseParticleFoam solver, which supports incompressible flow, including the
+effect of the volume fraction of particles on the continuous phase, coupled to
+multiple run-time-selectable lagrangian clouds.
+
+To run with a single cloud rename the constant/*CloudProperties file to
+constant/cloudProperties.
+
+To run with a multiple clouds create a constant/clouds file with a list of the
+names of clouds in it. Each cloud then has a corresponding
+constant/Properties file.
+
+In addition, cloud properties files also now require a "type" entry to specify
+the type of cloud model used (e.g., thermoCloud, reactingMultiphaseCloud,
+collidingCloud, etc ...).
+
+See the following case for an example converted from DPMFoam:
+
+ \$FOAM_TUTORIALS/lagrangian/denseParticleFoam/Goldschmidt
+
+EOF
+
+#------------------------------------------------------------------------------
diff --git a/bin/MPPICFoam b/bin/MPPICFoam
new file mode 100755
index 0000000000..90938c4ee4
--- /dev/null
+++ b/bin/MPPICFoam
@@ -0,0 +1,58 @@
+#!/bin/sh
+#------------------------------------------------------------------------------
+# ========= |
+# \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
+# \\ / O peration | Website: https://openfoam.org
+# \\ / A nd | Copyright (C) 2020 OpenFOAM Foundation
+# \\/ M anipulation |
+#------------------------------------------------------------------------------
+# 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 .
+#
+# Script
+# MPPICFoam
+#
+# Description
+# Script to inform the user that MPPICFoam has been replaced by the more
+# general denseParticleFoam solver.
+#
+#------------------------------------------------------------------------------
+
+cat << EOF
+
+The MPPICFoam solver has solver has been replaced by the more general
+denseParticleFoam solver, which supports incompressible flow, including the
+effect of the volume fraction of particles on the continuous phase, coupled to
+multiple run-time-selectable lagrangian clouds.
+
+To run with a single cloud rename the constant/*CloudProperties file to
+constant/cloudProperties.
+
+To run with a multiple clouds create a constant/clouds file with a list of the
+names of clouds in it. Each cloud then has a corresponding
+constant/Properties file.
+
+In addition, cloud properties files also now require a "type" entry to specify
+the type of cloud model used (e.g., thermoCloud, reactingMultiphaseCloud,
+collidingCloud, etc ...).
+
+See the following case for an example converted from MPPICFoam:
+
+ \$FOAM_TUTORIALS/lagrangian/denseParticleFoam/GoldschmidtMPPIC
+
+EOF
+
+#------------------------------------------------------------------------------
diff --git a/bin/coalChemistryFoam b/bin/coalChemistryFoam
new file mode 100755
index 0000000000..460b681eb7
--- /dev/null
+++ b/bin/coalChemistryFoam
@@ -0,0 +1,57 @@
+#!/bin/sh
+#------------------------------------------------------------------------------
+# ========= |
+# \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
+# \\ / O peration | Website: https://openfoam.org
+# \\ / A nd | Copyright (C) 2020 OpenFOAM Foundation
+# \\/ M anipulation |
+#------------------------------------------------------------------------------
+# 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 .
+#
+# Script
+# coalChemistryFoam
+#
+# Description
+# Script to inform the user that coalChemistryFoam has been replaced by the
+# more general reactingParticleFoam solver.
+#
+#------------------------------------------------------------------------------
+
+cat << EOF
+
+The coalChemistryFoam solver has solver has been replaced by the more general
+reactingParticleFoam solver, which supports compressible reacting flow coupled
+to multiple run-time-selectable lagrangian clouds and surface film modelling.
+
+To run with a single cloud rename the constant/*CloudProperties file to
+constant/cloudProperties.
+
+To run with a multiple clouds create a constant/clouds file with a list of the
+names of clouds in it. Each cloud then has a corresponding
+constant/Properties file.
+
+In addition, cloud properties files also now require a "type" entry to specify
+the type of cloud model used (e.g., thermoCloud, reactingMultiphaseCloud,
+collidingCloud, etc ...).
+
+See the following case for an example converted from coalChemistryFoam:
+
+ \$FOAM_TUTORIALS/lagrangian/reactingParticleFoam/simplifiedSiwek
+
+EOF
+
+#------------------------------------------------------------------------------
diff --git a/bin/reactingParcelFoam b/bin/reactingParcelFoam
new file mode 100755
index 0000000000..fcce87f974
--- /dev/null
+++ b/bin/reactingParcelFoam
@@ -0,0 +1,58 @@
+#!/bin/sh
+#------------------------------------------------------------------------------
+# ========= |
+# \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
+# \\ / O peration | Website: https://openfoam.org
+# \\ / A nd | Copyright (C) 2020 OpenFOAM Foundation
+# \\/ M anipulation |
+#------------------------------------------------------------------------------
+# 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 .
+#
+# Script
+# reactingParcelFoam
+#
+# Description
+# Script to inform the user that reactingParcelFoam has been replaced by the
+# more general buoyantReactingParticleFoam solver.
+#
+#------------------------------------------------------------------------------
+
+cat << EOF
+
+The reactingParcelFoam solver has solver has been replaced by the more general
+buoyantReactingParticleFoam solver, which supports buoyant compressible
+reacting flow coupled to multiple run-time-selectable lagrangian clouds and
+surface film modelling.
+
+To run with a single cloud rename the constant/*CloudProperties file to
+constant/cloudProperties.
+
+To run with a multiple clouds create a constant/clouds file with a list of the
+names of clouds in it. Each cloud then has a corresponding
+constant/Properties file.
+
+In addition, cloud properties files also now require a "type" entry to specify
+the type of cloud model used (e.g., thermoCloud, reactingMultiphaseCloud,
+collidingCloud, etc ...).
+
+See the following case for an example converted from reactingParcelFoam:
+
+ \$FOAM_TUTORIALS/lagrangian/buoyantReactingParticleFoam/splashPanel
+
+EOF
+
+#------------------------------------------------------------------------------
diff --git a/bin/simpleReactingParcelFoam b/bin/simpleReactingParcelFoam
new file mode 100755
index 0000000000..2d38b4b091
--- /dev/null
+++ b/bin/simpleReactingParcelFoam
@@ -0,0 +1,58 @@
+#!/bin/sh
+#------------------------------------------------------------------------------
+# ========= |
+# \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
+# \\ / O peration | Website: https://openfoam.org
+# \\ / A nd | Copyright (C) 2020 OpenFOAM Foundation
+# \\/ M anipulation |
+#------------------------------------------------------------------------------
+# 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 .
+#
+# Script
+# simpleReactingParcelFoam
+#
+# Description
+# Script to inform the user that simpleReactingParcelFoam has been replaced
+# by the more general simpleReactingParticleFoam solver.
+#
+#------------------------------------------------------------------------------
+
+cat << EOF
+
+The simpleReactingParcelFoam solver has solver has been replaced by the more
+general simpleReactingParticleFoam solver, which supports buoyant compressible
+reacting flow coupled to multiple run-time-selectable lagrangian clouds and
+surface film modelling.
+
+To run with a single cloud rename the constant/*CloudProperties file to
+constant/cloudProperties.
+
+To run with a multiple clouds create a constant/clouds file with a list of the
+names of clouds in it. Each cloud then has a corresponding
+constant/Properties file.
+
+In addition, cloud properties files also now require a "type" entry to specify
+the type of cloud model used (e.g., thermoCloud, reactingMultiphaseCloud,
+collidingCloud, etc ...).
+
+See the following case for an example converted from simpleReactingParcelFoam:
+
+ \$FOAM_TUTORIALS/lagrangian/simpleReactingParticleFoam/verticalChannel
+
+EOF
+
+#------------------------------------------------------------------------------
diff --git a/bin/sprayFoam b/bin/sprayFoam
new file mode 100755
index 0000000000..62971bb377
--- /dev/null
+++ b/bin/sprayFoam
@@ -0,0 +1,57 @@
+#!/bin/sh
+#------------------------------------------------------------------------------
+# ========= |
+# \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
+# \\ / O peration | Website: https://openfoam.org
+# \\ / A nd | Copyright (C) 2020 OpenFOAM Foundation
+# \\/ M anipulation |
+#------------------------------------------------------------------------------
+# 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 .
+#
+# Script
+# sprayFoam
+#
+# Description
+# Script to inform the user that sprayFoam has been replaced by the
+# more general reactingParticleFoam solver.
+#
+#------------------------------------------------------------------------------
+
+cat << EOF
+
+The sprayFoam solver has solver has been replaced by the more general
+reactingParticleFoam solver, which supports compressible reacting flow coupled
+to multiple run-time-selectable lagrangian clouds and surface film modelling.
+
+To run with a single cloud rename the constant/*CloudProperties file to
+constant/cloudProperties.
+
+To run with a multiple clouds create a constant/clouds file with a list of the
+names of clouds in it. Each cloud then has a corresponding
+constant/Properties file.
+
+In addition, cloud properties files also now require a "type" entry to specify
+the type of cloud model used (e.g., thermoCloud, reactingMultiphaseCloud,
+collidingCloud, etc ...).
+
+See the following case for an example converted from sprayFoam:
+
+ \$FOAM_TUTORIALS/lagrangian/reactingParticleFoam/aachenBomb
+
+EOF
+
+#------------------------------------------------------------------------------
diff --git a/etc/caseDicts/postProcessing/solvers/particles/particles b/etc/caseDicts/postProcessing/solvers/particles/particles
index b4e9be99a8..372d9757d7 100644
--- a/etc/caseDicts/postProcessing/solvers/particles/particles
+++ b/etc/caseDicts/postProcessing/solvers/particles/particles
@@ -8,9 +8,8 @@
Description
Tracks a cloud of particles driven by the flow of the continuous phase.
- The cloud is specified by a kinematicCloudProperties file in the constant
- directory. A template file is provided in:
- $FOAM_ETC/caseDicts/solvers/lagrangian
+ The cloud is specified by a cloudProperties file in the constant directory.
+ A template file is provided in: $FOAM_ETC/caseDicts/solvers/lagrangian
\*---------------------------------------------------------------------------*/
diff --git a/etc/caseDicts/solvers/lagrangian/kinematicCloudProperties b/etc/caseDicts/solvers/lagrangian/cloudProperties
similarity index 98%
rename from etc/caseDicts/solvers/lagrangian/kinematicCloudProperties
rename to etc/caseDicts/solvers/lagrangian/cloudProperties
index 995b813d5e..17e9b46c62 100644
--- a/etc/caseDicts/solvers/lagrangian/kinematicCloudProperties
+++ b/etc/caseDicts/solvers/lagrangian/cloudProperties
@@ -10,7 +10,7 @@ FoamFile
version 2.0;
format ascii;
class dictionary;
- object kinematicCloudProperties;
+ object cloudProperties;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
diff --git a/src/OpenFOAM/include/macros.H b/src/OpenFOAM/include/macros.H
index 56bcafd3f8..29db28534d 100644
--- a/src/OpenFOAM/include/macros.H
+++ b/src/OpenFOAM/include/macros.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration | Website: https://openfoam.org
- \\ / A nd | Copyright (C) 2016-2018 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2016-2020 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -53,6 +53,10 @@ Description
//- Map 'name' to 'Name' via the predefined macro CAPITALIZE_name
#define CAPITALIZE(name) CAPITALIZE_##name
+//- Convert macro expression to a string
+#define STR_(x) #x
+#define STR(x) STR_(x)
+
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
#endif
diff --git a/src/engine/include/createEngineControls.H b/src/engine/include/createEngineControls.H
new file mode 100644
index 0000000000..5a57cfa6c7
--- /dev/null
+++ b/src/engine/include/createEngineControls.H
@@ -0,0 +1,3 @@
+#include "createDyMControls.H"
+
+maxDeltaT = runTime.userTimeToTime(maxDeltaT);
diff --git a/src/engine/include/createEngineTimeControls.H b/src/engine/include/createEngineTimeControls.H
new file mode 100644
index 0000000000..cb4f8e891c
--- /dev/null
+++ b/src/engine/include/createEngineTimeControls.H
@@ -0,0 +1,3 @@
+#include "createTimeControls.H"
+
+maxDeltaT = runTime.userTimeToTime(maxDeltaT);
diff --git a/src/engine/include/readEngineControls.H b/src/engine/include/readEngineControls.H
new file mode 100644
index 0000000000..4497ef2116
--- /dev/null
+++ b/src/engine/include/readEngineControls.H
@@ -0,0 +1,3 @@
+#include "readDyMControls.H"
+
+maxDeltaT = runTime.userTimeToTime(maxDeltaT);
diff --git a/src/engine/include/readEngineTimeControls.H b/src/engine/include/readEngineTimeControls.H
index cccee289dd..8d6d5f28b3 100644
--- a/src/engine/include/readEngineTimeControls.H
+++ b/src/engine/include/readEngineTimeControls.H
@@ -1,3 +1,3 @@
- #include "createTimeControls.H"
+ #include "readTimeControls.H"
maxDeltaT = runTime.userTimeToTime(maxDeltaT);
diff --git a/src/functionObjects/field/Make/files b/src/functionObjects/field/Make/files
index e24d4569f5..992fe8dc23 100644
--- a/src/functionObjects/field/Make/files
+++ b/src/functionObjects/field/Make/files
@@ -13,7 +13,6 @@ fieldValues/surfaceFieldValue/surfaceFieldValue.C
nearWallFields/nearWallFields.C
nearWallFields/findCellParticle.C
-nearWallFields/findCellParticleCloud.C
processorField/processorField.C
readFields/readFields.C
diff --git a/src/functionObjects/field/streamLine/streamLineParticleCloud.C b/src/functionObjects/field/streamLine/streamLineParticleCloud.C
index efd9848879..cb6993cd3e 100644
--- a/src/functionObjects/field/streamLine/streamLineParticleCloud.C
+++ b/src/functionObjects/field/streamLine/streamLineParticleCloud.C
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration | Website: https://openfoam.org
- \\ / A nd | Copyright (C) 2011-2018 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2020 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -29,7 +29,7 @@ License
namespace Foam
{
- defineTemplateTypeNameAndDebug(Cloud, 0);
+ defineTypeNameAndDebug(streamLineParticleCloud, 0);
}
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
diff --git a/src/functionObjects/field/streamLine/streamLineParticleCloud.H b/src/functionObjects/field/streamLine/streamLineParticleCloud.H
index 65fb4b9d4d..6bb1996dba 100644
--- a/src/functionObjects/field/streamLine/streamLineParticleCloud.H
+++ b/src/functionObjects/field/streamLine/streamLineParticleCloud.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration | Website: https://openfoam.org
- \\ / A nd | Copyright (C) 2011-2019 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2020 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -56,6 +56,11 @@ public:
//- Type of parcel the cloud was instantiated for
typedef streamLineParticle parcelType;
+
+ //- Runtime type information
+ TypeName("streamLineParticleCloud");
+
+
// Constructors
//- Construct given mesh
diff --git a/src/functionObjects/lagrangian/Make/options b/src/functionObjects/lagrangian/Make/options
index ae5045e54d..23da67464c 100644
--- a/src/functionObjects/lagrangian/Make/options
+++ b/src/functionObjects/lagrangian/Make/options
@@ -3,7 +3,7 @@ EXE_INC = \
-I$(LIB_SRC)/transportModels/lnInclude \
-I$(LIB_SRC)/meshTools/lnInclude \
-I$(LIB_SRC)/lagrangian/basic/lnInclude \
- -I$(LIB_SRC)/lagrangian/intermediate/lnInclude \
+ -I$(LIB_SRC)/lagrangian/parcel/lnInclude \
-I$(LIB_SRC)/lagrangian/DSMC/lnInclude \
-I$(LIB_SRC)/regionModels/regionModel/lnInclude \
-I$(LIB_SRC)/regionModels/surfaceFilmModels/lnInclude
@@ -13,7 +13,7 @@ LIB_LIBS = \
-lincompressibleTransportModels \
-lmeshTools \
-llagrangian \
- -llagrangianIntermediate \
- -llagrangianTurbulence \
+ -llagrangianParcel \
+ -llagrangianParcelTurbulence \
-lregionModels \
-lsurfaceFilmModels
diff --git a/src/functionObjects/lagrangian/cloudInfo/cloudInfo.C b/src/functionObjects/lagrangian/cloudInfo/cloudInfo.C
index b5f51d44af..495754d02c 100644
--- a/src/functionObjects/lagrangian/cloudInfo/cloudInfo.C
+++ b/src/functionObjects/lagrangian/cloudInfo/cloudInfo.C
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration | Website: https://openfoam.org
- \\ / A nd | Copyright (C) 2012-2018 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2012-2020 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,7 +24,7 @@ License
\*---------------------------------------------------------------------------*/
#include "cloudInfo.H"
-#include "kinematicCloud.H"
+#include "parcelCloud.H"
#include "dictionary.H"
#include "PstreamReduceOps.H"
#include "addToRunTimeSelectionTable.H"
@@ -122,8 +122,7 @@ bool Foam::functionObjects::cloudInfo::write()
{
const word& cloudName = names()[i];
- const kinematicCloud& cloud =
- obr_.lookupObject(cloudName);
+ const parcelCloud& cloud = obr_.lookupObject(cloudName);
label nParcels = returnReduce(cloud.nParcels(), sumOp