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
5848b0af
Commit
5848b0af
authored
Jun 08, 2018
by
sergio
Browse files
BUG: Fixing ray dAve and omega for 1D and 2D cases
parent
698a6d59
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/thermophysicalModels/radiation/radiationModels/fvDOM/radiativeIntensityRay/radiativeIntensityRay.C
View file @
5848b0af
...
@@ -3,7 +3,7 @@
...
@@ -3,7 +3,7 @@
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / O peration |
\\ / A nd | Copyright (C) 2011-2017 OpenFOAM Foundation
\\ / A nd | Copyright (C) 2011-2017 OpenFOAM Foundation
\\/ M anipulation |
\\/ M anipulation |
Copyright (C) 2018 OpenCFD Ltd
-------------------------------------------------------------------------------
-------------------------------------------------------------------------------
License
License
This file is part of OpenFOAM.
This file is part of OpenFOAM.
...
@@ -137,6 +137,17 @@ Foam::radiation::radiativeIntensityRay::radiativeIntensityRay
...
@@ -137,6 +137,17 @@ Foam::radiation::radiativeIntensityRay::radiativeIntensityRay
if
(
mesh_
.
nSolutionD
()
==
2
)
if
(
mesh_
.
nSolutionD
()
==
2
)
{
{
// Omega for 2D
omega_
=
deltaPhi
;
// dAve for 2D
dAve_
=
vector
(
2
*
sinPhi
*
Foam
::
sin
(
0
.
5
*
deltaPhi
),
2
*
cosPhi
*
Foam
::
sin
(
0
.
5
*
deltaPhi
),
0
);
vector
meshDir
(
Zero
);
vector
meshDir
(
Zero
);
if
(
dom_
.
meshOrientation
()
!=
vector
::
zero
)
if
(
dom_
.
meshOrientation
()
!=
vector
::
zero
)
{
{
...
@@ -158,6 +169,7 @@ Foam::radiation::radiativeIntensityRay::radiativeIntensityRay
...
@@ -158,6 +169,7 @@ Foam::radiation::radiativeIntensityRay::radiativeIntensityRay
dAve_
=
coordRot
&
dAve_
;
dAve_
=
coordRot
&
dAve_
;
d_
=
coordRot
&
d_
;
d_
=
coordRot
&
d_
;
}
}
else
if
(
mesh_
.
nSolutionD
()
==
1
)
else
if
(
mesh_
.
nSolutionD
()
==
1
)
{
{
...
@@ -180,6 +192,9 @@ Foam::radiation::radiativeIntensityRay::radiativeIntensityRay
...
@@ -180,6 +192,9 @@ Foam::radiation::radiativeIntensityRay::radiativeIntensityRay
dAve_
=
(
dAve_
&
normal
)
*
meshDir
;
dAve_
=
(
dAve_
&
normal
)
*
meshDir
;
d_
=
(
d_
&
normal
)
*
meshDir
;
d_
=
(
d_
&
normal
)
*
meshDir
;
// Omega normalization for 1D
omega_
/=
2
;
}
}
autoPtr
<
volScalarField
>
IDefaultPtr
;
autoPtr
<
volScalarField
>
IDefaultPtr
;
...
...
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