Re: Don't Extrapolate with GRID3 (or cut off excess) [message #71996 is a reply to message #71968] |
Fri, 30 July 2010 08:48  |
penteado
Messages: 866 Registered: February 2018
|
Senior Member Administrator |
|
|
On Jul 30, 12:33 pm, asdf <rmc...@gmail.com> wrote:
> First, a little background. I have an irregular grid of 3D volume data
> that I would like to visualize (currently using iVolume). The volume
> is basically a wedge piece of a cylinder.
> I've the placed data onto a regular, cube grid using GRID3, but the
> result has a large, unrealistic value in an area outside of the
> original irregular grid. From GRID3 documentation, it doesn't seem
> like I can force it to ignore points outside the original grid, i.e.
> don't extrapolate (correct?). I'm wondering if someone knows an
> efficient way to set to NaN values in the regular grid that are
> outside the original, irregular grid. It seems I can do a Delaunay
> triangulation of the irregular grid, and use it somehow to find if a
> point in the regular grid is inside the irregular grid, but I'm lost
> on the details of how to do that.
If your distribution is convex, you can get what you want with
qgrid3(), instead of grid3(), as it allows to set a value for the
points outside the convex hull.
If it is not convex, things are trickier. If the original points all
fall into a series of planes, you could make an IDLanROIGroup with
those, then use the containspoints method to determine which points of
the grid fall inside it.
|
|
|