Skip to content
Snippets Groups Projects
Commit f3c647b9 authored by Henry Weller's avatar Henry Weller Committed by Andrew Heather
Browse files

swirlFlowRateInletVelocityFvPatchVectorField: Avoid calculating origin and...

swirlFlowRateInletVelocityFvPatchVectorField: Avoid calculating origin and axis for patches with no faces

Resolves problem with reconstructPar
parent 52ad98fa
1 merge request!144Integration openfoam.org
......@@ -65,7 +65,9 @@ swirlFlowRateInletVelocityFvPatchVectorField
dict.lookupOrDefault
(
"origin",
gSum(patch().Cf()*patch().magSf())/gSum(patch().magSf())
patch().size()
? gSum(patch().Cf()*patch().magSf())/gSum(patch().magSf())
: Zero
)
),
axis_
......@@ -73,7 +75,9 @@ swirlFlowRateInletVelocityFvPatchVectorField
dict.lookupOrDefault
(
"axis",
-gSum(patch().Sf())/gSum(patch().magSf())
patch().size()
? -gSum(patch().Sf())/gSum(patch().magSf())
: Zero
)
),
flowRate_(Function1<scalar>::New("flowRate", dict)),
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment