Lecture 05: Solving triangular systems#
A general lower triangular system of equations has \(a_{ij} = 0\) for \(j > i\) and takes the form:
Note the first equation is
The \(x_i\) can be found by calculating
for each row \(i = 1, 2, \ldots, n\) in turn.
Each calculation requires only previously computed values \(x_j\) (and the sum gives a loop for \(j < i\).
The matrix \(A\) must have nonzero diagonal entries
i.e. \(a_{ii} \neq 0\) for \(i = 1, 2, \ldots, n\).Upper triangular systems of equations can be solved in a similar manner.
Example 1#
Solve the lower triangular system of equations given by
or, equivalently,
Example 1: solution#
The solution can be calculated systematically from
which gives the solution \(\vec{x} = (1, 3, 2)^T\).
Example 2 (homework)#
Solve the upper triangular linear system given by
Notes#
It is simple to solve a lower (upper) triangular system of equations (provided the diagonal is nonzero).
This process is often referred to as forward (backward) substitution.
A general system of equations (i.e. a full matrix \(A\)) can be solved rapidly once it has been reduced to upper triangular form.
This will be the topic of the next section…
Further reading#
Wikipedia: Triangular matrix