Exercise · ZW-LINEAR-LEAST-SQUARES-008 · ★★☆ Intermediate

To fit \(y=c\,t\) (no intercept) to the points \((1,2)\) and \((2,3)\), what is \(c\)?

Choose one option.

Show answer
  • D. \(c=\tfrac{8}{5}\)

Explanation

Here \(A=(1,2)^\top\) and \(b=(2,3)^\top\), so \(c=\dfrac{A^\top b}{A^\top A}=\dfrac{8}{5}\). The option \(c=\tfrac{3}{2}\) is just the slope of the second point, ignoring the first.

Study Continuous optimization in ZWMath →

Review the concept: Linear least squares

Optimization problem that minimizes the sum of squared residuals \(\|Ax-b\|_2^2\) to approximate a vector \(b\) by linear combinations of the columns of \(A\).

\[\min_{x}\ \|Ax-b\|_2^2 \quad \Rightarrow \quad A^\top A\,x = A^\top b\]

More practice problems: linear least squares

← ZW-LINEAR-LEAST-SQUARES-007 ZW-LINEAR-LEAST-SQUARES-009 →