Question: last question I swear :)

Hello all,

This will be my LAST (I swear) question about translating a little function from Mathematica to Maple.

rand := RandomReal[{-5, 5}, 20]

ListPlot[rand]

 

ListListLinePlot[rand]

In[16]:= line = Fit[rand, {1, x}, x]

Out[16]= 0.247498 - 0.0131912 x

In[17]:= parabol = Fit[rand, {1, x, x^2}, x]

Out[17]= -1.82858 + 0.31249 x - 0.0082569 x^2

In[18]:= cos = Fit[rand, {1, x, Cos[x]}, x]

Out[18]= 0.483172 - 0.0302095 x - 0.271457 Cos[x]

Plot[{ListLinePlot[rand], line, parabol, cos}, {x, 0, 20}]

#graph omitted by request of users here.

So, then, my LAST question will be :

How to translate this to Maple ?

Thank you very much.

JM

Please Wait...