Skip to main content
Mathematics LibreTexts

29.2: Diagonalizable Matrix

  • Page ID
    69445
  • \( \newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \) \( \newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}} \)\(\newcommand{\id}{\mathrm{id}}\) \( \newcommand{\Span}{\mathrm{span}}\) \( \newcommand{\kernel}{\mathrm{null}\,}\) \( \newcommand{\range}{\mathrm{range}\,}\) \( \newcommand{\RealPart}{\mathrm{Re}}\) \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\) \( \newcommand{\Argument}{\mathrm{Arg}}\) \( \newcommand{\norm}[1]{\| #1 \|}\) \( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\) \( \newcommand{\Span}{\mathrm{span}}\) \(\newcommand{\id}{\mathrm{id}}\) \( \newcommand{\Span}{\mathrm{span}}\) \( \newcommand{\kernel}{\mathrm{null}\,}\) \( \newcommand{\range}{\mathrm{range}\,}\) \( \newcommand{\RealPart}{\mathrm{Re}}\) \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\) \( \newcommand{\Argument}{\mathrm{Arg}}\) \( \newcommand{\norm}[1]{\| #1 \|}\) \( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\) \( \newcommand{\Span}{\mathrm{span}}\)\(\newcommand{\AA}{\unicode[.8,0]{x212B}}\)

    In class we will be using matrix diagonalization to solve some problems.

    Matrix \(A\) is diagonalizable if there exists a diagonal matrix \(D\) that is similar similar to \(A\):

    \[ D = C^{-1}AC \nonumber \]

    If matrix \(A\) has linearly independent eigenvectors (\(v_1, \ldots, v_n\)) then \(A\) is diagonalizable with the following solution:

    \[C = \left[ v_1^T, \ldots, v_n^T \right] \nonumber \]

    In other words, each column of \(C\) is a linearly independent eigenvector of \(A\). The diagonal matrix \(D\) is

    \[\begin{split} D =
    \left[
    \begin{matrix}
    \lambda_1 & 0 & 0 \\
    0 & \ddots & 0 \\
    0 & 0 & \lambda_n
    \end{matrix}
    \right]
    \end{split} \nonumber \]

    In other-other words, \(D\) consists of the corresponding eigenvalues.

    %matplotlib inline
    import matplotlib.pylab as plt
    import numpy as np
    import sympy as sym
    from urllib.request import urlretrieve
    
    urlretrieve('https://raw.githubusercontent.com/colbrydi/jupytercheck/master/answercheck.py', 
                'answercheck.py');
    sym.init_printing(use_unicode=True)
    Do This

    Using numpy, Diagonalize (i.e. calculate \(C\) and \(D\)) the following matrix:

    A = np.matrix([[5, -2, 2], [4, -3, 4], [4,-6,7]])
    sym.Matrix(A)
    # Put your answer here
    from answercheck import checkanswer
    
    checkanswer.matrix(D,'56821475223b52e0b6e751da444a1441');
    Do This

    Verify that \(A\) is in fact Diagonalizable by calculating \(D2 = C^{-1} AC\) and comparing it to your original \(D\) using np.allclose.

    #Put your verificaiton code here.
    np.allclose(D,D2)

    Diagonalization of Symmetric Matrices

    One special case is Symmetric Matrices. It can be shown that symmetric Matrices are Diagonalizable and the resulting eigenvectors are not only linearly independent but also orthogonal. Since this is true, the equation changes to:

    \[ D = C^{T}AC \nonumber \]

    Question

    Why do we care if \(C\) is orthogonal? What advantages does the above equation give us?


    This page titled 29.2: Diagonalizable Matrix is shared under a CC BY-NC 4.0 license and was authored, remixed, and/or curated by Dirk Colbry via source content that was edited to the style and standards of the LibreTexts platform; a detailed edit history is available upon request.