# 奇异矩阵

**奇异矩阵**（singular matrix）是行列式为零的方阵，等价地说，是没有乘法逆的方阵。奇异性并非边缘的猎奇话题，而是线性代数的一个边界情形：奇异的系数矩阵不能保证对每个右端项都有唯一解，而接近奇异时的病态又可能使浮点计算变得不可靠。

| 关键事实 | 详情 |
|---|---|
| 定义 | 方阵奇异当且仅当 det(A) = 0；等价地，其简化行阶梯形至少有一行全零<sup>[1](https://tobydriscoll.net/udmath305/linalg/singular.html)</sup> |
| 等价条件 | 非平凡零空间、列线性相关、秩小于 n、有零特征值，以及对某个 b，Ax = b 没有唯一解<sup>[2](https://linear.pugetsound.edu/390/section-NM.html)</sup><sup> • </sup><sup>[3](https://www.cs.utexas.edu/~flame/laff/alaff/chapter09-singular-matrices-and-the-eigenvalue-problem.html)</sup> |
| 条件数 | κ(A) = ‖A‖‖A⁻¹‖；奇异矩阵的条件数为无穷大，有限但很大的条件数意味着矩阵接近奇异<sup>[4](https://www.phys.uconn.edu/~rozman/Courses/m3510_21f/downloads/condnumber.pdf)</sup> |
| 数值容差 | NumPy 的 matrix_rank 把小于 S.max() × max(M, N) × eps 的奇异值视为秩亏，这与 MATLAB 所用的算法相同<sup>[5](https://github.com/numpy/numpy/blob/main/numpy/linalg/_linalg.py)</sup> |
| 随机矩阵 | 元素连续的矩阵（均匀或正态）以零概率奇异；随机 ±1 矩阵奇异的概率为 (2+o(1))n²2⁻ⁿ<sup>[6](https://blogs.sas.com/content/iml/2011/09/28/what-is-the-chance-that-a-random-matrix-is-singular.html)</sup><sup> • </sup><sup>[7](https://arxiv.org/html/2609.39463)</sup> |
| 到奇异的距离 | 最小奇异值等于在谱范数下 A 到奇异矩阵集合的距离<sup>[8](https://www.math.uci.edu/~rvershyn/papers/rv-invertibility.pdf)</sup> |

## 定义与等价刻画

对 n × n 矩阵 A，以下陈述彼此等价，因此其中任何一条都可作为奇异性的定义<sup>[1](https://tobydriscoll.net/udmath305/linalg/singular.html)</sup><sup> • </sup><sup>[2](https://linear.pugetsound.edu/390/section-NM.html)</sup><sup> • </sup><sup>[3](https://www.cs.utexas.edu/~flame/laff/alaff/chapter09-singular-matrices-and-the-eigenvalue-problem.html)</sup><sup> • </sup><sup>[9](https://linearalgebra.math.umanitoba.ca/math1220/section-25.html)</sup>：

- det(A) = 0。
- A 没有逆。
- A 的简化行阶梯形至少有一行全零（而不是单位矩阵 I_n）。
- A 的列线性相关。
- 齐次方程组 Ax = 0 有非零解，因此 A 的零空间维数为正。
- rank(A) < n。
- A 有零特征值。
- 至少对某个 b，Ax = b 没有唯一解。

行列式判据来自乘积法则 det(AB) = det(A)det(B)：若 A 有逆，则 det(A)det(A⁻¹) = det(I) = 1，这迫使 det(A) ≠ 0<sup>[1](https://tobydriscoll.net/udmath305/linalg/singular.html)</sup>。与特征值的联系则经由特征多项式：λ 是 A 的特征值，当且仅当 (λI − A) 奇异，即 det(λI − A) = 0 且零空间非平凡<sup>[3](https://www.cs.utexas.edu/~flame/laff/alaff/chapter09-singular-matrices-and-the-eigenvalue-problem.html)</sup>。

## 奇异性在实践中如何检测

在精确算术中，上述任一等价判据都适用。在计算机上情况就变了，因为问题变成矩阵是恰好奇异还是仅仅接近奇异，而软件划定这条界线的方式各不相同。

**行列式是错的工具。** 微小的行列式不是衡量接近奇异程度的可靠指标：把矩阵乘以 10⁻¹⁰，其行列式乘以 10⁻¹⁰ⁿ，而可逆性丝毫未变。因此实用代码回避基于行列式的检验。

**带主元的 LU 分解。** LAPACK 的 DGETRF 用部分主元计算 LU 分解 A = P·L·U，并通过其 INFO 输出报告是否恰好奇异，标出那种若用该因子求解方程组就会发生除零的情形<sup>[10](https://www.netlib.org/lapack/double/dgetrf.f)</sup>。LAPACK 的三角求解器同样会验证非奇异性，但只能检测出恰好奇异；其文档警告说，一个或多个对角元可能是次正规的极小数而不会报错，因此关心接近奇异性的调用者应先在某个容差内验证非奇异性<sup>[11](https://netlib.org/lapack/explore-html/d1/db6/group__tptrs_gaca2a67c006910a35d219248c83e58419.html)</sup>。

**基于 SVD 的秩检验。** 奇异值分解直接暴露秩：秩就是非零奇异值的个数，但舍入误差会在本应为精确零的地方产生小的非零值，因此需要一个“足够小”的阈值<sup>[12](https://www.nber.org/system/files/working_papers/w0066/w0066.pdf)</sup>。NumPy 的 matrix_rank 实现了标准选择，把小于 S.max() × max(M, N) × eps 的奇异值视为秩亏，其中 eps 是双精度机器精度；这与 MATLAB 所用的算法相同<sup>[5](https://github.com/numpy/numpy/blob/main/numpy/linalg/_linalg.py)</sup>。

**库的行为。** NumPy 的 inv 在检测到矩阵奇异时抛出 LinAlgError；若矩阵病态，则可能抛错也可能不抛，且由于浮点误差，结果可能不准确<sup>[5](https://github.com/numpy/numpy/blob/main/numpy/linalg/_linalg.py)</sup>。这两种行为之间的差距，正是奇异与接近奇异在实践上的区别。

## 数字说话

**条件数。** 用于求逆的条件数为 κ(A) = ‖A‖‖A⁻¹‖，即矩阵施加的最大伸缩与最小伸缩之比；奇异矩阵的条件数为无穷大，有限但很大的条件数意味着矩阵接近奇异<sup>[4](https://www.phys.uconn.edu/~rozman/Courses/m3510_21f/downloads/condnumber.pdf)</sup>。用奇异值分解表示，κ(A) = σ_max/σ_min。条件数是范数型相对误差的放大因子，因此条件数大的线性方程组在浮点机上难以精确求解<sup>[13](https://scg.ece.ucsb.edu/publications/papers/CMA_2016.pdf)</sup>。一条广泛使用的经验法则：若 cond(A) = 10ᵏ，你可能最多损失 k 位精度<sup>[5](https://github.com/numpy/numpy/blob/main/numpy/linalg/_linalg.py)</sup>。

**奇异的概率。** 答案因元素分布而截然不同：

- 连续分布：从均匀或正态分布中抽取的矩阵以零概率奇异，因为奇异集是行列式多项式的零点集，其测度为零。在一次十亿个随机矩阵的模拟中，行列式恰好为零的情况出现了零次<sup>[6](https://blogs.sas.com/content/iml/2011/09/28/what-is-the-chance-that-a-random-matrix-is-singular.html)</sup>。
- 离散分布：对元素独立均匀取自 {−1, 1} 的 n × n 矩阵，奇异概率为 (2+o(1))n²2⁻ⁿ，这一结果解决了拉德马赫奇异性猜想<sup>[7](https://arxiv.org/html/2609.39463)</sup>。更一般地，对元素均匀取自大小为 q ≥ 2 的固定集合 S 的矩阵，P(s_n(M_n) ≤ z/√n) ≤ Cz + a_n(S) + C′n^{1+ε}q⁻ⁿ<sup>[7](https://arxiv.org/html/2609.39463)</sup>。
- 结构定理：对离散元素，奇异概率等于出现零行或零列的概率，加上 (1+o_n(1)) 倍出现两行（或两列）相等（至多差一个符号）的概率，因此离散随机性主要通过可见的巧合导致奇异<sup>[14](https://ar5iv.labs.arxiv.org/html/2010.06554)</sup>。
- 对称矩阵：对均匀取自对称 ±1 n × n 矩阵的矩阵，奇异概率至多为 exp(−c(n log n)^{1/2})，改进了此前 exp(−c n^{1/2}) 的最好上界<sup>[15](https://par.nsf.gov/biblio/10330634-singularity-random-symmetric-matrices-revisited)</sup>。

**最小奇异值。** 埃德尔曼（Edelman）对高斯矩阵证明了 P(s_n(A) ≤ εn^{−1/2}) ∼ ε，证实了冯·诺依曼（von Neumann）的猜测和斯梅尔（Smale）的猜想，即最小奇异值的阶为 n^{−1/2}；对元素方差至少为 1 且四阶矩有界的矩阵，s_n(A) 的中位数同样为 n^{−1/2} 阶<sup>[8](https://www.math.uci.edu/~rvershyn/papers/rv-invertibility.pdf)</sup>。对随机 ±1 矩阵，P(s_n(A) ≤ c₀εn^{−1/2}) ≤ ε + e⁻ᶜⁿ，由此推出 P(det(A) = 0) ≤ e⁻ᶜⁿ<sup>[16](https://myria.math.aegean.gr/conferences/phdsamos2007/Talks/Rudelson.pdf)</sup>。

## 对线性方程组的影响

当 A 奇异时，方程组 Ax = b 要么无解，要么有无穷多解；唯一性恰好在奇异处丧失。非奇异性等价于对每个 b，Ax = b 都恰有一个解<sup>[2](https://linear.pugetsound.edu/390/section-NM.html)</sup><sup> • </sup><sup>[9](https://linearalgebra.math.umanitoba.ca/math1220/section-25.html)</sup>。秩–零化度定理确定了其几何形态：零化度（零空间的维数）加秩等于列数，因此秩为 n − k 的 n × n 矩阵有 k 维的齐次解零空间<sup>[17](https://pressbooks.pub/linearalgebraandapplications/chapter/existence-and-unicity-of-solutions/)</sup>。

克拉默法则（Cramer's rule）通过行列式之比表达解，它恰在 det(A) = 0 时失效<sup>[1](https://tobydriscoll.net/udmath305/linalg/singular.html)</sup>。

对长方形矩阵而言根本不存在行列式，一般行为一分为二。一般而言，瘦（超定）方程组几乎必然无解，而胖（欠定）方程组几乎必然有无穷多解，这正是最小二乘与最小范数形式的动因<sup>[13](https://scg.ece.ucsb.edu/publications/papers/CMA_2016.pdf)</sup>。秩本身是个脆弱的观念：元素的微小改变就可能大幅改变秩，而从连续分布中抽取的矩阵以概率一满秩<sup>[17](https://pressbooks.pub/linearalgebraandapplications/chapter/existence-and-unicity-of-solutions/)</sup>。

## 奇异性、病态与秩亏

最小奇异值恰好衡量一个矩阵有多奇异：s_n(A) 等于在谱范数下 A 到奇异矩阵集合的距离<sup>[8](https://www.math.uci.edu/~rvershyn/papers/rv-invertibility.pdf)</sup>。这给出了精确概念与近似概念之间关系的最简洁表述。就矩阵求逆而言，在分量意义下，对分量距离的任何加权，病态矩阵都离某个奇异矩阵不远；简言之，“病态”意味着在范数意义和分量意义下都“近乎不适定”<sup>[18](https://epubs.siam.org/doi/10.1137/S0036144598323216)</sup>。

求解 Ax = b 的标准条件数为 κ(A) = ‖A‖₂‖A⁻¹‖₂，并约定当 A 奇异时 κ(A) = ∞；对长方形矩阵，自然的推广是使用伪逆的 κ(A) = ‖A‖₂‖A†‖₂<sup>[19](https://ar5iv.labs.arxiv.org/html/2102.09739)</sup>。对取无穷大的约定存在质疑：一个满列秩的方程组若有巨大的有限 κ(A) = ‖A‖₂‖A†‖₂，用批评者的话说，“在实际意义上就是事实上的秩亏”，因此基于伪逆的有限值可能比无穷值承载更多信息<sup>[19](https://ar5iv.labs.arxiv.org/html/2102.09739)</sup>。

## 奇异矩阵出现在何处

**回归中的共线数据。** 对回归数据矩阵 X 作奇异值分解，能直接暴露其条件数以及列之间的任何线性相关，从而得以检测多重共线性并评估它对系数估计造成的损害<sup>[12](https://www.nber.org/system/files/working_papers/w0066/w0066.pdf)</sup>。

**运动学奇异。** 奇异性分析是机器人机械臂设计与控制中不可或缺的部分，关于串联与并联机械臂的文献十分丰富<sup>[20](https://www.cambridge.org/core/journals/robotica/article/abs/singularitytheoretic-methods-in-robot-kinematics/DE12E8A0106D5439167791917BDA7273)</sup>。形式上，运动学映射为 f : Q → G 的串联机械臂在构型 q 处有运动学奇异，是指切映射 T_q f 的秩同时小于 dim Q 和 dim G——这是该映射的雅可比型矩阵上的秩亏条件<sup>[21](https://homepages.ecs.vuw.ac.nz/foswiki/pub/Users/Donelan/WebHome/ksrm.pdf)</sup>。

**图的邻接矩阵。** 若图 G 的 0–1 邻接矩阵 A 的零空间维数为 η(G) ≥ 1，则称 G 奇异，零化度为 η(G)；已有用容许诱导子图给出的刻画<sup>[22](https://www.um.edu.mt/library/oar/bitstream/123456789/28287/1/ACharofSingGraphs_2007.pdf)</sup>。

## 处理奇异与接近奇异的方程组

有若干策略，视方程组奇异的程度选用：

- **带主元的分解。** 带部分主元的 LU 分解在运行时通过 INFO 标志检测恰好奇异<sup>[10](https://www.netlib.org/lapack/double/dgetrf.f)</sup>。
- **SVD 与伪逆。** 穆尔–彭罗斯（Moore–Penrose）伪逆 A⁺ 通过 SVD 计算，保留所有大的奇异值而将其余置零；它求解最小二乘问题 Ax = b，并在解不唯一时给出最小范数解。NumPy 的 slogdet 在行列式为零时返回符号 0 与 logabsdet −inf，这是在不溢出的前提下检验行列式的安全方式<sup>[5](https://github.com/numpy/numpy/blob/main/numpy/linalg/_linalg.py)</sup>。
- **运行时检测秩亏并回退。** 现代求解器可以在运行时检验数值秩亏，一旦检出，就回退到基于列主元 QR 或 SVD 的求解器，或回退到正则化最小二乘<sup>[23](https://arxiv.org/html/2406.03468v2)</sup>。
- **迭代法。** 对 GMRES 而言，A 的（接近）奇异可能影响、也可能不影响性能，取决于方程组的性质和初始近似解，因此仅凭接近奇异并不能预测迭代求解器会失败<sup>[24](https://epubs.siam.org/doi/10.1137/S0895479894262339)</sup>。

## 近期进展

随机数值线性代数已趋成熟，它与秩亏的相互作用已成为一个核心议题。

**随机求解器的稳定性。** 在浮点运算中，随机迭代最小二乘方法（略图与预条件、迭代略图、SPIR、FOSSILS）在数值秩亏的矩阵上——即 κ ≳ u⁻¹ 的矩阵，其中 u 是单位舍入误差——可能灾难性地失败：不加修改时，它们在全一矩阵上都会以 NaN 退出，豪斯霍尔德（Householder）QR 本身亦然<sup>[23](https://arxiv.org/html/2406.03468v2)</sup>。SPIR 与 FOSSILS 现在在运行时以 cond(Σ) 作为 κ 的代理来检验数值秩亏，一旦检出就回退到基于列主元 QR 或 SVD 的求解器，或正则化最小二乘<sup>[23](https://arxiv.org/html/2406.03468v2)</sup>。2025 年的一篇 PMLR 论文把迭代略图与略图与预条件重新表述为迭代精化的形式，并考察这些随机求解器对超定最小二乘问题的数值稳定性，向着后向稳定性迈进了一步<sup>[25](https://proceedings.mlr.press/v258/xu25a.html)</sup>。

**显秩工具。** CQRRPT（2024/2025）是一种针对高矩阵、带列主元的随机 QR 分解，配有显秩与稳定性分析，其 RandLAPACK 实现在 Intel Xeon Gold 6248R 上比 LAPACK 标准 QRCP 快了一个数量级<sup>[26](https://dl.acm.org/doi/abs/10.1137/24M163712X)</sup>。

**奇异矩阵束与 GPU 上的 SVD。** 2024 年的一项分析考察了把奇异矩阵束 A − λB 变换为正则矩阵束的随机方法，表明变换后矩阵束的特征值条件数不太可能远大于原矩阵束的 δ-弱条件数；这些方法需要精确的正规秩，而正规秩可由少数随机 ξᵢ ∈ ℂ 的 rank(A − ξᵢB) 确定<sup>[27](https://pmc.ncbi.nlm.nih.gov/articles/PMC11249782/)</sup>。在硬件方面，PPoPP 2026 提出的一种针对秩亏矩阵的 SVD 算法基于混合精度的显秩 QB 分解，相比 cuSOLVER 的完整 SVD 最高加速 6978.71 倍，相比 FP32 下的随机 SVD 加速 9.99 倍，且后向误差显著更小<sup>[28](https://ppopp26.sigplan.org/details/PPoPP-2026-papers/17/Towards-Singular-Value-Decomposition-for-Rank-Deficient-Matrices-An-Efficient-and-Accurate-Algorithm-on-GPU-Architectures)</sup>。

## References

1. [Detecting singularity — Notes on linear algebra and ODEs, Toby Driscoll, University of Delaware](https://tobydriscoll.net/udmath305/linalg/singular.html)
2. [Nonsingular Matrices, A First Course in Linear Algebra](https://linear.pugetsound.edu/390/section-NM.html)
3. [Singular matrices and the eigenvalue problem, ALAFF, UT Austin](https://www.cs.utexas.edu/~flame/laff/alaff/chapter09-singular-matrices-and-the-eigenvalue-problem.html)
4. [Condition Number of a Matrix, MATH 3510, University of Connecticut](https://www.phys.uconn.edu/~rozman/Courses/m3510_21f/downloads/condnumber.pdf)
5. [numpy/linalg/_linalg.py, NumPy source](https://github.com/numpy/numpy/blob/main/numpy/linalg/_linalg.py)
6. [What is the chance that a random matrix is singular? The DO Loop, SAS](https://blogs.sas.com/content/iml/2011/09/28/what-is-the-chance-that-a-random-matrix-is-singular.html)
7. [Sharp singularity asymptotics for discrete random matrices, arXiv](https://arxiv.org/html/2609.39463)
8. [Least singular value and condition number of a square random matrix with i.i.d. rows, Rudelson–Vershynin](https://www.math.uci.edu/~rvershyn/papers/rv-invertibility.pdf)
9. [Equivalent forms of Invertibility and Singularity of Matrices, University of Manitoba](https://linearalgebra.math.umanitoba.ca/math1220/section-25.html)
10. [LAPACK DGETRF source, Netlib](https://www.netlib.org/lapack/double/dgetrf.f)
11. [LAPACK DTPTRS documentation, Netlib](https://netlib.org/lapack/explore-html/d1/db6/group__tptrs_gaca2a67c006910a35d219248c83e58419.html)
12. [Detecting and assessing multicollinearity via the singular value decomposition, NBER Working Paper w0066](https://www.nber.org/system/files/working_papers/w0066/w0066.pdf)
13. [Core Matrix Analysis, UC Santa Barbara](https://scg.ece.ucsb.edu/publications/papers/CMA_2016.pdf)
14. [Singularity of Discrete Random Matrices, arXiv](https://ar5iv.labs.arxiv.org/html/2010.06554)
15. [Singularity of random symmetric matrices revisited, NSF Public Access](https://par.nsf.gov/biblio/10330634-singularity-random-symmetric-matrices-revisited)
16. [Invertibility of random matrices, Rudelson lecture notes](https://myria.math.aegean.gr/conferences/phdsamos2007/Talks/Rudelson.pdf)
17. [Existence and Unicity of Solutions, Linear Algebra and Applications, Pressbooks](https://pressbooks.pub/linearalgebraandapplications/chapter/existence-and-unicity-of-solutions/)
18. [Ill-Conditioned Matrices Are Componentwise Near to Singularity, SIAM Review](https://epubs.siam.org/doi/10.1137/S0036144598323216)
19. [On the Sensitivity of Singular and Ill-Conditioned Linear Systems, arXiv](https://ar5iv.labs.arxiv.org/html/2102.09739)
20. [Singularity-theoretic methods in robot kinematics, Robotica, Cambridge Core](https://www.cambridge.org/core/journals/robotica/article/abs/singularitytheoretic-methods-in-robot-kinematics/DE12E8A0106D5439167791917BDA7273)
21. [Kinematic Singularities of Robot Manipulators, Victoria University of Wellington](https://homepages.ecs.vuw.ac.nz/foswiki/pub/Users/Donelan/WebHome/ksrm.pdf)
22. [A Characterization of Singular Graphs, University of Malta](https://www.um.edu.mt/library/oar/bitstream/123456789/28287/1/ACharofSingGraphs_2007.pdf)
23. [Fast randomized least-squares solvers can be just as accurate and stable as classical direct solvers, arXiv](https://arxiv.org/html/2406.03468v2)
24. [GMRES On (Nearly) Singular Systems, SIAM J. Matrix Anal. Appl.](https://epubs.siam.org/doi/10.1137/S0895479894262339)
25. [Randomized Iterative Solver as Iterative Refinement, PMLR v258 (2025)](https://proceedings.mlr.press/v258/xu25a.html)
26. [CholeskyQR with Randomization and Pivoting for Tall Matrices (CQRRPT), SIMAX](https://dl.acm.org/doi/abs/10.1137/24M163712X)
27. [Analysis of eigenvalue condition numbers for randomized methods for singular matrix pencils (2024), PMC](https://pmc.ncbi.nlm.nih.gov/articles/PMC11249782/)
28. [Towards SVD for Rank-Deficient Matrices on GPU Architectures, PPoPP 2026](https://ppopp26.sigplan.org/details/PPoPP-2026-papers/17/Towards-Singular-Value-Decomposition-for-Rank-Deficient-Matrices-An-Efficient-and-Accurate-Algorithm-on-GPU-Architectures)

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

Topic: 物质世界与数学 › 数学与统计学 › 数与代数 › Linear and multilinear algebra › Matrix theory › Matrix operations and matrix algebra

Copyright 2026 Edgepedia

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

Source: https://www.edgepedia.org/zh/singular-matrix

English original: https://www.edgepedia.org/singular-matrix
