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
17afa039
Commit
17afa039
authored
Jan 04, 2011
by
Andrew Heather
Browse files
COMP: fix merge conflict
parents
afb5b6d4
c80a5643
Changes
1000
Hide whitespace changes
Inline
Side-by-side
Too many changes to show.
To preserve performance only
20 of 1000+
files are displayed.
Plain diff
Email patch
Allwmake
View file @
17afa039
...
...
@@ -8,6 +8,12 @@ wmakeCheckPwd "$WM_PROJECT_DIR" || {
exit
1
}
[
-n
"
$FOAM_EXT_LIBBIN
"
]
||
{
echo
"Error: FOAM_EXT_LIBBIN not set"
echo
" Check the OpenFOAM entries in your dot-files and source them."
exit
1
}
# wmake is required for subsequent targets
(
cd
wmake/src
&&
make
)
...
...
applications/Allwmake
View file @
17afa039
...
...
@@ -8,6 +8,12 @@ wmakeCheckPwd "$WM_PROJECT_DIR/applications" || {
exit
1
}
[
-n
"
$FOAM_EXT_LIBBIN
"
]
||
{
echo
"Error: FOAM_EXT_LIBBIN not set"
echo
" Check the OpenFOAM entries in your dot-files and source them."
exit
1
}
set
-x
wmake all utilities
...
...
applications/solvers/DNS/dnsFoam/dnsFoam.C
View file @
17afa039
...
...
@@ -85,7 +85,7 @@ int main(int argc, char *argv[])
for
(
int
corr
=
1
;
corr
<=
1
;
corr
++
)
{
volScalarField
rAU
=
1
.
0
/
UEqn
.
A
();
volScalarField
rAU
(
1
.
0
/
UEqn
.
A
()
)
;
U
=
rAU
*
UEqn
.
H
();
phi
=
(
fvc
::
interpolate
(
U
)
&
mesh
.
Sf
())
...
...
applications/solvers/DNS/dnsFoam/readTurbulenceProperties.H
View file @
17afa039
...
...
@@ -12,8 +12,10 @@
)
);
volVectorField
force
=
U
/
dimensionedScalar
(
"dt"
,
dimTime
,
runTime
.
deltaTValue
());
volVectorField
force
(
U
/
dimensionedScalar
(
"dt"
,
dimTime
,
runTime
.
deltaTValue
())
);
Kmesh
K
(
mesh
);
UOprocess
forceGen
(
K
,
runTime
.
deltaTValue
(),
turbulenceProperties
);
applications/solvers/basic/laplacianFoam/write.H
View file @
17afa039
if
(
runTime
.
outputTime
())
{
volVectorField
gradT
=
fvc
::
grad
(
T
);
volVectorField
gradT
(
fvc
::
grad
(
T
)
)
;
volScalarField
gradTx
(
...
...
applications/solvers/combustion/PDRFoam/PDRModels/XiEqModels/basicXiSubXiEq/basicXiSubXiEq.C
View file @
17afa039
...
...
@@ -34,8 +34,8 @@ namespace XiEqModels
{
defineTypeNameAndDebug
(
basicSubGrid
,
0
);
addToRunTimeSelectionTable
(
XiEqModel
,
basicSubGrid
,
dictionary
);
}
;
}
;
}
}
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
...
...
@@ -123,20 +123,24 @@ Foam::tmp<Foam::volScalarField> Foam::XiEqModels::basicSubGrid::XiEq() const
const
objectRegistry
&
db
=
Su_
.
db
();
const
volVectorField
&
U
=
db
.
lookupObject
<
volVectorField
>
(
"U"
);
volScalarField
magU
=
mag
(
U
);
volVectorField
Uhat
=
U
/
(
mag
(
U
)
+
dimensionedScalar
(
"Usmall"
,
U
.
dimensions
(),
1e-4
));
volScalarField
magU
(
mag
(
U
));
volVectorField
Uhat
(
U
/
(
mag
(
U
)
+
dimensionedScalar
(
"Usmall"
,
U
.
dimensions
(),
1e-4
))
);
volScalarField
n
=
max
(
N_
-
(
Uhat
&
ns_
&
Uhat
),
scalar
(
1e-4
));
volScalarField
n
(
max
(
N_
-
(
Uhat
&
ns_
&
Uhat
),
scalar
(
1e-4
))
)
;
volScalarField
b
=
(
Uhat
&
B_
&
Uhat
)
/
n
;
volScalarField
b
(
(
Uhat
&
B_
&
Uhat
)
/
n
)
;
volScalarField
up
=
sqrt
((
2
.
0
/
3
.
0
)
*
turbulence_
.
k
());
volScalarField
up
(
sqrt
((
2
.
0
/
3
.
0
)
*
turbulence_
.
k
())
)
;
volScalarField
XiSubEq
=
volScalarField
XiSubEq
(
scalar
(
1
)
+
max
(
2
.
2
*
sqrt
(
b
),
min
(
0
.
34
*
magU
/
up
,
scalar
(
1
.
6
)))
*
min
(
0
.
25
*
n
,
scalar
(
1
));
*
min
(
0
.
25
*
n
,
scalar
(
1
))
);
return
XiSubEq
*
XiEqModel_
->
XiEq
();
}
...
...
applications/solvers/combustion/PDRFoam/PDRModels/XiGModels/basicXiSubG/basicXiSubG.C
View file @
17afa039
...
...
@@ -34,8 +34,8 @@ namespace XiGModels
{
defineTypeNameAndDebug
(
basicSubGrid
,
0
);
addToRunTimeSelectionTable
(
XiGModel
,
basicSubGrid
,
dictionary
);
}
;
}
;
}
}
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
...
...
applications/solvers/combustion/PDRFoam/PDRModels/dragModels/PDRDragModel/PDRDragModel.C
View file @
17afa039
...
...
@@ -31,7 +31,7 @@ namespace Foam
{
defineTypeNameAndDebug
(
PDRDragModel
,
0
);
defineRunTimeSelectionTable
(
PDRDragModel
,
dictionary
);
}
;
}
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
...
...
applications/solvers/combustion/PDRFoam/PDRModels/dragModels/basic/basic.C
View file @
17afa039
...
...
@@ -34,8 +34,8 @@ namespace PDRDragModels
{
defineTypeNameAndDebug
(
basic
,
0
);
addToRunTimeSelectionTable
(
PDRDragModel
,
basic
,
dictionary
);
}
;
}
;
}
}
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
...
...
applications/solvers/combustion/PDRFoam/PDRModels/turbulence/PDRkEpsilon/PDRkEpsilon.C
View file @
17afa039
...
...
@@ -78,7 +78,7 @@ void PDRkEpsilon::correct()
RASModel
::
correct
();
volScalarField
divU
=
fvc
::
div
(
phi_
/
fvc
::
interpolate
(
rho_
));
volScalarField
divU
(
fvc
::
div
(
phi_
/
fvc
::
interpolate
(
rho_
))
)
;
if
(
mesh_
.
moving
())
{
...
...
@@ -99,7 +99,7 @@ void PDRkEpsilon::correct()
const
PDRDragModel
&
drag
=
U_
.
db
().
lookupObject
<
PDRDragModel
>
(
"PDRDragModel"
);
volScalarField
GR
=
drag
.
Gk
();
volScalarField
GR
(
drag
.
Gk
()
)
;
// Dissipation equation
tmp
<
fvScalarMatrix
>
epsEqn
...
...
applications/solvers/combustion/PDRFoam/StCourantNo.H
View file @
17afa039
...
...
@@ -34,9 +34,11 @@ Description
if
(
mesh
.
nInternalFaces
())
{
scalarField
sumPhi
=
scalarField
sumPhi
(
fvc
::
surfaceSum
(
mag
(
phiSt
))().
internalField
()
/
rho
.
internalField
();
/
rho
.
internalField
()
);
StCoNum
=
0
.
5
*
gMax
(
sumPhi
/
mesh
.
V
().
field
())
*
runTime
.
deltaTValue
();
...
...
applications/solvers/combustion/PDRFoam/UEqn.H
View file @
17afa039
...
...
@@ -7,7 +7,7 @@
betav
*
rho
*
g
);
volSymmTensorField
invA
=
inv
(
I
*
UEqn
.
A
()
+
drag
->
Dcu
());
volSymmTensorField
invA
(
inv
(
I
*
UEqn
.
A
()
+
drag
->
Dcu
())
)
;
if
(
momentumPredictor
)
{
...
...
applications/solvers/combustion/PDRFoam/XiEqns
deleted
100644 → 0
View file @
afb5b6d4
// Calculate Xi according to the selected flame wrinkling model
// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
// Calculate coefficients for Gulder's flame speed correlation
// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
volScalarField up = uPrimeCoef*sqrt((2.0/3.0)*k);
volScalarField epsilonPlus = pow(uPrimeCoef, 3)*epsilon;
volScalarField tauEta = sqrt(mag(thermo->muu()/(rhou*epsilonPlus)));
volScalarField Reta = up/
(
sqrt(epsilonPlus*tauEta)
+ dimensionedScalar("1e-8", up.dimensions(), 1e-8)
);
else if (XiModel == "algebraic")
{
// Simple algebraic model for Xi based on Gulders correlation
// with a linear correction function to give a plausible profile for Xi
// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
volScalarField GEta = GEtaCoef/tauEta;
volScalarField XiEqEta = 1.0 + XiCoef*sqrt(up/(Su + SuMin))*Reta;
volScalarField R =
GEta*XiEqEta/(XiEqEta - 0.999) + GIn*XiIn/(XiIn - 0.999);
volScalarField XiEqStar = R/(R - GEta - GIn);
//- Calculate the unweighted b
//volScalarField Rrho = thermo->rhou()/thermo->rhob();
//volScalarField bbar = b/(b + (Rrho*(1.0 - b)));
Xi == 1.0 + (1.0 + (2*XiShapeCoef)*(0.5 - b))*(XiEqStar - 1.0);
}
else if (XiModel == "transport")
{
// Calculate Xi transport coefficients based on Gulders correlation
// and DNS data for the rate of generation
// with a linear correction function to give a plausible profile for Xi
// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
volScalarField GEta = GEtaCoef/tauEta;
volScalarField XiEqEta = 1.0 + XiCoef*sqrt(up/(Su + SuMin))*Reta;
volScalarField R =
GEta*XiEqEta/(XiEqEta - 0.999) + GIn*XiIn/(XiIn - 0.999);
volScalarField XiEqStar = R/(R - GEta - GIn);
volScalarField XiEq =
1.0 + (1.0 + (2*XiShapeCoef)*(0.5 - b))*(XiEqStar - 1.0);
volScalarField G = R*(XiEq - 1.0)/XiEq;
// Calculate Xi flux
// ~~~~~~~~~~~~~~~~~
surfaceScalarField phiXi =
phiSt
+ (
- fvc::interpolate(fvc::laplacian(Dbf, b)/mgb)*nf
+ fvc::interpolate(rho)*fvc::interpolate(Su*(1.0/Xi - Xi))*nf
);
// Solve for the flame wrinkling
// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
solve
(
betav*fvm::ddt(rho, Xi)
+ mvConvection->fvmDiv(phi, Xi)
+ fvm::div(phiXi, Xi, "div(phiXi,Xi)")
- fvm::Sp(fvc::div(phiXi), Xi)
==
betav*rho*R
- fvm::Sp(betav*rho*(R - G), Xi)
);
// Correct boundedness of Xi
// ~~~~~~~~~~~~~~~~~~~~~~~~~
Xi.max(1.0);
Xi = min(Xi, 2.0*XiEq);
Info<< "max(Xi) = " << max(Xi).value() << endl;
Info<< "max(XiEq) = " << max(XiEq).value() << endl;
}
else
{
FatalError
<< args.executable() << " : Unknown Xi model " << XiModel
<< abort(FatalError);
}
applications/solvers/combustion/PDRFoam/XiModels/XiEqModels/Gulder/Gulder.C
View file @
17afa039
...
...
@@ -34,8 +34,8 @@ namespace XiEqModels
{
defineTypeNameAndDebug
(
Gulder
,
0
);
addToRunTimeSelectionTable
(
XiEqModel
,
Gulder
,
dictionary
);
}
;
}
;
}
}
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
...
...
@@ -64,15 +64,18 @@ Foam::XiEqModels::Gulder::~Gulder()
Foam
::
tmp
<
Foam
::
volScalarField
>
Foam
::
XiEqModels
::
Gulder
::
XiEq
()
const
{
volScalarField
up
=
sqrt
((
2
.
0
/
3
.
0
)
*
turbulence_
.
k
());
volScalarField
up
(
sqrt
((
2
.
0
/
3
.
0
)
*
turbulence_
.
k
())
)
;
const
volScalarField
&
epsilon
=
turbulence_
.
epsilon
();
volScalarField
tauEta
=
sqrt
(
mag
(
thermo_
.
muu
()
/
(
thermo_
.
rhou
()
*
epsilon
)));
volScalarField
tauEta
(
sqrt
(
mag
(
thermo_
.
muu
()
/
(
thermo_
.
rhou
()
*
epsilon
)))
)
;
volScalarField
Reta
=
up
/
volScalarField
Reta
(
sqrt
(
epsilon
*
tauEta
)
+
dimensionedScalar
(
"1e-8"
,
up
.
dimensions
(),
1e-8
)
up
/
(
sqrt
(
epsilon
*
tauEta
)
+
dimensionedScalar
(
"1e-8"
,
up
.
dimensions
(),
1e-8
)
)
);
return
1
.
0
+
XiEqCoef
*
sqrt
(
up
/
(
Su_
+
SuMin
))
*
Reta
;
...
...
applications/solvers/combustion/PDRFoam/XiModels/XiEqModels/SCOPEBlendXiEq/SCOPEBlendXiEq.C
View file @
17afa039
...
...
@@ -34,8 +34,8 @@ namespace XiEqModels
{
defineTypeNameAndDebug
(
SCOPEBlend
,
0
);
addToRunTimeSelectionTable
(
XiEqModel
,
SCOPEBlend
,
dictionary
);
}
;
}
;
}
}
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
...
...
applications/solvers/combustion/PDRFoam/XiModels/XiEqModels/SCOPEXiEq/SCOPEXiEq.C
View file @
17afa039
...
...
@@ -34,8 +34,8 @@ namespace XiEqModels
{
defineTypeNameAndDebug
(
SCOPEXiEq
,
0
);
addToRunTimeSelectionTable
(
XiEqModel
,
SCOPEXiEq
,
dictionary
);
}
;
}
;
}
}
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
...
...
@@ -83,13 +83,13 @@ Foam::tmp<Foam::volScalarField> Foam::XiEqModels::SCOPEXiEq::XiEq() const
const
volScalarField
&
k
=
turbulence_
.
k
();
const
volScalarField
&
epsilon
=
turbulence_
.
epsilon
();
volScalarField
up
=
sqrt
((
2
.
0
/
3
.
0
)
*
k
);
volScalarField
l
=
(
lCoef
*
sqrt
(
3
.
0
/
2
.
0
))
*
up
*
k
/
epsilon
;
volScalarField
Rl
=
up
*
l
*
thermo_
.
rhou
()
/
thermo_
.
muu
();
volScalarField
up
(
sqrt
((
2
.
0
/
3
.
0
)
*
k
)
)
;
volScalarField
l
(
(
lCoef
*
sqrt
(
3
.
0
/
2
.
0
))
*
up
*
k
/
epsilon
)
;
volScalarField
Rl
(
up
*
l
*
thermo_
.
rhou
()
/
thermo_
.
muu
()
)
;
volScalarField
upBySu
=
up
/
(
Su_
+
SuMin
);
volScalarField
K
=
0
.
157
*
upBySu
/
sqrt
(
Rl
);
volScalarField
Ma
=
MaModel
.
Ma
();
volScalarField
upBySu
(
up
/
(
Su_
+
SuMin
)
)
;
volScalarField
K
(
0
.
157
*
upBySu
/
sqrt
(
Rl
)
)
;
volScalarField
Ma
(
MaModel
.
Ma
()
)
;
tmp
<
volScalarField
>
tXiEq
(
...
...
applications/solvers/combustion/PDRFoam/XiModels/XiEqModels/XiEqModel/XiEqModel.C
View file @
17afa039
...
...
@@ -31,7 +31,7 @@ namespace Foam
{
defineTypeNameAndDebug
(
XiEqModel
,
0
);
defineRunTimeSelectionTable
(
XiEqModel
,
dictionary
);
}
;
}
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
...
...
applications/solvers/combustion/PDRFoam/XiModels/XiEqModels/instabilityXiEq/instabilityXiEq.C
View file @
17afa039
...
...
@@ -34,8 +34,8 @@ namespace XiEqModels
{
defineTypeNameAndDebug
(
instability
,
0
);
addToRunTimeSelectionTable
(
XiEqModel
,
instability
,
dictionary
);
}
;
}
;
}
}
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
...
...
@@ -64,7 +64,7 @@ Foam::XiEqModels::instability::~instability()
Foam
::
tmp
<
Foam
::
volScalarField
>
Foam
::
XiEqModels
::
instability
::
XiEq
()
const
{
volScalarField
turbXiEq
=
XiEqModel_
->
XiEq
();
volScalarField
turbXiEq
(
XiEqModel_
->
XiEq
()
)
;
return
XiEqIn
/
turbXiEq
+
turbXiEq
;
}
...
...
applications/solvers/combustion/PDRFoam/XiModels/XiGModels/KTS/KTS.C
View file @
17afa039
...
...
@@ -34,8 +34,8 @@ namespace XiGModels
{
defineTypeNameAndDebug
(
KTS
,
0
);
addToRunTimeSelectionTable
(
XiGModel
,
KTS
,
dictionary
);
}
;
}
;
}
}
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
...
...
@@ -63,10 +63,11 @@ Foam::XiGModels::KTS::~KTS()
Foam
::
tmp
<
Foam
::
volScalarField
>
Foam
::
XiGModels
::
KTS
::
G
()
const
{
volScalarField
up
=
sqrt
((
2
.
0
/
3
.
0
)
*
turbulence_
.
k
());
//
volScalarField up
(
sqrt((2.0/3.0)*turbulence_.k())
)
;
const
volScalarField
&
epsilon
=
turbulence_
.
epsilon
();
volScalarField
tauEta
=
sqrt
(
mag
(
thermo_
.
muu
()
/
(
thermo_
.
rhou
()
*
epsilon
)));
tmp
<
volScalarField
>
tauEta
=
sqrt
(
mag
(
thermo_
.
muu
()
/
(
thermo_
.
rhou
()
*
epsilon
)));
return
GEtaCoef
/
tauEta
;
}
...
...
applications/solvers/combustion/PDRFoam/XiModels/XiGModels/XiGModel/XiGModel.C
View file @
17afa039
...
...
@@ -31,7 +31,7 @@ namespace Foam
{
defineTypeNameAndDebug
(
XiGModel
,
0
);
defineRunTimeSelectionTable
(
XiGModel
,
dictionary
);
}
;
}
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
...
...
Prev
1
2
3
4
5
…
50
Next
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment