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

Community Tip - Learn all about PTC Community Badges. Engage with PTC and see how many you can earn! X

Linear Interpolation from Table

MH_10592278
2-Explorer

Linear Interpolation from Table

MH_10592278_0-1688474632441.png

As shown above when I tried to linear interpolate the D values corresponding to h/d values of column 1. It is showing following error, Kindly help me. 

 

 

ACCEPTED SOLUTION

Accepted Solutions
Werner_E
25-Diamond I
(To:MH_10592278)

Isn't the error message self-explanatory?

The elements of the first argument vector must be in ascending order. your vector is in DEscending  order, so you have to resort it (and of  course also vector D (which contains constant values anyway.
What do you expect your function to return? Anything else than 0.8 for any input value?

Furthermore you should not name the function and the vector the same (D).

 

BTW, it would be polite if, after you asked a question here in he forum, that you come back, comment on the answers and close the thread or explain whats still missing -> what to create a table with variable value from a ... - PTC Community

View solution in original post

2 REPLIES 2
Werner_E
25-Diamond I
(To:MH_10592278)

Isn't the error message self-explanatory?

The elements of the first argument vector must be in ascending order. your vector is in DEscending  order, so you have to resort it (and of  course also vector D (which contains constant values anyway.
What do you expect your function to return? Anything else than 0.8 for any input value?

Furthermore you should not name the function and the vector the same (D).

 

BTW, it would be polite if, after you asked a question here in he forum, that you come back, comment on the answers and close the thread or explain whats still missing -> what to create a table with variable value from a ... - PTC Community

Thank you for your help, It worked.

Announcements

Top Tags