最小二乘法逼近

最小二乘法逼近
几何画板及绘图内容加载中,请稍等……
2017-07-14 14:03
①本范例演示了如何通过最小二乘法对散点数据进行线性回归,绘制最佳拟合直线;②涉及的核心数学概念包括最小二乘法、统计特征、正态分布、相似变换和二维向量;③作图要点——使用了Sequence、Sum、Textfield、TableText等GeoGebra命令/对象,通过按钮控制不同函数(Legendre、Chebyshev)的系数计算与展示;④适合高中及以上数学学习者,用于理解数据拟合和优化方法。

GeoGebra 命令及参数

  1. Sequence(Integral[(Element[Legendre, i] * f0(x)), -1, 1] / Integral[Element[Legendre, i]^(2), -1, 1], i, 1, 11) → LeCoeff
  2. Sequence(Integral[((w(x) * Element[Chebyshev, i]) * f0(x)), -0.999999999, 0.999999999] / Integral[(w(x) * Element[Chebyshev, i]^(2)), -0.999999999, 0.999999999], i, 1, 11) → ChCoeff
  3. Sum(L, n + 1) → LL
  4. Sum(C, n + 1) → CC
  5. Textfield(f0) → InputBox1
  6. Sequence(Element[LeCoeff, i], i, 1, n + 1) → list1
  7. Sequence(Element[ChCoeff, i], i, 1, n + 1) → list2
  8. Sequence(Element[list3, i], i, 1, n + 1) → list4
  9. TableText({list4, list1}, "v") → text1
  10. TableText({list4, list2}, "v") → text2