Skip to main content
Mathematics LibreTexts

23.3: Change of Basis

  • Page ID
    68052
  • \( \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}}\)

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

    Now consider the following two bases in \(R^2\):

    \[B_1 = \{(1,2), (3,-1)\} \nonumber \]

    \[B_2 = \{(3,1), (5,2)\} \nonumber \]

    The transformation from the “standard basis” to \(B_1\) and \(B_2\) can be defined as the column vectors \(P_1\) and \(P_2\) as follows:

    B1 = np.matrix([[1,2],[3,-1]]).T
    P1 = np.linalg.inv(B1)
    
    sym.Matrix(P1)
    B2 = np.matrix([[3,1],[5,2]]).T
    P2 = np.linalg.inv(B2)
    
    sym.Matrix(P2)
    Do This

    Find the transition matrix \(T\) that will take points in the \(B_1\) coordinate representation and put them into \(B_2\) coordinates.

    NOTE this is analogous to the robot kinematics problem. We want to represent points in a different coordinate system.

    # Put your answer to the above question here.
    from answercheck import checkanswer
    
    checkanswer.matrix(T,'dcc03ddff982e29eea6dd52ec9088986')
    Question

    Given \(u_{B_1} = \left[ \begin{matrix} 2 \\ 1 \end{matrix} \right]\) (a point named \(u\) in the \(B_1\) coordinate system) and your calculated transition matrix \(T\), what is the same point expressed in the \(B_2\) basis (i.e. what is \(u_{B2}\))? Store your answer in a variable named ub2 for checking.

    ub1 = np.matrix([[2],[1]])
    sym.Matrix(ub1)
    ##Put your code here
    from answercheck import checkanswer
    
    checkanswer.vector(ub2,'9a5fe29254c07cf59ebdffcaba679917')

    There are three bases \(B_1\), \(B_2\), and \(B_3\). We have the transition matrix \(P_{12}\) from \(B_1\) to \(B_2\) and the transition matrix \(P_{23}\) from \(B_2\) to \(B_3\). In \(R^n\), we can compute the transition matrix as \(P_{12}=B_2^{-1}B_1,\quad P_{23}=B_3^{-1}B_2\).

    Then we can find all other transition matrices.

    \(P_{13} = B_3^{-1}B_1=B_3^{-1}B_2*B_2^{-1}B_1= P_{23}P_{12}\)

    \(P_{21} = B_1^{-1}B_2 = (B_2^{-1}B_1)^{-1}=P_{12}^{-1}\)

    \(P_{32} = B_2^{-1}B_3 = (B_3^{-1}B_2)^{-1}=P_{23}^{-1}\)

    \(P_{31} = B_1^{-1}B_3 = (B_3^{-1}B_1)^{-1}=P_{13}^{-1}=(P_{23}P_{12})^{-1}=P_{12}^{-1}P_{23}^{-1}\)

    The result is true for general vector spaces and can be extended to many bases.


    This page titled 23.3: Change of Basis 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.

    • Was this article helpful?