help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Interpolating over a non-monotonic mesh


From: michaell
Subject: Re: Interpolating over a non-monotonic mesh
Date: Fri, 29 May 2020 23:29:55 -0500 (CDT)

BGreen wrote
> I would like to evaluate a function at each of these points and then
> interpolate its values to a finer mesh. The finer mesh should also be a
> parallelogram of the form depicted above, just with more points.
> Unfortunately, because the meshes x and y are not both monotonic, I cannot
> use interp2 here.
> 
> I'm aware of solutions in which the parallelogram grid is used to create a
> rectangular grid, which can then be interpolated, but if possible I would
> like to interpolate without using another lattice. Is anyone aware of a
> method to do this?
> 
> - Brett Green

Do a basis change so that your grid is orthogonal (probably that's what you
mean by "monotonic"), interpolate via interpn by the method of your choice
there, and evaluate at the equally transformed probe points. Of course, in
this way you will have anisotropy in your interpolated results -- e.g., if
you use nearest-neighbour interpolation, you will get parallelogram facets.
But in any case that can't be avoided: you didn't specify which method you
want to use for interpolation -- if your data points were on a regular
triangular lattice, barycentric interpolation would be natural, which would
give you isotropic results, but your data points aren't.



--
Sent from: https://octave.1599824.n4.nabble.com/Octave-General-f1599825.html



reply via email to

[Prev in Thread] Current Thread [Next in Thread]