Skip to content
GitLab
Menu
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
045a08c9
Commit
045a08c9
authored
Jun 17, 2008
by
Mark Olesen
Browse files
turbulenceModel : remove missed dimensionedScalar treatment for Cmu, kappa, E
parent
dfc4c690
Changes
2
Hide whitespace changes
Inline
Side-by-side
src/turbulenceModels/RAS/compressible/turbulenceModel/turbulenceModel.C
View file @
045a08c9
...
@@ -123,9 +123,9 @@ tmp<scalarField> turbulenceModel::yPlus(const label patchNo) const
...
@@ -123,9 +123,9 @@ tmp<scalarField> turbulenceModel::yPlus(const label patchNo) const
if
(
typeid
(
curPatch
)
==
typeid
(
wallFvPatch
))
if
(
typeid
(
curPatch
)
==
typeid
(
wallFvPatch
))
{
{
dimensionedS
calar
Cmu
(
turbulenceModelCoeffs_
.
lookup
(
"Cmu"
));
s
calar
Cmu
(
turbulenceModelCoeffs_
.
lookup
(
"Cmu"
));
Yp
=
pow
(
Cmu
.
value
()
,
0
.
25
)
Yp
=
pow
(
Cmu
,
0
.
25
)
*
y_
[
patchNo
]
*
y_
[
patchNo
]
*
sqrt
(
k
()().
boundaryField
()[
patchNo
].
patchInternalField
())
*
sqrt
(
k
()().
boundaryField
()[
patchNo
].
patchInternalField
())
/
(
/
(
...
@@ -164,32 +164,14 @@ bool turbulenceModel::read()
...
@@ -164,32 +164,14 @@ bool turbulenceModel::read()
lookup
(
"turbulence"
)
>>
turbulence_
;
lookup
(
"turbulence"
)
>>
turbulence_
;
turbulenceModelCoeffs_
=
subDict
(
type
()
+
"Coeffs"
);
turbulenceModelCoeffs_
=
subDict
(
type
()
+
"Coeffs"
);
kappa_
=
dimensionedScalar
subDict
(
"wallFunctionCoeffs"
).
lookup
(
"kappa"
)
>>
kappa_
;
(
subDict
(
"wallFunctionCoeffs"
).
lookup
(
"E"
)
>>
E_
;
subDict
(
"wallFunctionCoeffs"
).
lookup
(
"kappa"
)
).
value
();
E_
=
dimensionedScalar
(
subDict
(
"wallFunctionCoeffs"
).
lookup
(
"E"
)
).
value
();
yPlusLam_
=
yPlusLam
(
kappa_
,
E_
);
yPlusLam_
=
yPlusLam
(
kappa_
,
E_
);
if
(
found
(
"k0"
))
readIfPresent
(
"k0"
,
k0_
);
{
readIfPresent
(
"epsilon0"
,
epsilon0_
);
lookup
(
"k0"
)
>>
k0_
;
readIfPresent
(
"epsilonSmall"
,
epsilonSmall_
);
}
if
(
found
(
"epsilon0"
))
{
lookup
(
"epsilon0"
)
>>
epsilon0_
;
}
if
(
found
(
"epsilonSmall"
))
{
lookup
(
"epsilonSmall"
)
>>
epsilonSmall_
;
}
return
true
;
return
true
;
}
}
...
...
src/turbulenceModels/RAS/incompressible/turbulenceModel/turbulenceModel.C
View file @
045a08c9
...
@@ -123,9 +123,9 @@ tmp<scalarField> turbulenceModel::yPlus(const label patchNo) const
...
@@ -123,9 +123,9 @@ tmp<scalarField> turbulenceModel::yPlus(const label patchNo) const
if
(
typeid
(
curPatch
)
==
typeid
(
wallFvPatch
))
if
(
typeid
(
curPatch
)
==
typeid
(
wallFvPatch
))
{
{
dimensionedS
calar
Cmu
(
turbulenceModelCoeffs_
.
lookup
(
"Cmu"
));
s
calar
Cmu
(
turbulenceModelCoeffs_
.
lookup
(
"Cmu"
));
Yp
=
pow
(
Cmu
.
value
()
,
0
.
25
)
*
y_
[
patchNo
]
Yp
=
pow
(
Cmu
,
0
.
25
)
*
y_
[
patchNo
]
*
sqrt
(
k
()().
boundaryField
()[
patchNo
].
patchInternalField
())
*
sqrt
(
k
()().
boundaryField
()[
patchNo
].
patchInternalField
())
/
nu
().
boundaryField
()[
patchNo
];
/
nu
().
boundaryField
()[
patchNo
];
}
}
...
@@ -161,32 +161,14 @@ bool turbulenceModel::read()
...
@@ -161,32 +161,14 @@ bool turbulenceModel::read()
lookup
(
"turbulence"
)
>>
turbulence_
;
lookup
(
"turbulence"
)
>>
turbulence_
;
turbulenceModelCoeffs_
=
subDict
(
type
()
+
"Coeffs"
);
turbulenceModelCoeffs_
=
subDict
(
type
()
+
"Coeffs"
);
kappa_
=
dimensionedScalar
subDict
(
"wallFunctionCoeffs"
).
lookup
(
"kappa"
)
>>
kappa_
;
(
subDict
(
"wallFunctionCoeffs"
).
lookup
(
"E"
)
>>
E_
;
subDict
(
"wallFunctionCoeffs"
).
lookup
(
"kappa"
)
).
value
();
E_
=
dimensionedScalar
(
subDict
(
"wallFunctionCoeffs"
).
lookup
(
"E"
)
).
value
();
yPlusLam_
=
yPlusLam
(
kappa_
,
E_
);
yPlusLam_
=
yPlusLam
(
kappa_
,
E_
);
if
(
found
(
"k0"
))
readIfPresent
(
"k0"
,
k0_
);
{
readIfPresent
(
"epsilon0"
,
epsilon0_
);
lookup
(
"k0"
)
>>
k0_
;
readIfPresent
(
"epsilonSmall"
,
epsilonSmall_
);
}
if
(
found
(
"epsilon0"
))
{
lookup
(
"epsilon0"
)
>>
epsilon0_
;
}
if
(
found
(
"epsilonSmall"
))
{
lookup
(
"epsilonSmall"
)
>>
epsilonSmall_
;
}
return
true
;
return
true
;
}
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a 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