For each of the following, factor the matrix $A$ into a product $XDX^{-1}$ where $D$ is diagonal.

(a) $A = \left[\begin{array}{ccc} 8 &-7 &3\cr -4 &-4 &4\cr 0 &0 &-1 \end{array}\right]$

$X=$
 $\left.\vphantom{\begin{array}{c}\!\strut\\\!\strut\\\!\strut\\\!\strut\\\end{array}}\right[$ $\left.\vphantom{\begin{array}{c}\!\strut\\\!\strut\\\!\strut\\\!\strut\\\end{array}}\right]$
$\qquad D=$
 $\left.\vphantom{\begin{array}{c}\!\strut\\\!\strut\\\!\strut\\\!\strut\\\end{array}}\right[$ 0 0 $\left.\vphantom{\begin{array}{c}\!\strut\\\!\strut\\\!\strut\\\!\strut\\\end{array}}\right]$ 0 0 0 0

(b) $A = \left[\begin{array}{ccc} 0 &0 &0\cr -2 &-4 &2\cr 3 &6 &-3 \end{array}\right]$

$X=$
 $\left.\vphantom{\begin{array}{c}\!\strut\\\!\strut\\\!\strut\\\!\strut\\\end{array}}\right[$ $\left.\vphantom{\begin{array}{c}\!\strut\\\!\strut\\\!\strut\\\!\strut\\\end{array}}\right]$
$\qquad D=$
 $\left.\vphantom{\begin{array}{c}\!\strut\\\!\strut\\\!\strut\\\!\strut\\\end{array}}\right[$ 0 0 $\left.\vphantom{\begin{array}{c}\!\strut\\\!\strut\\\!\strut\\\!\strut\\\end{array}}\right]$ 0 0 0 0

You can earn partial credit on this problem.