Replies: 2 comments
-
|
In order to compute the z-average, If possible, you can first get the 2D mesh, then use Nek5000's n2to3 tool to do the extrusion. do ez = 1,nelz
do e2d = 1, nelxy
eg = (ez-1) * nelxy + e2d
enddo
enddo
c NUMBER_OF_ELEMENT_X = nelxy
c NUMBER_OF_ELEMENT_Y = 1
c NUMBER_OF_ELEMENT_Z = nelzI'm not sure whether ICEM does extrusion in this way. If so, you can directly use planarAvg. Alternatively, if you only need It is still possible to figure out the vertices index because we do have grid connectivity. |
Beta Was this translation helpful? Give feedback.
-
|
Thank you very much for the explanation and the example. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi everyone,
I am using nekRS v24.0.4 for a case that is periodic in the streamwise (z) direction.
Goal
I would like to compute a z-direction average so that the resulting fields become invariant in z, while preserving the cross-sectional (x,y) profiles.
In other words:
The final field should be independent of z.
Every z-slice should exhibit the same (x,y) profile.
This is not a domain-wide scalar average, but a directional average along z only.
Fields of Interest
In my setup, velocity-related quantities are stored as scalars, for example:
s0 = u ,s1 = v, s2 = w
s6 = u², s7 = v² , s8 = w²
I would like to apply the same z-averaging operator to these fields.
Mesh Characteristics
The mesh was generated in ICEM and has the following properties: Structured mesh
O-grid topology in the cross-section (rod-bundle type geometry)
Uniform extrusion in the z direction
Multi-block structured mesh (not generated with genbox, and not a single tensor-product block)
So although the mesh is structured and extruded in z, it is not a single lexicographically ordered tensor-product block.
Current Question
Previously, I was advised to use planarAvg() for this purpose.
However, from the documentation and examples, it seems that planarAvg() assumes a lexicographically ordered tensor-product mesh.
My question is:
Any guidance would be greatly appreciated.
Thank you. :)
Beta Was this translation helpful? Give feedback.
All reactions