1. Limited time only! Sign up for a free 30min personal tutor trial with Chegg Tutors
    Dismiss Notice
Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Least-squares fit

  1. Apr 11, 2013 #1
    Given the data points (-1,2) (0,1) and (3,-4), you want to fit the best straight line, y=mx + b, through these points. given that m = -20/13, find the value of b that minimizes the error E = Ʃ ("N" on top, "i=1" on bottom) (MXi + B - Yi)^2.

    This was on a test I just took for calc 1. I did the work there, I am not going to put it all on here via computer. Basically I took the derivative of the function with respect to B. Then did three iterations of it using the data points. Then solved for B. I got b = .691. Can anyone confirm/refute this?


    Thanks
     
  2. jcsd
  3. Apr 11, 2013 #2

    Mark44

    Staff: Mentor

    You're asking a lot for helpers to work the whole problem for you and compare what they get to your answer. Forum requirements are that you show what you've done.
     
    Last edited: Apr 11, 2013
  4. Apr 11, 2013 #3

    Dick

    User Avatar
    Science Advisor
    Homework Helper

    Yes, it's pretty close. If you work a little harder you can get an exact fractional answer for B like the -20/13 for the slope.
     
    Last edited: Apr 11, 2013
Know someone interested in this topic? Share this thread via Reddit, Google+, Twitter, or Facebook

Have something to add?
Draft saved Draft deleted



Similar Discussions: Least-squares fit
  1. Least Squares Fit (Replies: 3)

  2. Least Squares Fitting (Replies: 1)

  3. Least squares fitting (Replies: 12)

Loading...