Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Solving a quadratic Lagrange interpolant , How ?

  1. Apr 17, 2008 #1
    [​IMG]



    how would i solve it using matlab ? I tried many times but i didnt get the same answer may anyone help me please ?
     
    Last edited: Apr 17, 2008
  2. jcsd
  3. Apr 17, 2008 #2
    Anyone please ? I have to submit this in 2 days please help...


    My attempt is as follows

    v(15)=a0+a1(t)+a2(t)=24
    a0+a1(15)+a2(15)^2=24


    v(18)=a0+a1(t)+a2(t)=37
    a0+a1(18)+a2(18)^2=37

    v(22)=a0+a1(t)+a2(t)=25
    a0+a1(22)+a2(22)^2=25


    I then wrote it in the Matrix Form

    a=[1 15 225;1 18 324;1 22 484]
    b=[24;27;35]
    x=a/b

    Results:

    a0=-323.8571
    a1=38.9048
    a2=-1.0476


    Using the following Equation:

    v(16)=-323.8571+(38.9048*16)+(-1.0476*(16^2))=
    30.4341 s which is wrong ofcourse The ans is 20.846 so wheres my mistake
     
  4. Apr 17, 2008 #3
    The value 26m/s is obtained twice

    First interval: 15 -18
    Second Interval: 18-22

    So i should be getting two answers is that so ?
     
  5. Apr 19, 2008 #4
    Anyone please help me submission is tommrow
     
Know someone interested in this topic? Share this thread via Reddit, Google+, Twitter, or Facebook

Have something to add?



Similar Discussions: Solving a quadratic Lagrange interpolant , How ?
  1. Lagrange Interpolation (Replies: 14)

  2. How to solve this bug? (Replies: 14)

Loading...