EllipSys ParaView Plugin issueshttps://gitlab.windenergy.dtu.dk/EllipSys/ellipsys_paraview_plugin/-/issues2023-02-23T19:50:12Zhttps://gitlab.windenergy.dtu.dk/EllipSys/ellipsys_paraview_plugin/-/issues/4vertex-centered coordinates vs cell-centered variables2023-02-23T19:50:12ZMads Christian Baungaardvertex-centered coordinates vs cell-centered variablesThe variables (u, v, w, den, vis, p) are cell-centered (CC) in EllipSys. On the other hand the coordinates are vertex-centered (x, y, z).
![image](/uploads/2760e0bd9577d2ac05b47108565ec874/image.png)
It appears that this is currently ...The variables (u, v, w, den, vis, p) are cell-centered (CC) in EllipSys. On the other hand the coordinates are vertex-centered (x, y, z).
![image](/uploads/2760e0bd9577d2ac05b47108565ec874/image.png)
It appears that this is currently not taken into account in the ellipsys_paraview_plugin, hence the CC values are wrongly displayed at the vertices. As a simple example, consider the 2D lid-driven cavity (https://gitlab.windenergy.dtu.dk/EllipSys/ellipsys2d_testcases/-/tree/lid_cavity/cavity), where one would expect $V=0$ at the walls ($x=0$ and $x=1$), but ellipsys_paraview_plugin shows $V\neq 0$ there!
![image](/uploads/6b2b63e982238156d9bef54ceea1e78f/image.png)
In other words, the CC variables need to be "moved" half a cell size to the right and half a cell size upwards.
In the EllipSys Fortran postprocessor (which outputs Plot3D files normally used for Fieldview) this is handled by doing an interpolation of the CC variables onto the vertices (https://gitlab.windenergy.dtu.dk/EllipSys/ellipsys2d/-/blob/master/SourcesMPI/PostProcessor/PostProcessor.f):
![image](/uploads/9443e1af5adbcbf455bc2cd9024326ee/image.png)
![image](/uploads/fa1047e16e5a570e8854c9914f21176c/image.png)
As I see it we have two options:
1. Either we change to CC coordinates instead (do an interpolation of the coordinates).
2. Interpolate the CC variables to the vertices like in the EllipSys postprocessor. However, this would mean that it doesn't make sense to have the "load ghost cells" option anymore.