Syntax for linterp

Syntax for linterp - What is the correct syntax for linterp(x,y,z) - Mensajes

#1 Publicado: 14/2/2019 18:57:41
RegCurry

RegCurry

0 me gusta en 57 mensajes.

Grupo: User

Sorry to be so slow on Smath. Some thing work like Mathcad and some don't. I need help with the correct syntax for the interpolation function linterp. I have tired all combinations of syntax that I can think of and none work in the attached Smath file.

Help would be appreciated.



RMD CALCULATION.sm (15,13 KiB) descargado 1292 vez(es).

#2 Publicado: 14/2/2019 19:17:53
RegCurry

RegCurry

0 me gusta en 57 mensajes.

Grupo: User

Oops I meant this way to no success.

RMD CALCULATION.sm (15,27 KiB) descargado 1254 vez(es).
#3 Publicado: 14/2/2019 20:30:15
Arie

Arie

94 me gusta en 285 mensajes.

Grupo: User

I don't think vectorize works with this function. It is expecting a single value in argument 3. Checkout my linterp2 function in the attached. I think it does what you want.
RMD CALCULATION.sm (18,24 KiB) descargado 1262 vez(es).

Note: In my program, it is not necessary to initialize the result. However, I have found that in cases of large vectors, it speeds up processing time to initialize a vector to the expected size and then fill in values. I generally just do this as standard practice now even if it's not necessary.
Feel free to join the SMath Studio Users Discord Channel: https://discord.gg/PayZpJW
#4 Publicado: 14/2/2019 20:47:17
RegCurry

RegCurry

0 me gusta en 57 mensajes.

Grupo: User

Thanks much. You are a real help.

I did not realize that the interpolation functions required additional programming. I incorrectly assumed it was like Mathcad. Many things are like Mathcad, but clearly not all.

Thanks again.


Reg
#5 Publicado: 14/2/2019 20:56:20
Arie

Arie

94 me gusta en 285 mensajes.

Grupo: User

No problem!. Welcome to the forum. There are a lot of people here who are regular contributors and will help you with questions you have. For me, it's why I primarily use SMath for my calculations.

Regarding similarity/dissimilarity to MathCAD... once you start using SMath more you'll stop thinking in "MathCAD" and be able to think in "SMath". As a former MathCAD convert myself, I really started to come into my own when I stopped thinking of how I would do things in MathCAD and started figuring out how best to use SMath.
Feel free to join the SMath Studio Users Discord Channel: https://discord.gg/PayZpJW
#6 Publicado: 14/2/2019 21:16:12
Jean Giraud

Jean Giraud

983 me gusta en 6.866 mensajes.

Grupo: User

Wrote

Some thing work like Mathcad and some don't.I need help with the correct syntax for the interpolation function linterp.


Read carefully: linterp, cinterp are 1/1 Mathcad
Smath ainterp has special virtues not found in Mathcad.
Smath linterp, cinterp, ainterp are 1/1 Mathcad as interpolation.
but are 0/1 as scalar functions. In many instances, it is possible
to recast the problem in the form of infinitesimal analysis.
I found no way to render a_c_l interp scalar Mathcad style.
Though, I have the Mathcad code. Don't confuse yourself, a_c_l_interp
they plot on the canvas, i.e: they plot scalar.
scalar is a kernel internal vanishing iterator
Next question: please attach the Smath document.

Jean

#7 Publicado: 14/2/2019 21:53:35
Jean Giraud

Jean Giraud

983 me gusta en 6.866 mensajes.

Grupo: User

Wrote

Oops I meant this way to no success.


Sorry, I downloaded the other one.
Either blue/red will each have an extraordinary good model fit,
for further processing [deriv, int].

linterp.PNG
#8 Publicado: 14/2/2019 22:57:58
Jean Giraud

Jean Giraud

983 me gusta en 6.866 mensajes.

Grupo: User

Wrote

Oops I meant this way to no success.



