Having a cloud point shaped like some sort of distorted paraboloid, I would like to use Delaunay Triangulation to interpolate the points. I have tried other techniques (f.ex. splines) but did not manage to enforce the desired behavior.
I was wondering if there's a quick way to use the results of scipy.spatial.Delaunay
in a way where I can give the (x,y) coords and get the z-coord of the point on the simplex (triangle).
From the documentation looks like I can pull out the index of the simplex but I am not sure how to take it from there.
The most straightforward way of efficiently computing the Delaunay triangulation is to repeatedly add one vertex at a time, retriangulating the affected parts of the graph. When a vertex v is added, we split in three the triangle that contains v, then we apply the flip algorithm.
Our triangle-based interpolation method computes. a value at a point based only on data values and first partial derivatives. at the three vertices of the triangle containing the point. Given a point. P and the coordinates of the vertices of a triangle containing P along.
Delaunay triangulation: Mainly centred on demonstrating in a practical way that it is always possible the tranformation between 2 triangulations of any points only using interchanges of edges.
The Delaunay triangulation ensures that no vertex lies within the interior of any of the circumcircles of the triangles in the network. If the Delaunay criterion is satisfied everywhere on the TIN, the minimum interior angle of all triangles is maximized.
You can give the Delaunay triangulation to scipy.interpolate.LinearNDInterpolator together with the set of Z-values, and it should do the job for you.
If you really want to do the interpolation yourself, you can build it up from find_simplex and transform.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With