15/3338–12FE Reference Handbook 10.4 · Mathematics · Statistics / curve fitting

Handbook formula

Linear Least Squares

The least-squares line y = a + b x minimizes Σ(y_i − a − b x_i)². The Handbook gives the normal-equation formulas for intercept a and slope b. Correlation r measures linear association; r² is the coefficient of determination.

Number of data pairs
Intercept
Slope
Sample means

Step-by-step solved example

Fit y = a + bx to (1,2), (2,3), (3,5).

εσF_y
Best-fit line through scattered (x,y) data.
  1. 1. Sums

    n=3, Σx=6, Σy=10, Σxy=1·2+2·3+3·5=23, Σx²=1+4+9=14.

  2. 2. Slope

    b = (3·23 − 6·10)/(3·14 − 6²) = (69−60)/(42−36) = 1.5.

  3. 3. Intercept

    a = 10/3 − 1.5·2 = 3.333 − 3 = 0.333.

Answer: y = 0.333 + 1.5x

10 practice questions

0/10 correct

1.The least-squares line always passes through

2.If every y increases by 4, the slope b

3.n = 2 points determine a line with residual sum of squares

4.Coefficient of determination r² = 1 means

5.The quantity minimized is

6.x̄ = 2, ȳ = 5, b = 3. Intercept a =

7.If x and y are uncorrelated, the least-squares slope is

8.n Σx² − (Σx)² is proportional to

9.Extrapolation far beyond the data range is

10.Three points (0,0),(1,1),(2,1). Σx, Σy, Σxy =