# 超定方程组

超定方程组是指方程个数多于未知数个数的方程组，通常为线性方程组，因此一般不存在精确解，转而寻求最佳近似解。对于写作 \( A x = b \) 的线性方程组，其中 \( A \in \mathbb{R}^{m \times n} \) 且 \( m > n \)，标准做法是求最小二乘解，它使残差 \( r(x) = b - Ax \) 的欧几里得范数最小。<sup>[1](https://mathworld.wolfram.com/OverdeterminedSystem.html)</sup><sup> • </sup><sup>[2](https://courses.math.wichita.edu/math451/ch3/8/LeastSquares.html)</sup>

| 关键事实 | 细节 |
|---|---|
| 定义 | 方程多于未知数：\( A \) 为 \( m \times n \) 矩阵，且 \( m > n \)<sup>[2](https://courses.math.wichita.edu/math451/ch3/8/LeastSquares.html)</sup> |
| 精确可解性 | 线性超定方程组有精确解当且仅当 \( b \) 属于 \( A \) 的列空间；超定方程组未必不相容<sup>[1](https://mathworld.wolfram.com/OverdeterminedSystem.html)</sup> |
| 最小二乘解 | 使 \( \|b - Ax\|_2 \) 最小；当 \( A \) 的列线性无关时，解唯一，且满足正规方程 \( A^T A x = A^T b \)<sup>[1](https://mathworld.wolfram.com/OverdeterminedSystem.html)</sup> |
| 冗余度 | 方程组的冗余度为 \( m - n \)，即超出确定未知数所需最少观测数的观测数<sup>[3](https://mude.citg.tudelft.nl/book/2026-draft/observation_theory/02_LeastSquares.html)</sup> |
| 数值实践 | QR 分解避免了使用正规方程造成的条件数平方问题，\( \kappa_2(A^T A) = \kappa_2(A)^2 \)，代价约为 \( 2mn^2 - \tfrac{2}{3}n^3 \) 次浮点运算<sup>[4](https://ericdarve.github.io/NLA/content/LS_using_QR.html)</sup> |
| 秩亏情形 | 当 \( \operatorname{rank}(A) < \min(m,n) \) 时，最小范数最小二乘解同时使 \( \|x\|_2 \) 和 \( \|b - Ax\|_2 \) 最小；LAPACK 为此情形提供驱动程序 xGELSY、xGELSS 和 xGELSD<sup>[5](https://www.netlib.org/lapack/lug/node27.html)</sup> |
| 历史起源 | 勒让德（Legendre）于 1805 年发表最小二乘法；高斯（Gauss）称自 1795 年起便已使用该原理，优先权之争最终以勒让德 1820 年对高斯的攻击达到高潮<sup>[6](https://en.wikisource.org/wiki/A_Source_Book_in_Mathematics/Legendre_on_Least_Squares)</sup><sup> • </sup><sup>[7](https://www.sciencedirect.com/science/article/pii/0315086077900325)</sup> |

## 可解性与几何

方程多于未知数本身并不使方程组无解。方程组 \( x = 1 \) 与 \( 2x = 2 \) 是超定的，有公共解 \( x = 1 \)，而 \( x = 1 \) 与 \( x = 2 \) 则无解。一般而言，线性超定方程组 \( Ax = b \) 有精确解当且仅当 \( b \) 位于 \( A \) 的列空间中。<sup>[1](https://mathworld.wolfram.com/OverdeterminedSystem.html)</sup>

当不存在精确解时，最小二乘解 \( \hat{x} \) 是使 \( \|A\hat{x} - b\|_2 \le \|Ax - b\|_2 \) 对所有 \( x \) 成立的向量。从几何上看，\( A\hat{x} \) 是 \( A \) 的列空间中距离 \( b \) 最近的点，因此残差 \( b - A\hat{x} \) 与该空间正交；这一正交条件正是正规方程所表达的。<sup>[2](https://courses.math.wichita.edu/math451/ch3/8/LeastSquares.html)</sup><sup> • </sup><sup>[8](https://epubs.siam.org/doi/full/10.1137/23M161851X)</sup> 若 \( A \) 的列线性无关，则最小二乘解唯一，且等于 \( \hat{x} = (A^T A)^{-1} A^T b \)。<sup>[1](https://mathworld.wolfram.com/OverdeterminedSystem.html)</sup><sup> • </sup><sup>[2](https://courses.math.wichita.edu/math451/ch3/8/LeastSquares.html)</sup>

## 最小二乘解

正规方程来自对残差平方 \( (y - Ax)^T (y - Ax) \) 的最小化：令其对 \( x \) 的导数为零，得到 \( A^T A x = A^T y \)，其中对称矩阵 \( N = A^T A \) 称为正规矩阵。<sup>[3](https://mude.citg.tudelft.nl/book/2026-draft/observation_theory/02_LeastSquares.html)</sup> 正规方程表明，任何最小二乘解的残差 \( r = b - Ax \) 必须与 \( A \) 的所有列正交。<sup>[8](https://epubs.siam.org/doi/full/10.1137/23M161851X)</sup>

范数的选择很重要。用 2-范数度量误差得到最小二乘法；其他范数定义不同的近似解，选择可能显著改变结果。<sup>[9](https://pages.cs.wisc.edu/~amos/412/lecture-notes/lecture16.pdf)</sup> 在统计噪声模型下，即每个测量值等于模型预测值加上独立高斯噪声，最小化残差平方和恰好就是最大似然估计，这是平方准则的经典依据；噪声水平由残差估计为 \( \hat{\sigma}^2 = \mathrm{SSE}/(n - p) \)，其中 \( n \) 为数据点数，\( p \) 为拟合参数个数。<sup>[10](https://www.medford.chbe.gatech.edu/DA4CHE/1-numerical_methods/Topic1.5-Parameter_Estimation.html)</sup>

## 数值解法

**正规方程与 QR 分解。** 构造并求解正规方程效率高，但数值上脆弱：\( A^T A \) 的条件数是 \( A \) 的条件数的平方，即 \( \kappa_2(A^T A) = \kappa_2(A)^2 \)，因此病态的 \( A \) 用这种方法会损失大约两倍的精度位数。QR 分解 \( A = QR \)，其中 \( Q \) 正交、\( R \) 上三角，将问题化为用回代求解的方阵三角方程组 \( R_1 x = Q_1^T b \)，使用的是 \( \kappa_2(A) \) 本身。分解步骤的代价约为 \( 2mn^2 - \tfrac{2}{3}n^3 \) 次浮点运算，与正规方程方法相当。<sup>[4](https://ericdarve.github.io/NLA/content/LS_using_QR.html)</sup><sup> • </sup><sup>[11](https://courses.seas.harvard.edu/courses/am205/fall13/AM205_unit_2_chapter_3.pdf)</sup>

**秩亏与稀疏问题。** 当 \( A \) 可能秩亏时，最小范数最小二乘解同时使 \( \|x\|_2 \) 和 \( \|b - Ax\|_2 \) 最小。LAPACK 的驱动程序覆盖了这一谱系：xGELS 假定满秩，使用 QR 或 LQ 分解；xGELSY 使用完全正交分解；xGELSS 和 xGELSD 使用奇异值分解，其中 xGELSD 对大规模问题显著更快，代价是更多工作空间。<sup>[5](https://www.netlib.org/lapack/lug/node27.html)</sup> 对于大型稀疏方程组，LSQR 等迭代方法求 \( Ax = b \) 或其阻尼变体 \( \min \|Ax - b\|^2 + d^2\|x - x_0\|^2 \) 的最小二乘解，接受方阵或矩形、超定或欠定、任意秩的矩阵。<sup>[12](https://cache-docs.scipy.org/doc/scipy/reference/generated/scipy.sparse.linalg.lsqr.html)</sup>

**软件。** SciPy 的 `scipy.linalg.lstsq` 计算使 \( \|b - Ax\|_2 \) 最小的最小二乘解 \( x \)，提供 LAPACK 驱动程序 `gelsd`（默认）、`gelsy` 和 `gelss`，并返回 \( A \) 的有效秩和奇异值，其比值 `s[0]/s[-1]` 给出条件数。<sup>[13](https://docs.scipy.org/doc/scipy/reference/generated/scipy.linalg.lstsq.html)</sup> MATLAB 的反斜杠运算符对矩形方程组产生最小二乘解，并在 \( A \) 秩亏时发出警告，此时 `lsqminnorm` 求最小范数解。<sup>[14](https://www.mathworks.com/help/matlab/math/systems-of-linear-equations.html)</sup>

## 历史

最小二乘法源于天文观测的超定方程组。十九世纪初，天文观测与由牛顿（Newton）原理导出的轨道公式之间的差异有时使万有引力平方反比定律受到怀疑，如何综合大量观测来求模型参数成为核心问题；在此类模型中，每个方程代表一次观测的数据，未知数即模型参数。<sup>[15](https://doi.org/10.1016/j.hm.2010.06.003)</sup>

阿德里安-马里·勒让德（Adrien-Marie Legendre，1752–1833）曾在巴黎军事学校任数学教授五年，于 1805 年发表最小二乘法，作为一种不假定随机性的近似工具。<sup>[6](https://en.wikisource.org/wiki/A_Source_Book_in_Mathematics/Legendre_on_Least_Squares)</sup><sup> • </sup><sup>[16](https://link.springer.com/article/10.1007/s00407-022-00291-w)</sup> 卡尔·弗里德里希·高斯（Carl Friedrich Gauss）在其 1809 年关于天体运动的工作中称，他自 1795 年起便已使用该原理，但首先由勒让德发表；优先权问题在勒让德 1820 年发表对高斯的攻击时达到高潮。<sup>[6](https://en.wikisource.org/wiki/A_Source_Book_in_Mathematics/Legendre_on_Least_Squares)</sup><sup> • </sup><sup>[7](https://www.sciencedirect.com/science/article/pii/0315086077900325)</sup> 高斯给出了两种论证：1809 年他证明，在误差正态分布的假设下，最大似然估计量等于最小二乘公式；1823 年他又在不假设正态性的情况下将最小二乘导出为最佳线性无偏估计。在 1839 年致弗里德里希·贝塞尔（Friedrich Bessel）的一封信中，高斯写道，出于一个他未公开说明的理由，他认为后者更为根本，并更偏爱自己 1823 年的论证。<sup>[16](https://link.springer.com/article/10.1007/s00407-022-00291-w)</sup> 高斯的第一种证明，连同正态分布误差在许多情形下的充分性，使哈根（Hagen，1867）、肖维涅（Chauvenet，1868）和梅里曼（Merriman，1884）等后来的作者得以从高斯时代到现代统计学发展期间维持一种在统计上站得住脚的估计方法论。<sup>[15](https://doi.org/10.1016/j.hm.2010.06.003)</sup>

## 应用

凡观测数超过确定未知数所需最少数量之处，超定方程组都会出现，这是有意为之，以减少噪声的影响。在大地测量学和卫星定位中，这种做法称为平差：由全球导航卫星系统的卫星确定地理位置至少需要四颗卫星来固定位置和钟差，而通常会综合四颗以上的卫星，用最小二乘获得更好的位置估计及其不确定度估计。<sup>[3](https://mude.citg.tudelft.nl/book/2026-draft/observation_theory/02_LeastSquares.html)</sup><sup> • </sup><sup>[17](https://www2.imm.dtu.dk/pubdb/pubs/2804-full.html)</sup>

对实验数据进行曲线拟合是另一常见来源。将 \( y(t) = c_1 + c_2 e^{-t} \) 之类的模型拟合到六次测量，得到两个未知数的六个方程，即一个 6×2 的方程组，用最小二乘求解；拟合模型不会精确再现数据，但差异可能小于原始数据中的测量误差。<sup>[14](https://www.mathworks.com/help/matlab/math/systems-of-linear-equations.html)</sup> 同样的结构普遍构成回归分析的基础，后者是从自然科学到社会科学各领域最广泛使用的统计技术之一。<sup>[17](https://www2.imm.dtu.dk/pubdb/pubs/2804-full.html)</sup>

## References

1. [Weisstein, Eric W. "Overdetermined System." MathWorld, Wolfram Research.](https://mathworld.wolfram.com/OverdeterminedSystem.html)
2. ["Least Squares Problems," Math 511 Linear Algebra, Wichita State University.](https://courses.math.wichita.edu/math451/ch3/8/LeastSquares.html)
3. [Verhagen, S. "Least-squares estimation," MUDE textbook, Delft University of Technology.](https://mude.citg.tudelft.nl/book/2026-draft/observation_theory/02_LeastSquares.html)
4. [Darve, E. "Solving Least-Squares using QR Factorization," Numerical Linear Algebra, Stanford University.](https://ericdarve.github.io/NLA/content/LS_using_QR.html)
5. ["Linear Least Squares (LLS) Problems," LAPACK Users' Guide, Netlib.](https://www.netlib.org/lapack/lug/node27.html)
6. ["Legendre on Least Squares," A Source Book in Mathematics, Wikisource.](https://en.wikisource.org/wiki/A_Source_Book_in_Mathematics/Legendre_on_Least_Squares)
7. ["An attack on Gauss, published by Legendre in 1820," Historia Mathematica, ScienceDirect.](https://www.sciencedirect.com/science/article/pii/0315086077900325)
8. [Wathen, Andrew J. "Least Squares and the Not-Normal Equations," SIAM Review (2024).](https://epubs.siam.org/doi/full/10.1137/23M161851X)
9. ["cs412: Introduction to Numerical Analysis," Lecture 16, University of Wisconsin–Madison.](https://pages.cs.wisc.edu/~amos/412/lecture-notes/lecture16.pdf)
10. [Medford, A. J. "Nonlinear Parameter Estimation," Data Analytics for Chemical Engineers, Georgia Tech.](https://www.medford.chbe.gatech.edu/DA4CHE/1-numerical_methods/Topic1.5-Parameter_Estimation.html)
11. ["Applied Mathematics 205, Unit II: Numerical Linear Algebra," Harvard University.](https://courses.seas.harvard.edu/courses/am205/fall13/AM205_unit_2_chapter_3.pdf)
12. ["lsqr," SciPy v1.18.0 Manual.](https://cache-docs.scipy.org/doc/scipy/reference/generated/scipy.sparse.linalg.lsqr.html)
13. ["lstsq," SciPy v1.18.0 Manual.](https://docs.scipy.org/doc/scipy/reference/generated/scipy.linalg.lstsq.html)
14. ["Systems of Linear Equations," MATLAB & Simulink Documentation, MathWorks.](https://www.mathworks.com/help/matlab/math/systems-of-linear-equations.html)
15. ["How ordinary elimination became Gaussian elimination," Historia Mathematica, ScienceDirect.](https://doi.org/10.1016/j.hm.2010.06.003)
16. ["Gauss on least-squares and maximum-likelihood estimation," Archive for History of Exact Sciences, Springer Nature (2022).](https://link.springer.com/article/10.1007/s00407-022-00291-w)
17. ["Least Squares Adjustment: Linear and Nonlinear Weighted Regression Analysis," Technical University of Denmark.](https://www2.imm.dtu.dk/pubdb/pubs/2804-full.html)

---
*Initially written Sep 17, 2026 · Reviewed: Sep 30, 2026; Oct 15, 2026 · Edited: Sep 30, 2026; Oct 15, 2026 · Last review: Oct 15, 2026*

Topic: 物质世界与数学 › 数学与统计学 › 数与代数 › Linear and multilinear algebra › Numerical linear algebra › Least squares and overdetermined systems

Copyright 2026 Edgepedia

License: Edgepedia Community License 1.0, https://www.edgepedia.org/edgepedia/license

Source: https://www.edgepedia.org/zh/overdetermined-system

English original: https://www.edgepedia.org/overdetermined-system
