Courses / Mathematics I
Scientific Programming

Solving Linear Systems Numerically

Solving Ax = b powers simulations and data fitting with millions of unknowns.

Mathematics I 210 words Free to read

Linear Systems & Direct Methods

Solving Ax=bA\mathbf{x} = \mathbf{b} powers simulations and data fitting with millions of unknowns. Theory uses Gaussian elimination, reducing AA to triangular form before back-substitution.

The cost is about 23n3\frac{2}{3}n^3 operations for an n×nn \times n system. Because it is cubic, doubling nn multiplies the work eightfold. For huge sparse systems, iterative methods (Jacobi, Gauss-Seidel, conjugate gradient) refine guesses step-by-step instead.

Plain elimination fails on a zero pivot and amplifies round-off error on a small one. Partial pivoting swaps rows to place the largest available entry on the pivot, making the method numerically stable and safe for real-world use.

Conditioning & Pitfalls

Even stable solvers fail if a system is inherently fragile. The condition number of AA measures solution sensitivity to input errors.

System TypeCondition NumberGeometric MeaningRobustness
Well-conditionedSmallNearly perpendicularRobust to errors
Ill-conditionedLargeNearly parallel linesSwings wildly
Common pitfall: Blaming the algorithm when the problem is ill-conditioned. A large condition number means the solution is hyper-sensitive. Even a perfect solver cannot rescue imprecise data; error lives in the problem, not the method.
Solving Linear Systems Numerically

Practise this lesson

The explanation above is free to read. The graded practice for this lesson lives in the Tryals app.

11practice questions
2interactive scenes

Scientific Programming