Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Development
openfoam
Commits
8cf3f429
Commit
8cf3f429
authored
Feb 11, 2010
by
mattijs
Browse files
Merge branch 'master' of /home/noisy3/OpenFOAM/OpenFOAM-dev
parents
b6082c30
9259d4f6
Changes
297
Hide whitespace changes
Inline
Side-by-side
applications/solvers/combustion/PDRFoam/Make/options
View file @
8cf3f429
...
...
@@ -15,8 +15,7 @@ EXE_INC = \
-I$(LIB_SRC)/finiteVolume/lnInclude \
-I$(LIB_SRC)/dynamicFvMesh/lnInclude \
-I$(LIB_SRC)/dynamicMesh/lnInclude \
-I$(LIB_SRC)/meshTools/lnInclude \
-I$(LIB_SRC)/triSurface/lnInclude
-I$(LIB_SRC)/meshTools/lnInclude
EXE_LIBS = \
-lengine \
...
...
applications/solvers/combustion/fireFoam/Allwclean
0 → 100755
View file @
8cf3f429
#!/bin/sh
cd
${
0
%/*
}
||
exit
1
# run from this directory
set
-x
wclean libso combustionModels
wclean all sensibleEnthalpyCombustionThermophysicalModels
wclean
# ----------------------------------------------------------------- end-of-file
applications/solvers/combustion/fireFoam/Allwmake
0 → 100755
View file @
8cf3f429
#!/bin/sh
cd
${
0
%/*
}
||
exit
1
# run from this directory
set
-x
sensibleEnthalpyCombustionThermophysicalModels/Allwmake
wmake libso combustionModels
wmake
# ----------------------------------------------------------------- end-of-file
applications/solvers/combustion/fireFoam/Make/files
0 → 100644
View file @
8cf3f429
fireFoam.C
EXE = $(FOAM_APPBIN)/fireFoam
applications/solvers/combustion/fireFoam/Make/options
0 → 100644
View file @
8cf3f429
EXE_INC = \
-I./combustionModels/lnInclude \
-I./sensibleEnthalpyCombustionThermophysicalModels/basic/lnInclude \
-I./sensibleEnthalpyCombustionThermophysicalModels/reactionThermo/lnInclude \
-I$(LIB_SRC)/thermophysicalModels/basic/lnInclude \
-I$(LIB_SRC)/thermophysicalModels/specie/lnInclude \
-I$(LIB_SRC)/thermophysicalModels/reactionThermo/lnInclude \
-I$(LIB_SRC)/finiteVolume/lnInclude \
-I$(LIB_SRC)/turbulenceModels/compressible/turbulenceModel \
-I$(LIB_SRC)/thermophysicalModels/radiation/lnInclude
EXE_LIBS = \
-lbasicSensibleEnthalpyThermophysicalModels \
-lreactionSensibleEnthalpyThermophysicalModels \
-lcombustionModels \
-lspecie \
-lreactionThermophysicalModels \
-lbasicThermophysicalModels \
-lfiniteVolume \
-lcompressibleLESModels \
-lcompressibleRASModels \
-lradiation
applications/solvers/combustion/fireFoam/UEqn.H
0 → 100644
View file @
8cf3f429
fvVectorMatrix
UEqn
(
fvm
::
ddt
(
rho
,
U
)
+
fvm
::
div
(
phi
,
U
)
+
turbulence
->
divDevRhoReff
(
U
)
);
UEqn
.
relax
();
if
(
oCorr
==
nOuterCorr
-
1
)
{
solve
(
UEqn
==
fvc
::
reconstruct
(
fvc
::
interpolate
(
rho
)
*
(
g
&
mesh
.
Sf
())
-
fvc
::
snGrad
(
p
)
*
mesh
.
magSf
()
),
mesh
.
solver
(
"UFinal"
)
);
}
else
{
solve
(
UEqn
==
fvc
::
reconstruct
(
fvc
::
interpolate
(
rho
)
*
(
g
&
mesh
.
Sf
())
-
fvc
::
snGrad
(
p
)
*
mesh
.
magSf
()
)
);
}
applications/solvers/combustion/fireFoam/combustionModels/Make/files
0 → 100644
View file @
8cf3f429
combustionModel/combustionModel.C
combustionModel/newCombustionModel.C
infinitelyFastChemistry/infinitelyFastChemistry.C
noCombustion/noCombustion.C
LIB = $(FOAM_LIBBIN)/libcombustionModels
applications/solvers/combustion/fireFoam/combustionModels/Make/options
0 → 100644
View file @
8cf3f429
EXE_INC = \
-I../sensibleEnthalpyCombustionThermophysicalModels/basic/lnInclude \
-I../sensibleEnthalpyCombustionThermophysicalModels/reactionThermo/lnInclude \
-I$(LIB_SRC)/thermophysicalModels/basic/lnInclude \
-I$(LIB_SRC)/thermophysicalModels/reactionThermo/lnInclude \
-I$(LIB_SRC)/thermophysicalModels/specie/lnInclude \
-I$(FOAM_SRC)/turbulenceModels/compressible/turbulenceModel \
-I$(FOAM_SRC)/finiteVolume/lnInclude
LIB_LIBS = \
-lfiniteVolume
applications/solvers/combustion/fireFoam/combustionModels/combustionModel/combustionModel.C
0 → 100644
View file @
8cf3f429
/*---------------------------------------------------------------------------*\
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
\\/ 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 2 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, write to the Free Software Foundation,
Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
\*---------------------------------------------------------------------------*/
#include
"combustionModel.H"
#include
"fvm.H"
// * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
namespace
Foam
{
defineTypeNameAndDebug
(
combustionModel
,
0
);
defineRunTimeSelectionTable
(
combustionModel
,
dictionary
);
};
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
Foam
::
combustionModel
::
combustionModel
(
const
dictionary
&
combustionProperties
,
const
hsCombustionThermo
&
thermo
,
const
compressible
::
turbulenceModel
&
turbulence
,
const
surfaceScalarField
&
phi
,
const
volScalarField
&
rho
)
:
combustionModelCoeffs_
(
combustionProperties
.
subDict
(
word
(
combustionProperties
.
lookup
(
"combustionModel"
))
+
"Coeffs"
)
),
thermo_
(
thermo
),
turbulence_
(
turbulence
),
mesh_
(
phi
.
mesh
()),
phi_
(
phi
),
rho_
(
rho
),
stoicRatio_
(
thermo
.
lookup
(
"stoichiometricAirFuelMassRatio"
)),
s_
(
thermo
.
lookup
(
"stoichiometricOxygenFuelMassRatio"
)),
qFuel_
(
thermo_
.
lookup
(
"qFuel"
)),
composition_
(
thermo
.
composition
())
{}
// * * * * * * * * * * * * * * * * Destructors * * * * * * * * * * * * * * * //
Foam
::
combustionModel
::~
combustionModel
()
{}
// * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * * //
Foam
::
tmp
<
Foam
::
fvScalarMatrix
>
Foam
::
combustionModel
::
combustionModel
::
R
(
volScalarField
&
fu
)
const
{
const
basicMultiComponentMixture
&
composition
=
thermo_
.
composition
();
const
volScalarField
&
ft
=
composition
.
Y
(
"ft"
);
volScalarField
fres
=
composition
.
fres
(
ft
,
stoicRatio_
.
value
());
volScalarField
wFuelNorm
=
this
->
wFuelNorm
()
*
pos
(
fu
-
fres
);
return
wFuelNorm
*
fres
-
fvm
::
Sp
(
wFuelNorm
,
fu
);
}
Foam
::
tmp
<
Foam
::
volScalarField
>
Foam
::
combustionModel
::
combustionModel
::
dQ
(
const
fvScalarMatrix
&
Rfu
)
const
{
const
basicMultiComponentMixture
&
composition
=
thermo_
.
composition
();
const
volScalarField
&
fu
=
composition
.
Y
(
"fu"
);
return
(
-
qFuel_
)
*
(
Rfu
&
fu
);
}
bool
Foam
::
combustionModel
::
read
(
const
dictionary
&
combustionProperties
)
{
combustionModelCoeffs_
=
combustionProperties
.
subDict
(
type
()
+
"Coeffs"
);
return
true
;
}
// ************************************************************************* //
applications/solvers/combustion/fireFoam/combustionModels/combustionModel/combustionModel.H
0 → 100644
View file @
8cf3f429
/*---------------------------------------------------------------------------*\
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
\\/ 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 2 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, write to the Free Software Foundation,
Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
Class
Foam::combustionModel
Description
Base class for all non-premixed combustion models.
SourceFiles
combustionModel.C
\*---------------------------------------------------------------------------*/
#ifndef combustionModel_H
#define combustionModel_H
#include
"IOdictionary.H"
#include
"hsCombustionThermo.H"
#include
"turbulenceModel.H"
#include
"multivariateSurfaceInterpolationScheme.H"
#include
"runTimeSelectionTables.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
namespace
Foam
{
/*---------------------------------------------------------------------------*\
Class combustionModel Declaration
\*---------------------------------------------------------------------------*/
class
combustionModel
{
protected:
// Protected data
//- Dictionary of coefficients for the particular model
dictionary
combustionModelCoeffs_
;
//- Reference to the thermodynamic
const
hsCombustionThermo
&
thermo_
;
//- Reference to the turbulence model
const
compressible
::
turbulenceModel
&
turbulence_
;
//- Reference to the mesh database
const
fvMesh
&
mesh_
;
//- Reference to mass-flux field
const
surfaceScalarField
&
phi_
;
//- Reference to the density field
const
volScalarField
&
rho_
;
//- Stoichiometric air-fuel mass ratio
dimensionedScalar
stoicRatio_
;
//- Stoichiometric oxygen-fuel mass ratio
dimensionedScalar
s_
;
//- Heat of combustion (J/Kg)
dimensionedScalar
qFuel_
;
private:
// Private Member Functions
//- Disallow copy construct
combustionModel
(
const
combustionModel
&
);
//- Disallow default bitwise assignment
void
operator
=
(
const
combustionModel
&
);
const
basicMultiComponentMixture
&
composition_
;
public:
//- Runtime type information
TypeName
(
"combustionModel"
);
// Declare run-time constructor selection table
declareRunTimeSelectionTable
(
autoPtr
,
combustionModel
,
dictionary
,
(
const
dictionary
&
combustionProperties
,
const
hsCombustionThermo
&
thermo
,
const
compressible
::
turbulenceModel
&
turbulence
,
const
surfaceScalarField
&
phi
,
const
volScalarField
&
rho
),
(
combustionProperties
,
thermo
,
turbulence
,
phi
,
rho
)
);
// Selectors
//- Return a reference to the selected combustion model
static
autoPtr
<
combustionModel
>
New
(
const
dictionary
&
combustionProperties
,
const
hsCombustionThermo
&
thermo
,
const
compressible
::
turbulenceModel
&
turbulence
,
const
surfaceScalarField
&
phi
,
const
volScalarField
&
rho
);
// Constructors
//- Construct from components
combustionModel
(
const
dictionary
&
combustionProperties
,
const
hsCombustionThermo
&
thermo
,
const
compressible
::
turbulenceModel
&
turbulence
,
const
surfaceScalarField
&
phi
,
const
volScalarField
&
rho
);
//- Destructor
virtual
~
combustionModel
();
// Member Functions
// Access functions
//- Access composition
const
basicMultiComponentMixture
&
composition
()
const
{
return
composition_
;
}
//- Access combustion dictionary
const
dictionary
combustionModelCoeffs
()
const
{
return
combustionModelCoeffs_
;
}
//- Access heat of combustion
const
dimensionedScalar
qFuel
()
const
{
return
qFuel_
;
}
//- Return normalised consumption rate of (fu - fres)
virtual
tmp
<
volScalarField
>
wFuelNorm
()
const
=
0
;
//- Fuel consumption rate matrix i.e. source-term for the fuel equation
virtual
tmp
<
fvScalarMatrix
>
R
(
volScalarField
&
fu
)
const
;
//- Heat-release rate calculated from the given
// fuel consumption rate matrix
virtual
tmp
<
volScalarField
>
dQ
(
const
fvScalarMatrix
&
Rfu
)
const
;
//- Correct combustion rate
virtual
void
correct
()
=
0
;
//- Update properties from given dictionary
virtual
bool
read
(
const
dictionary
&
combustionProperties
)
=
0
;
};
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
}
// End namespace Foam
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
#endif
// ************************************************************************* //
applications/solvers/combustion/fireFoam/combustionModels/combustionModel/newCombustionModel.C
0 → 100644
View file @
8cf3f429
/*---------------------------------------------------------------------------*\
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
\\/ 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 2 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, write to the Free Software Foundation,
Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
\*---------------------------------------------------------------------------*/
#include
"combustionModel.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
Foam
::
autoPtr
<
Foam
::
combustionModel
>
Foam
::
combustionModel
::
New
(
const
dictionary
&
combustionProperties
,
const
hsCombustionThermo
&
thermo
,
const
compressible
::
turbulenceModel
&
turbulence
,
const
surfaceScalarField
&
phi
,
const
volScalarField
&
rho
)
{
word
combustionModelTypeName
=
combustionProperties
.
lookup
(
"combustionModel"
);
Info
<<
"Selecting combustion model "
<<
combustionModelTypeName
<<
endl
;
dictionaryConstructorTable
::
iterator
cstrIter
=
dictionaryConstructorTablePtr_
->
find
(
combustionModelTypeName
);
if
(
cstrIter
==
dictionaryConstructorTablePtr_
->
end
())
{
FatalErrorIn
(
"combustionModel::New"
)
<<
"Unknown combustionModel type "
<<
combustionModelTypeName
<<
endl
<<
endl
<<
"Valid combustionModels are : "
<<
endl
<<
dictionaryConstructorTablePtr_
->
toc
()
<<
exit
(
FatalError
);
}
return
autoPtr
<
combustionModel
>
(
cstrIter
()(
combustionProperties
,
thermo
,
turbulence
,
phi
,
rho
));
}
// ************************************************************************* //
applications/solvers/combustion/fireFoam/combustionModels/infinitelyFastChemistry/infinitelyFastChemistry.C
0 → 100644
View file @
8cf3f429
/*---------------------------------------------------------------------------*\
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
\\/ 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 2 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, write to the Free Software Foundation,
Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
\*---------------------------------------------------------------------------*/
#include
"infinitelyFastChemistry.H"
#include
"addToRunTimeSelectionTable.H"
// * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
namespace
Foam
{
namespace
combustionModels
{
defineTypeNameAndDebug
(
infinitelyFastChemistry
,
0
);
addToRunTimeSelectionTable
(
combustionModel
,
infinitelyFastChemistry
,
dictionary
);
};
};
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
Foam
::
combustionModels
::
infinitelyFastChemistry
::
infinitelyFastChemistry
(
const
dictionary
&
combustionProperties
,
const
hsCombustionThermo
&
thermo
,
const
compressible
::
turbulenceModel
&
turbulence
,
const
surfaceScalarField
&
phi
,
const
volScalarField
&
rho
)
:
combustionModel
(
combustionProperties
,
thermo
,
turbulence
,
phi
,
rho
),
C_
(
readScalar
(
combustionModelCoeffs_
.
lookup
(
"C"
)))
{}
// * * * * * * * * * * * * * * * * Destructors * * * * * * * * * * * * * * * //
Foam
::
combustionModels
::
infinitelyFastChemistry
::~
infinitelyFastChemistry
()
{}
// * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * * //
void
Foam
::
combustionModels
::
infinitelyFastChemistry
::
correct
()
{}