MATLAB: How to retrieve z value from surf plot given x and y

MATLAB and Simulink Student Suiteplotsurf

I got a surface useing:
s= surf(X, Y, Z)
Since the X, Y, and Z are discrete, I want to get the consecutive value of Z. For example, the origin data X and Y are all integers, and I don't the relationship between XY and Z, I want to get the z value where X = 1.87 and Y = 2.9. Is it possible? What should I do?

Best Answer

where Xq and Yq are defined using the values given in your question.
Related Question