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
898742e6
Commit
898742e6
authored
Jul 24, 2008
by
henry
Browse files
Corrected the update of pd from p in closed-volume cases.
parent
1bc9eea3
Changes
4
Hide whitespace changes
Inline
Side-by-side
applications/solvers/heatTransfer/buoyantFoam/pEqn.H
View file @
898742e6
...
...
@@ -55,5 +55,6 @@ if (closedVolume)
{
p
+=
(
initialMass
-
fvc
::
domainIntegrate
(
thermo
->
psi
()
*
p
))
/
fvc
::
domainIntegrate
(
thermo
->
psi
());
pd
==
p
-
(
rho
*
gh
+
pRef
);
rho
=
thermo
->
rho
();
}
applications/solvers/heatTransfer/buoyantSimpleFoam/pEqn.H
View file @
898742e6
volScalarField
rUA
=
1
.
0
/
UEqn
().
A
();
U
=
rUA
*
UEqn
().
H
();
UEqn
.
clear
();
phi
=
fvc
::
interpolate
(
rho
)
*
(
fvc
::
interpolate
(
U
)
&
mesh
.
Sf
());
bool
closedVolume
=
adjustPhi
(
phi
,
U
,
p
);
phi
-=
fvc
::
interpolate
(
rho
*
gh
*
rUA
)
*
fvc
::
snGrad
(
rho
)
*
mesh
.
magSf
();
...
...
@@ -46,6 +47,7 @@ if (closedVolume)
{
p
+=
(
initialMass
-
fvc
::
domainIntegrate
(
thermo
->
psi
()
*
p
))
/
fvc
::
domainIntegrate
(
thermo
->
psi
());
pd
==
p
-
(
rho
*
gh
+
pRef
);
}
rho
=
thermo
->
rho
();
...
...
applications/solvers/heatTransfer/buoyantSimpleRadiationFoam/pEqn.H
View file @
898742e6
...
...
@@ -46,6 +46,7 @@ if (closedVolume)
{
p
+=
(
initialMass
-
fvc
::
domainIntegrate
(
thermo
->
psi
()
*
p
))
/
fvc
::
domainIntegrate
(
thermo
->
psi
());
pd
==
p
-
(
rho
*
gh
+
pRef
);
}
rho
=
thermo
->
rho
();
...
...
applications/solvers/heatTransfer/chtMultiRegionFoam/fluid/pEqn.H
View file @
898742e6
...
...
@@ -51,7 +51,7 @@
)
-
fvc
::
domainIntegrate
(
thermof
[
i
].
psi
()
*
thermof
[
i
].
p
())
)
/
fvc
::
domainIntegrate
(
thermof
[
i
].
psi
());
pdf
[
i
]
==
thermof
[
i
].
p
()
-
(
rhof
[
i
]
*
ghf
[
i
]
+
pRef
);
rhof
[
i
]
=
thermof
[
i
].
rho
();
}
...
...
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