RMD CALCULATION (J).sm (18,81 KiB) descargado 1274 vez(es).

#9 Publicado: 14/2/2019 23:51:13
Jean Giraud

Jean Giraud

983 me gusta en 6.866 mensajes.

Grupo: User

... a bit .

RMD CALCULATION (J).sm (26,09 KiB) descargado 1279 vez(es).
#10 Publicado: 15/2/2019 0:08:02
Jean Giraud

Jean Giraud

983 me gusta en 6.866 mensajes.

Grupo: User

... interesting stuff .

Interpolate [Linterp, Spline2D].sm (118,34 KiB) descargado 1109 vez(es).
#11 Publicado: 15/2/2019 0:20:02
RegCurry

RegCurry

0 me gusta en 57 mensajes.

Grupo: User


Jean,
I appreciate your attempt at helping me. Unfortunately, I am new to Smath and don't really understand your syntax in your attached sm file. See my comments in the attached file.


Wrote

Wrote

Oops I meant this way to no success.



RMD CALCULATION (J).sm (18,81 KiB) descargado 1274 vez(es).



RMD%20CALCULATION%20(J)-1.sm (21,15 KiB) descargado 1406 vez(es).

Sorry, I am just too new to this code to appreciate your input.
Thanks again,
Reg
#12 Publicado: 15/2/2019 0:41:09
Alvaro

Alvaro

1.139 me gusta en 1.805 mensajes.

Grupo: User

Hi. You can do some plots too.
Best regards.
Alvaro.

RMD CALCULATION.sm (10,79 KiB) descargado 1298 vez(es).

Clipboard02.gif
#13 Publicado: 15/2/2019 1:46:57
RegCurry

RegCurry

0 me gusta en 57 mensajes.

Grupo: User

Thanks to all. I was able to find some useful stuff from everyone. Here is where I was headed.

RMD CALCULATION.sm (16,94 KiB) descargado 1214 vez(es).



#14 Publicado: 15/2/2019 1:57:46
Jean Giraud

Jean Giraud

983 me gusta en 6.866 mensajes.

Grupo: User

Wrote

Sorry, I am just too new to this code to appreciate your input.
Thanks again,
Reg


Hello Reg ... answered in blue

RMD CALCULATION (J in_blue)-1.sm (24,61 KiB) descargado 1230 vez(es).

#15 Publicado: 15/2/2019 3:51:44
Radovan Omorjan

Radovan Omorjan

325 me gusta y 1 no me gusta en 2.052 mensajes.

Grupo: Moderator

Just a note.

Pay attention to the plot by Alvaro. He uses often neded lele() function (Custom functions plugin) for checking if the value is in a range: Xmin<=x<=Xmax

Regards,
Radovan
When Sisyphus climbed to the top of a hill, they said: "Wrong boulder!"
A 1 usuarios les gustó este mensaje
frapuano 15/2/2019 5:52:00
#16 Publicado: 15/2/2019 12:47:44
Jean Giraud

Jean Giraud

983 me gusta en 6.866 mensajes.

Grupo: User

Wrote

Thanks to all.I was able to find some useful stuff from everyone.


... more in there for publishing.
Little Smath doing so much, so nice !

Jean

RMD CALCULATION (J).sm (35,64 KiB) descargado 1266 vez(es).


#17 Publicado: 15/2/2019 18:55:22
RegCurry

RegCurry

0 me gusta en 57 mensajes.

Grupo: User



Is this XY plot new? I find it really helpful.

RMD CALCULATION.sm (18,33 KiB) descargado 1220 vez(es).
#18 Publicado: 15/2/2019 22:48:25
Jean Giraud

Jean Giraud

983 me gusta en 6.866 mensajes.

Grupo: User

Wrote

Is this XY plot new?I find it really helpful.


Not new, just from applied Smath features as in older SS 6179.
  • Nuevos mensajes
  • Sin mensajes nuevos