|
[Sponsors] |
May 3, 2023, 06:41 |
Different face normals for internal faces
|
#1 |
New Member
Join Date: Jul 2021
Posts: 10
Rep Power: 5 |
Hello,
I am currently facing the following problem. I have a body with many channels, where air is flowing around/through it. I want to determine the massflow inside the body, hence I made a named selection of the opening of the channels (internal surfaces). Due to the missing symmetry I cannot create a plane in Post. However, I noticed that the massflow was too little and saw that some faces of the named selection had a different face normal vector (1,-1), which resulted into the wrong massflow. I tried the following ways to calculate the massflow: =areaInt(Density*Velocity u) =areaInt(Density*Velocity u * step(Normal X))+=areaInt(Density*Velocity u * step(-Normal X)) and a variation where I calculate the Vdot (u*X+v*Y+w*Z) and then again the areaInt. These calculations are about 3% off from the ideal massflow (which I got from a toycase, where I can just create a plane and calculate the massflow). Can you help me find my error or do you know a way to direct all face normals in a named selection in one direction? Thanks in advance! Best, Leo |
|
May 3, 2023, 08:25 |
|
#2 |
Super Moderator
Glenn Horrocks
Join Date: Mar 2009
Location: Sydney, Australia
Posts: 17,870
Rep Power: 144 |
The most accurate way of calculating mass flow is using the massFlow() CEL expression in the solver. That way it uses the full integration points of the solution. If you calculate mass flow in the post processor you only use what the results file contains, which is variables at nodes only. This may cause a loss of accuracy in the post processor results.
If you cut a duct and reconnect it with an interface (use a 1:1 interface if you can) then you can use the interface as a location identifier in the solver (or in post processing) to use the massFlow() expression.
__________________
Note: I do not answer CFD questions by PM. CFD questions should be posted on the forum. |
|
May 4, 2023, 05:43 |
|
#3 |
New Member
Join Date: Jul 2021
Posts: 10
Rep Power: 5 |
Thank you for the tip! I found out that if I calculate the massflow at the interface it results the right massflow value. However, if I use the named selection, which are the same faces, an error of 3% is received. Nevertheless, I can continue working with your approach.
Thank you! |
|
Tags |
areaintegrate, face normals, massflow |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Foam::error::PrintStack | almir | OpenFOAM Running, Solving & CFD | 92 | May 21, 2024 08:56 |
[snappyHexMesh] Error snappyhexmesh - Multiple outside loops | avinashjagdale | OpenFOAM Meshing & Mesh Conversion | 53 | March 8, 2019 10:42 |
[Gmsh] Vertex numbering is dense | KateEisenhower | OpenFOAM Meshing & Mesh Conversion | 7 | August 3, 2015 11:49 |
[blockMesh] error message with modeling a cube with a hold at the center | hsingtzu | OpenFOAM Meshing & Mesh Conversion | 2 | March 14, 2012 10:56 |
[blockMesh] BlockMeshmergePatchPairs | hjasak | OpenFOAM Meshing & Mesh Conversion | 11 | August 15, 2008 08:36 |