-
Notifications
You must be signed in to change notification settings - Fork 12
Open
Description
I'm working with a type of 3D FEM model which uses a logically rectilinear, but locally deformed hexahedral grid.
Here's an example in python:
import numpy as np
# coordinates
x = np.linspace(0,10,num=11)
y = np.linspace(0,10,num=11)
z = np.linspace(0,10,num=11)
xx, yy, zz = np.meshgrid(x,y,z)
# some scalar-valued function within the grid
scalar_value = xx*yy*zz
# deform the grid. This is abitrary and just for demonstration purposes.
xx+=np.sin(xx*yy*zz)*0.02
yy+=np.sin(xx*yy*zz)*0.02
zz+=np.cos(xx*yy*zz)*0.02While complex, this can easily be plotted as a pyvista.StructuredGrid, even if its not supported by any geo-specific software I've come across.
One option would be to regrid and interpolate into a regular scheme. However, the large aspect-ratio's of the original grid and its rotation within a UTM system is causing severe losses of resolution when I do so, not to mention file types which are 10-100x larger than the source file.
Exporing the grid as is to geoh5py would be optimal, but it doesn't seem like it supports this kind of format. I'm hoping I'm wrong.
Metadata
Metadata
Assignees
Labels
No labels