Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found

Target

Select target project
No results found
Show changes
Showing
with 98 additions and 67 deletions
......@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
......@@ -116,7 +116,7 @@ public:
//- Correct the flame-wrinking Xi
virtual void correct()
{
notImplemented("transport::correct()");
NotImplemented;
}
//- Correct the flame-wrinking Xi using the given convection scheme
......
......@@ -73,6 +73,8 @@ if (ign.ignited())
+ fvm::div(phiSt, b)
- fvm::Sp(fvc::div(phiSt), b)
- fvm::laplacian(Db, b)
==
betav*fvOptions(rho, b)
);
......@@ -82,8 +84,14 @@ if (ign.ignited())
// Solve for b
// ~~~~~~~~~~~
bEqn.relax();
fvOptions.constrain(bEqn);
bEqn.solve();
fvOptions.correct(b);
Info<< "min(b) = " << min(b).value() << endl;
if (composition.contains("ft"))
......
......@@ -49,7 +49,7 @@ mesh.setFluxRequired(p.name());
Info<< "Creating turbulence model\n" << endl;
autoPtr<compressible::RASModel> turbulence
(
compressible::RASModel::New
compressible::New<compressible::RASModel>
(
rho,
U,
......
......@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
......@@ -172,7 +172,7 @@ inline Foam::scalar Foam::laminarFlameSpeedModels::SCOPE::SuRef
}
else
{
FatalErrorIn("laminarFlameSpeedModels::SCOPE::SuRef(scalar phi)")
FatalErrorInFunction
<< "phi = " << phi
<< " cannot be handled by SCOPE function with the "
"given coefficients"
......@@ -210,7 +210,7 @@ inline Foam::scalar Foam::laminarFlameSpeedModels::SCOPE::Ma
}
else
{
FatalErrorIn("laminarFlameSpeedModels::SCOPE::Ma(scalar phi)")
FatalErrorInFunction
<< "phi = " << phi
<< " cannot be handled by SCOPE function with the "
"given coefficients"
......
......@@ -25,6 +25,8 @@ if (pimple.transonic())
betav*fvm::ddt(psi, p)
+ fvm::div(phid, p)
- fvm::laplacian(rho*invA, p)
==
betav*fvOptions(psi, p, rho.name())
);
pEqn.solve(mesh.solver(p.select(pimple.finalInnerIter())));
......@@ -53,6 +55,8 @@ else
betav*fvm::ddt(psi, p)
+ fvc::div(phiHbyA)
- fvm::laplacian(rho*invA, p)
==
betav*fvOptions(psi, p, rho.name())
);
pEqn.solve(mesh.solver(p.select(pimple.finalInnerIter())));
......@@ -69,6 +73,7 @@ else
U = HbyA - (invA & (betav*fvc::grad(p)));
U.correctBoundaryConditions();
fvOptions.correct(U);
K = 0.5*magSqr(U);
if (thermo.dpdt())
......
EXE_INC = \
-I$(LIB_SRC)/finiteVolume/lnInclude \
-I$(LIB_SRC)/fvOptions/lnInclude \
-I$(LIB_SRC)/sampling/lnInclude \
-I$(LIB_SRC)/meshTools/lnInclude\
-I$(LIB_SRC)/engine/lnInclude \
-I$(LIB_SRC)/thermophysicalModels/specie/lnInclude \
-I$(LIB_SRC)/transportModels/compressible/lnInclude \
......@@ -10,13 +6,12 @@ EXE_INC = \
-I$(LIB_SRC)/thermophysicalModels/reactionThermo/lnInclude \
-I$(LIB_SRC)/TurbulenceModels/turbulenceModels/lnInclude \
-I$(LIB_SRC)/TurbulenceModels/compressible/lnInclude \
-I$(LIB_SRC)/thermophysicalModels/laminarFlameSpeed/lnInclude
-I$(LIB_SRC)/thermophysicalModels/laminarFlameSpeed/lnInclude \
-I$(LIB_SRC)/finiteVolume/lnInclude \
-I$(LIB_SRC)/sampling/lnInclude \
-I$(LIB_SRC)/meshTools/lnInclude
EXE_LIBS = \
-lfiniteVolume \
-lfvOptions \
-lsampling \
-lmeshTools \
-lengine \
-lturbulenceModels \
-lcompressibleTurbulenceModels \
......@@ -24,4 +19,8 @@ EXE_LIBS = \
-lfluidThermophysicalModels \
-lreactionThermophysicalModels \
-lspecie \
-llaminarFlameSpeedModels
-llaminarFlameSpeedModels \
-lfiniteVolume \
-lfvOptions \
-lsampling \
-lmeshTools
......@@ -6,8 +6,7 @@
+ MRF.DDt(rho, U)
+ turbulence->divDevRhoReff(U)
==
rho*g
+ fvOptions(rho, U)
fvOptions(rho, U)
);
UEqn.relax();
......
......@@ -24,6 +24,9 @@ License
Application
XiFoam
Group
grpCombustionSolvers grpMovingMeshSolvers
Description
Solver for compressible premixed/partially-premixed combustion with
turbulence modelling.
......@@ -58,7 +61,7 @@ Description
#include "Switch.H"
#include "pimpleControl.H"
#include "CorrectPhi.H"
#include "fvIOoptionList.H"
#include "fvOptions.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
......
......@@ -24,6 +24,9 @@ License
Application
XiFoam
Group
grpCombustionSolvers
Description
Solver for compressible premixed/partially-premixed combustion with
turbulence modelling.
......@@ -56,7 +59,7 @@ Description
#include "ignition.H"
#include "Switch.H"
#include "pimpleControl.H"
#include "fvIOoptionList.H"
#include "fvOptions.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
......@@ -70,7 +73,6 @@ int main(int argc, char *argv[])
pimpleControl pimple(mesh);
#include "readCombustionProperties.H"
#include "readGravitationalAcceleration.H"
#include "createFields.H"
#include "createMRF.H"
#include "createFvOptions.H"
......@@ -79,6 +81,8 @@ int main(int argc, char *argv[])
#include "compressibleCourantNo.H"
#include "setInitialDeltaT.H"
turbulence->validate();
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
Info<< "\nStarting time loop\n" << endl;
......
EXE_INC = \
-I$(LIB_SRC)/TurbulenceModels/turbulenceModels/lnInclude \
-I$(LIB_SRC)/TurbulenceModels/compressible/lnInclude \
-I$(LIB_SRC)/thermophysicalModels/specie/lnInclude \
-I$(LIB_SRC)/thermophysicalModels/thermophysicalFunctions/lnInclude \
-I$(LIB_SRC)/thermophysicalModels/reactionThermo/lnInclude \
-I$(LIB_SRC)/transportModels/compressible/lnInclude \
-I$(LIB_SRC)/thermophysicalModels/basic/lnInclude \
-I$(LIB_SRC)/thermophysicalModels/laminarFlameSpeed/lnInclude \
-I$(LIB_SRC)/transportModels/compressible/lnInclude \
-I$(LIB_SRC)/ODE/lnInclude\
-I$(LIB_SRC)/thermophysicalModels/chemistryModel/lnInclude \
-I$(LIB_SRC)/finiteVolume/lnInclude \
-I$(LIB_SRC)/meshTools/lnInclude
EXE_LIBS = \
-lturbulenceModels \
-lcompressibleTurbulenceModels \
-lreactionThermophysicalModels \
-lcompressibleTransportModels \
-lfluidThermophysicalModels \
-lchemistryModel \
-lODE \
-lthermophysicalFunctions \
-lspecie \
-lfiniteVolume \
-lmeshTools
......@@ -24,10 +24,14 @@ License
Application
chemFoam
Group
grpCombustionSolvers
Description
Solver for chemistry problems
- designed for use on single cell cases to provide comparison against
other chemistry solvers
Solver for chemistry problems designed for use on single cell cases to
provide comparison against other chemistry solvers
Note:
- single cell mesh created on-the-fly
- fields created on the fly from the initial conditions
......@@ -35,7 +39,6 @@ Description
#include "fvCFD.H"
#include "psiReactionThermo.H"
#include "turbulentFluidThermoModel.H"
#include "psiChemistryModel.H"
#include "chemistrySolver.H"
#include "OFstream.H"
......
if (runTime.controlDict().lookupOrDefault("suppressSolverInfo", false))
{
lduMatrix::debug = 0;
}
Switch adjustTimeStep(runTime.controlDict().lookup("adjustTimeStep"));
scalar maxDeltaT(readScalar(runTime.controlDict().lookup("maxDeltaT")));
if (mesh.nCells() != 1)
{
FatalErrorIn(args.executable())
FatalErrorInFunction
<< "Solver only applicable to single cell cases"
<< exit(FatalError);
}
......@@ -86,20 +86,6 @@
#include "createPhi.H"
Info << "Creating turbulence model.\n" << endl;
autoPtr<compressible::turbulenceModel> turbulence
(
compressible::turbulenceModel::New
(
rho,
U,
phi,
thermo
)
);
OFstream post(args.path()/"chemFoam.out");
post<< "# Time" << token::TAB << "Temperature [K]" << token::TAB
<< "Pressure [Pa]" << endl;
......@@ -12,7 +12,6 @@ EXE_INC = \
-I$(LIB_SRC)/finiteVolume/lnInclude \
-I$(LIB_SRC)/sampling/lnInclude \
-I$(LIB_SRC)/meshTools/lnInclude \
-I$(LIB_SRC)/fvOptions/lnInclude
EXE_LIBS = \
-lengine \
......
......@@ -22,7 +22,10 @@ License
along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
Application
engineFoam
coldEngineFoam
Group
grpCombustionSolvers grpMovingMeshSolvers
Description
Solver for cold-flow in internal combustion engines.
......@@ -35,7 +38,7 @@ Description
#include "psiThermo.H"
#include "turbulentFluidThermoModel.H"
#include "OFstream.H"
#include "fvIOoptionList.H"
#include "fvOptions.H"
#include "pimpleControl.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
......@@ -59,6 +62,8 @@ int main(int argc, char *argv[])
#include "setInitialDeltaT.H"
#include "startSummary.H"
turbulence->validate();
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
Info<< "\nStarting time loop\n" << endl;
......
/*---------------------------------------------------------------------------*\
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 2015 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 <http://www.gnu.org/licenses/>.
\defgroup grpCombustionSolvers Combustion solvers
@{
\ingroup grpSolvers
This group contains combustion solvers.
@}
\*---------------------------------------------------------------------------*/
EXE_INC = \
-I$(FOAM_SOLVERS)/combustion/XiFoam \
-I$(LIB_SRC)/finiteVolume/lnInclude \
-I$(LIB_SRC)/fvOptions/lnInclude \
-I$(LIB_SRC)/sampling/lnInclude \
-I$(LIB_SRC)/meshTools/lnInclude \
-I$(LIB_SRC)/engine/lnInclude \
......
......@@ -24,6 +24,9 @@ License
Application
engineFoam
Group
grpCombustionSolvers
Description
Solver for internal combustion engines.
......@@ -59,7 +62,7 @@ Description
#include "OFstream.H"
#include "mathematicalConstants.H"
#include "pimpleControl.H"
#include "fvIOoptionList.H"
#include "fvOptions.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
......@@ -83,6 +86,8 @@ int main(int argc, char *argv[])
#include "setInitialDeltaT.H"
#include "startSummary.H"
turbulence->validate();
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
Info<< "\nStarting time loop\n" << endl;
......
EXE_INC = \
-I$(LIB_SRC)/finiteVolume/lnInclude \
-I$(LIB_SRC)/fvOptions/lnInclude \
-I${LIB_SRC}/meshTools/lnInclude \
-I${LIB_SRC}/sampling/lnInclude \
-I$(LIB_SRC)/TurbulenceModels/turbulenceModels/lnInclude \
......
......@@ -24,8 +24,11 @@ License
Application
fireFoam
Group
grpCombustionSolvers
Description
Transient PIMPLE solver for Fires and turbulent diffusion flames with
Transient PIMPLE solver for fires and turbulent diffusion flames with
reacting Lagrangian parcels, surface film and pyrolysis modelling.
\*---------------------------------------------------------------------------*/
......@@ -40,7 +43,7 @@ Description
#include "solidChemistryModel.H"
#include "psiCombustionModel.H"
#include "pimpleControl.H"
#include "fvIOoptionList.H"
#include "fvOptions.H"
#include "fixedFluxPressureFvPatchScalarField.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
......@@ -67,6 +70,8 @@ int main(int argc, char *argv[])
#include "setInitialDeltaT.H"
#include "readPyrolysisTimeControls.H"
turbulence->validate();
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
Info<< "\nStarting time loop\n" << endl;
......