Linear System Sensitivity & Error Calculator
Enter a real 2×2 system and bounds on uncertainty in its matrix and right-hand side. The calculator solves the system, reports its 2-norm condition number, and turns those input bounds into conservative error guidance.
Solution vector (x₁, x₂)x₁ = 1.4, x₂ = 3.4
- 2-norm condition number κ₂(A)
- 2.618034
- Reciprocal condition number
- 0.38
- First-order relative error bound
- 0.5236068%
- Finite perturbation error bound
- 0.52498122%
- Absolute solution error radius
- 0.019303324
- Decimal digits at risk
- 0.41797528
- Estimated usable significant digits
- 5
- Conditioning assessment
- Well-conditioned
Bounds are normwise worst-case estimates in the matrix 2-norm, not predictions of actual error.
A condition number near 1 means the system has little worst-case error amplification.
How to use this calculator
- Enter the four coefficients of A in row order and the two values in b for Ax = b.
- Enter normwise relative uncertainty bounds for the matrix and right-hand side as percentages.
- Enter the number of significant digits you believe the inputs contain.
- Read the solution first, then compare the first-order and finite bounds with the conditioning assessment.
What the condition number says about this system
For a 2×2 system Ax = b, this calculator first finds the nominal solution. With A = [[a₁₁, a₁₂], [a₂₁, a₂₂]], the determinant is D = a₁₁a₂₂ − a₁₂a₂₁. When D ≠ 0, the solution is x₁ = (b₁a₂₂ − a₁₂b₂) / D and x₂ = (a₁₁b₂ − b₁a₂₁) / D.
The 2-norm condition number is κ₂(A) = σmax / σmin, where the singular values describe how A stretches vectors. A value of 1 is best possible. Larger values mean a small relative change in the inputs can cause a much larger relative change in the solution. The calculator scales A before finding its singular values, which keeps the condition-number calculation more reliable when coefficients are very large or very small.
How the error bounds are calculated
Let εA = ‖ΔA‖₂ / ‖A‖₂ and εb = ‖Δb‖₂ / ‖b‖₂ be the uncertainty percentages converted to fractions. The first-order estimate is:
‖Δx‖₂ / ‖x‖₂ ≤ κ₂(A) × (εA + εb)
This is useful when perturbations are small. The finite perturbation result is more guarded:
‖Δx‖₂ / ‖x‖₂ ≤ [κ₂(A) / (1 − κ₂(A)εA)] × (εA + εb)
It is shown only when κ₂(A)εA < 1. Otherwise the entered matrix uncertainty is already large enough that this theorem cannot guarantee the perturbed matrix stays nonsingular. The absolute radius multiplies that finite relative bound by ‖x‖₂.
What moves the result and what it leaves out
Near-dependent rows or columns usually drive κ₂(A) up; a small determinant alone does not prove poor conditioning because the scale of the coefficients also matters. Matrix uncertainty matters especially strongly because it appears in the finite-bound denominator. The digits-at-risk display uses the rule of thumb log10(κ₂(A)), so it is an approximate loss of decimal precision, not a promise about a particular algorithm.
These are worst-case normwise bounds for real 2×2 systems. They do not model statistical confidence, correlations between errors, component-by-component tolerances, modeling error, or the stability of the software that will solve a larger system. A small actual residual does not by itself prove the solution is accurate when the system is ill-conditioned.
Worked example
With A = [[4, 1], [2, 3]] and b = [9, 13], the determinant is 10 and the solution is x = [1.4, 3.4]. The singular values give κ₂(A) ≈ 2.618, so this is well-conditioned rather than close to singular.
If both entered uncertainty bounds are 0.1%, the first-order relative bound is about 0.524%. The finite bound is about 0.525%, because 2.618 × 0.001 is below 1. Since ‖x‖₂ ≈ 3.677, the corresponding absolute solution error radius is about 0.0193 in the 2-norm.
Common questions
What does a matrix condition number mean in practice?
It measures the worst-case sensitivity of a linear-system solution to relative input changes in the selected norm. A condition number near 1 means little amplification; a large one means measurements, rounding, or residual errors can be amplified substantially in the solution.
Why can a system have a unique solution but still be unreliable?
A nonzero determinant gives a unique exact solution, but it does not say how far the matrix is from singular relative to its scale. If rows or columns are nearly dependent, a tiny change in the entered values can move that unique solution by a large amount.
What is the difference between the first-order and finite perturbation bounds?
The first-order bound keeps only the leading sensitivity terms and is most informative for small perturbations. The finite bound adds a denominator that accounts for matrix perturbation more cautiously, but it is valid only when κ₂(A)εA is less than 1.
How should I estimate uncertainty in A and b?
Use defensible bounds on the 2-norm of the total error relative to the 2-norm of each input, including instrument tolerance, rounding, and transcription where relevant. Do not treat the percentages as probabilities or standard deviations unless you have separately converted a statistical model into a conservative bound.
Why is a small determinant not enough to prove poor conditioning?
The determinant changes when the whole matrix is rescaled, while the condition number does not. Conditioning compares the largest and smallest singular directions, so it captures relative closeness to singularity rather than determinant size alone.