cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Your Friends List is a way to easily have access to the community members that you interact with the most! X

Interpolation

ELSID
4-Participant

Interpolation

There has got to be an easy way of interpolating data in MathCAD 14 M020.

Given the attached image, how would I interpolate the data. I have already calculated the variables theta and Ao/A.

As an example, I calculated theta=7 and Ao/A=4.7

Thank you
6 REPLIES 6

Doesn't make sense. Your worksheet is set up to interpolate for the ratio for θ=20°. But you haven't defined the variables you use for calculating the ratio. So naturally you get errors.

In your post you mention θ=7°. That is not an interpolation, it is way outside the table. And I don't understand θ. The picture seems to show it as the angle between the corner lines. But that cannot exceed 90°, it can't reach the 180° claimed for the abrupt transition.
__________________
� � � � Tom Gutman
ELSID
4-Participant
(To:TomGutman)

Tom,
The angle theta is calculated elsewhere. I am trying to set up a routine that interpolates based off of the chart.Essentially, plot the points, interpolate between the points. I know I posted at 20 degrees, I assumed that as a condition in order to continue with my work. I would like to get an interpolated answer if possible

You can do a bilinear interpolation. That is not provided for directly in Mathcad, but is easy to program. You just need to do a search on the two coordinate vectors to identify the rectangle containing the desired point. If t and s are the fractional distances (between zero and one) from the low X and Y values the weights are just the four combinations of t, s, 1-t, and 1-s.

You can also do a cubic spline interpolation. That is usually more accurate, but also a bit riskier. You need to check the iterpolation to be sure you have not introduced undesired wiggles into the surface. Sometimes you need to transform the coordinates first, to get a better spacing. Mathcad has built in 2D cubic spline for a square data matrix, I have a more general implementation in my cubic spline sheet.

But you still have the issue that 7° is outside the table and calls for extrapolation, not interpolation. And an extrapolation that is large enough to make it very questionable. And I still don't understand θ, based on the diagram and the presented values.
__________________
� � � � Tom Gutman

1. Augment the data table for 0�
2. Spline ... lspline in the program

Done

jmG

jmG
ELSID
4-Participant
(To:ptc-1368288)

jmG
Appears to be an elegant approach to the solution. Now I will try and decipher your use of Matrices to solve my question. Documentation is seriously lacking for MathCAD!
Top Tags