What is the matrix function to find the extrapolated value from a given 2-dimension table

What is the matrix function to find the extrapolated value from a given 2-dimension table - 消息

#1 已发布: 2021/4/21 16:46:53
Tuan Nguyen

Tuan Nguyen

0个赞,共16个帖子。

组: User

Is there such matrix function to help me get the coefficient Cf based on ratio s/h and B/s from given table in matrix form?

#2 已发布: 2021/4/21 17:38:34
overlord

overlord

600个赞,共1,381个帖子。

组: Moderator

Wrote

Is there such matrix function to help me get the coefficient Cf based on ratio s/h and B/s from given table in matrix form?


You can either use linterp() or InterpBilinear().
They can also find an interpolated value between title numbers.
Please look at the Reference Book for further information.

Regards
#3 已发布: 2021/4/21 18:05:55
Tuan Nguyen

Tuan Nguyen

0个赞,共16个帖子。

组: User

Wrote

Wrote

Is there such matrix function to help me get the coefficient Cf based on ratio s/h and B/s from given table in matrix form?


You can either use linterp() or InterpBilinear().
They can also find an interpolated value between title numbers.
Please look at the Reference Book for further information.

Regards



Thank you. Found it here. https://en.smath.com/forum/yaf_postst17672_Interpolate-Matrix.aspx

Learn new things every day.
#4 已发布: 2021/4/21 18:24:29
Jean Giraud

Jean Giraud

983个赞,共6,866个帖子。

组: User

Wrote

Is there such matrix function to help me get
the coefficient Cf based on ratio s/h and B/s
from given table in matrix form?


Spline(M,x,y) is universal.
Construct 1/1 from the given example, forget decoration <, >
Just for interpolation, you don't need the rotation system.
Cheers ... Jean

Spline Matrix Tutorial RECTANGULAR Surface Plot.sm (22.98 KiB)已下载 1262 次。

1位用户喜欢此帖子
Tuan Nguyen 2021/4/21 19:04:00
#5 已发布: 2021/4/21 18:33:04
Jean Giraud

Jean Giraud

983个赞,共6,866个帖子。

组: User

... nice example done for Smath Community visitor.
Construct rough data table, spline at will, plot is most delightful.
How do you manage ... Jean

SplineRectangularMatrix Isentropic Surface.sm (457.73 KiB)已下载 1293 次。
1位用户喜欢此帖子
Tuan Nguyen 2021/4/21 19:04:00
#6 已发布: 2021/4/21 19:13:21
Tuan Nguyen

Tuan Nguyen

0个赞,共16个帖子。

组: User

Wrote

Wrote

Is there such matrix function to help me get
the coefficient Cf based on ratio s/h and B/s
from given table in matrix form?


Spline(M,x,y) is universal.
Construct 1/1 from the given example, forget decoration <, >
Just for interpolation, you don't need the rotation system.
Cheers ... Jean

Spline Matrix Tutorial RECTANGULAR Surface Plot.sm (22.98 KiB)已下载 1262 次。



Beautiful. I love the way you present all math problems in such a lovely form.

Even though it is a very rare case, when x and/or y values exceed the range in my posted table the function will return the value more or less than it should be because I think the table cap the values. I wanted to make changes to the Spline function to reflect this but my limited knowledge in programing and Smath prevents me from doing that. Any suggestions?
#7 已发布: 2021/4/22 13:50:04
Jean Giraud

Jean Giraud

983个赞,共6,866个帖子。

组: User

Wrote

See you soon tomorrow ... Jean.


... here is, play with rotation.

Spline Matrix Tutorial RECTANGULAR Surface Plot Example.sm (23.4 KiB)已下载 1313 次。
1位用户喜欢此帖子
Tuan Nguyen 2021/4/22 14:42:00
#8 已发布: 2021/4/22 14:47:20
Tuan Nguyen

Tuan Nguyen

0个赞,共16个帖子。

组: User

Wrote

Wrote

See you soon tomorrow ... Jean.


... here is, play with rotation.

Spline Matrix Tutorial RECTANGULAR Surface Plot Example.sm (23.4 KiB)已下载 1313 次。



Awesome. When x=70, y=0.5, I need it to be 1.75 per code because x>45 but the function gives me 1.83. How would I modify the code for Spline to achieve this.

#9 已发布: 2021/4/22 15:37:25
Martin Kraska

Martin Kraska

1,362个赞,共2,276个帖子。

组: Moderator

Obviously the function uses linear extrapolation beyond the limits of the data array.

Without touching the function you can enforce constant extrapolation by repeating the first or last rows or columns of data.

surface.png
surface.sm (18.8 KiB)已下载 1196 次。
Technische Mechanik mit SMath Studio: https://link.springer.com/book/10.1007/978-3-658-50592-9
1位用户喜欢此帖子
Tuan Nguyen 2021/4/22 18:37:00
#10 已发布: 2021/4/22 16:46:35
Jean Giraud

Jean Giraud

983个赞,共6,866个帖子。

组: User

Wrote

Awesome. When x=70, y=0.5, I need it to be 1.75 per code because x


... as simple as that, preserving last two cols linearity.

Augment.PNG
1位用户喜欢此帖子
Tuan Nguyen 2021/4/22 18:37:00
#11 已发布: 2021/4/22 18:41:11
Tuan Nguyen

Tuan Nguyen

0个赞,共16个帖子。

组: User

Me feeling dumb. Thanks, Jean and MKraska
  • 有新帖
  • 无新帖