How to do this on my Prime ?

09292017, 11:56 AM
Post: #1




How to do this on my Prime ?
Hi,
I am learn how to calculate a fonction of parabole with 3 points given. Me I do at hand pincil and paper, after I have resolve I obtain a system of 3 equations what I resolve with app linear solver. But I have to calculation by hand the system as I say. On internet I have see on a computer hand I dont' know the name a solution automatic, which I have tryied on Prime but no work. May be is a way to do same ? In attachement I give what I do with hand and the other picture, may be you help me to do with Prime. Because I know how to do with hand ,it save me time for excercizes further if there is a solution automatic with Prime. I hope it is clear because it is difficult for me to speek american. Gérard. 

09292017, 12:26 PM
Post: #2




RE: How to do this on my Prime ?
1  The quickest way might be to determine the Lagrange polynomial:
lagrange([1 2 3], [2 1 4]) (then simplify the result). 2  If you really want to solve the linear equations then you can do that as follows: linsolve([a+b+c=2 4*a2*b+c=1 9*a+3*b+c=4], [a b c]) 3  Or if you want to imitate the approach in your second screenshot: f(x):=a*x^2+b*x+c solve({f(1)=2,f(2)=1,f(3)=4},[a b c]) 

09292017, 12:32 PM
Post: #3




RE: How to do this on my Prime ?
(09292017 11:56 AM)ggauny@live.fr Wrote: I am learn how to calculate a fonction of parabole with 3 points given. I am sure there is a more elegant way on the Prime, but all you need is the linear equation solver. For a parabola the equation system is as follows: Code:  x1² x1 1  →  y1  So simply start the linear solver and fill the matrix. Consider the example in your screenshot: Enter the xvalues into the center column and the yvalues on the righthand side: Code:  _ 1 _  →  2  Fill the left column with the squares of the center column: Code:  1 1 _  →  2  Fill the right column with 1s: Code:  1 1 1  →  2  Now solve this system and you're done. Dieter 

09292017, 12:52 PM
(This post was last modified: 09292017 01:00 PM by Gerson W. Barbosa.)
Post: #4




RE: How to do this on my Prime ?
Interesting ideas in this old thread (others, not mine).


09292017, 01:22 PM
Post: #5




RE: How to do this on my Prime ?
(09292017 12:52 PM)Gerson W. Barbosa Wrote: Interesting ideas in this old thread (others, not mine).Thanks for that link. And as you already suggested: Cramer's Rule is not very efficient in general and should probably be avoided for numerical calculations, especially when the dimension goes up. And I am not 100% sure, but I seem to remember that the determinant calculations are also quite sensitive to rounding (not if all you care about are integer x values of course). Again, this becomes more of a problem as the dimension goes up. 

09292017, 02:59 PM
Post: #6




RE: How to do this on my Prime ?
Hi,
One again many thank you at all. You are great teachers mathematician ! Have a good day. Gérard. 

09292017, 04:53 PM
(This post was last modified: 09292017 04:58 PM by toshk.)
Post: #7




RE: How to do this on my Prime ?
(09292017 12:32 PM)Dieter Wrote:[[2],[1],[4]]/vandermonde([1,2,3])(09292017 11:56 AM)ggauny@live.fr Wrote: I am learn how to calculate a fonction of parabole with 3 points given. for ill/weird/large/spare matrix: try LSQ(vandermonde([1,2,3]),[[2],[1],[4]]) 

« Next Oldest  Next Newest »

User(s) browsing this thread: 1 Guest(s)