Linear Interpolation to Find Z Value in Quadrilateral

  • Context: Undergrad 
  • Thread starter Thread starter Cummings
  • Start date Start date
  • Tags Tags
    Interpolation Linear
Join the discussion
Ask a follow-up here, or get your own question answered by working scientists, mathematicians and engineers — people, not an autocomplete.
Real named experts · corrections over time · the nuance an AI answer skips
1 reply · 4K views
Cummings
Messages
53
Reaction score
0
I have a problem where I need to work out a value of a specific point that lies in the quadrilateral that is formed by four separate points.

For each point that makes up the quadrilateral, I know the X and Y coordinates and their value, Z. For the point I am trying to find the value for, I only know the X and Y coordinates.

I want to use linear interpolation to determine the value at that point, yet am not sure of the best mathematical technique to do it. For simplicity, I can assume that the quadrilateral is, for lack of a better term, 'squareish' - no inner angle is more than 180 degrees. The four points are also given in clockwise order.

I have thought about using some simple line equations to do this, where I take the point and find the equation of the line that passes through one of the quadrilateral points. I then find the equations of the lines that form the quadrilateral and find the point where the original line intersects with one of the quadrilateral lines. I can interpolate the value at this point and then use that interpolated value to interpolate the value at the point I need.

Would this technique work or is there a better one. The most important aspect is that if the point lies on a known value, it takes that value. For all other points, it needs to be interpolated.

I appreciate your time.
 
Last edited by a moderator:
Mathematics news on Phys.org
As I understand it, there is a surface in three dimensional spaces which contains the quadrilateral. The crucial point are not the angles, but the shape of the surface. In case it is flat you can simply calculate the plane equation and evaluate it at the given inner point. In any other case the surface could be quite arbitrary and additional information is needed about how the ##z-##values are distributed.