shaoeChen
    • Create new note
    • Create a note from template
      • Sharing URL Link copied
      • /edit
      • View mode
        • Edit mode
        • View mode
        • Book mode
        • Slide mode
        Edit mode View mode Book mode Slide mode
      • Customize slides
      • Note Permission
      • Read
        • Only me
        • Signed-in users
        • Everyone
        Only me Signed-in users Everyone
      • Write
        • Only me
        • Signed-in users
        • Everyone
        Only me Signed-in users Everyone
    • Invite by email
      Invitee

      This note has no invitees

    • Publish Note

      Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note No publishing access yet

      Your note will be visible on your profile and discoverable by anyone.
      Your note is now live.
      This note is visible on your profile and discoverable online.
      Everyone on the web can find and read all notes of this public team.

      Your account was recently created. Publishing will be available soon, allowing you to share notes on your public page and in search results.

      Your team account was recently created. Publishing will be available soon, allowing you to share notes on your public page and in search results.

      Explore these features while you wait
      Complete general settings
      Bookmark and like published notes
      Write a few more notes
      Complete general settings
      Write a few more notes
      See published notes
      Unpublish note
      Please check the box to agree to the Community Guidelines.
      View profile
    • Commenting
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
      • Everyone
    • Suggest edit
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
    • Emoji Reply
    • Enable
    • Versions and GitHub Sync
    • Note settings
    • Note Insights New
    • Make a copy
    • Transfer ownership
    • Delete this note
    • Save as template
    • Insert from template
    • Import from
      • Dropbox
      • Google Drive
      • Gist
      • Clipboard
    • Export to
      • Dropbox
      • Google Drive
      • Gist
    • Download
      • Markdown
      • HTML
      • Raw HTML
Menu Note settings Note Insights Versions and GitHub Sync Sharing URL Create Help
Create Create new note Create a note from template
Menu
Options
Make a copy Transfer ownership Delete this note
Import from
Dropbox Google Drive Gist Clipboard
Export to
Dropbox Google Drive Gist
Download
Markdown HTML Raw HTML
Back
Sharing URL Link copied
/edit
View mode
  • Edit mode
  • View mode
  • Book mode
  • Slide mode
Edit mode View mode Book mode Slide mode
Customize slides
Note Permission
Read
Only me
  • Only me
  • Signed-in users
  • Everyone
Only me Signed-in users Everyone
Write
Only me
  • Only me
  • Signed-in users
  • Everyone
Only me Signed-in users Everyone
  • Invite by email
    Invitee

    This note has no invitees

  • Publish Note

    Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note No publishing access yet

    Your note will be visible on your profile and discoverable by anyone.
    Your note is now live.
    This note is visible on your profile and discoverable online.
    Everyone on the web can find and read all notes of this public team.

    Your account was recently created. Publishing will be available soon, allowing you to share notes on your public page and in search results.

    Your team account was recently created. Publishing will be available soon, allowing you to share notes on your public page and in search results.

    Explore these features while you wait
    Complete general settings
    Bookmark and like published notes
    Write a few more notes
    Complete general settings
    Write a few more notes
    See published notes
    Unpublish note
    Please check the box to agree to the Community Guidelines.
    View profile
    Engagement control
    Commenting
    Permission
    Disabled Forbidden Owners Signed-in users Everyone
    Enable
    Permission
    • Forbidden
    • Owners
    • Signed-in users
    • Everyone
    Suggest edit
    Permission
    Disabled Forbidden Owners Signed-in users Everyone
    Enable
    Permission
    • Forbidden
    • Owners
    • Signed-in users
    Emoji Reply
    Enable
    Import from Dropbox Google Drive Gist Clipboard
       Owned this note    Owned this note      
    Published Linked with GitHub
    1
    • Any changes
      Be notified of any changes
    • Mention me
      Be notified of mention me
    • Unsubscribe
    # 李宏毅_Linear Algebra Lecture 35: General Vectors (Part II) ###### tags: `Hung-yi Lee` `NTU` `Linear Algebra Lecture` [課程撥放清單](https://www.youtube.com/playlist?list=PLJV_el3uVTsNmr39gwbyV-0KjULUsN7fW) ## Linear Algebra Lecture 35: General Vectors (Part II) [課程連結](https://www.youtube.com/watch?v=7E7ZzTJFeng&list=PLJV_el3uVTsNmr39gwbyV-0KjULUsN7fW&index=36) ### Vector Representation of Object ![](https://i.imgur.com/67CvlTe.png) 廣義的vector space上,一樣可以有不同的coordinate system之間的轉換。 ### Matrix Representation of Linear Operator ![](https://i.imgur.com/Z4O0qAu.png) 如果我們可以不同的coordinate system來看到一個function,那這個function就可以變的比較簡單。先前的課程就提過,同一個linear operator在不同的coordinate system下看起來就是不一樣,以微分為例: * 微分如課程中所提,它是function的function,以polynomial為例,input為polynomial,output也會是polynomial。我們想知道,這個linear operator是長什麼樣子的,這只需要丟入一個stnadard vector,看它的output就可以知道,丟入$e_i$就可以知道第$i$個column的樣子 * 每個polynomial都可以視為vector,因此將input與ouput的polynomial以vector來表示,即input-$\begin{bmatrix}2\\-3\\5 \end{bmatrix}$、ouput-$\begin{bmatrix}-3\\10\\0 \end{bmatrix}$,這樣我們就只需要找出什麼樣的matrix會讓它們有這樣的轉換即可 ### Matrix Representation of Linear Operator ![](https://i.imgur.com/PI6gmwU.png) 我們分別輸入三個standard vector: * $\begin{bmatrix}1\\0\\0 \end{bmatrix}$,常數微分之後為0,因此得到$\begin{bmatrix}0\\0\\0 \end{bmatrix}$ * $\begin{bmatrix}0\\1\\0 \end{bmatrix}$,$x$微分之後為1,因此得到$\begin{bmatrix}1\\0\\0 \end{bmatrix}$ * $\begin{bmatrix}0\\0\\1 \end{bmatrix}$,$x^2$微分之後為$2x$,因此得到$\begin{bmatrix}0\\2\\0 \end{bmatrix}$ 這三個vector組合起來就是這個微分背後所代表的matrix ### Matrix Representation of Linear Operator ![](https://i.imgur.com/hvLmNvP.png) 這邊給出一個範例,很直觀。其中值得注意的是,這個代表微分的matrix是一個non-invertible的matrix,這也意味著polynomial微分這個行為是non-invertible。 ### Matrix Representation of Linear Operator ![](https://i.imgur.com/PkQBnec.png) 這範例一樣是微分,但並非在polynomial上,而是某一個function set-F,其basis為$\left\{ e^t \text{ cos } t, e^t \text{ sin } t \right\}$,找出其微分所代表的matrix: * 輸入standard vector-$\begin{bmatrix}1 \\ 0\end{bmatrix}$,依兩個相乘做微分的公式,左微乘右加右微乘左,因此$e^t \text{ cos} t$微分之後得到$(1)e^t \text{ cos }t + (-1)e^t \text{ sin } t$,我們發現得到的結果是1倍的F的第1個column 加上-1倍F的第2個column,我們得到$\begin{bmatrix}1 \\ -1\end{bmatrix}$ * 輸入standard vector-$\begin{bmatrix}0 \\ 1\end{bmatrix}$,依兩個相乘做微分的公式,左微乘右加右微乘左,因此$e^t \text{ cos} t$微分之後得到$(1)e^t \text{ cos }t + (-)e^t \text{ sin } t$,,我們發現得到的結果是1倍的F的第1個column 加上1倍F的第2個column,我們得到$\begin{bmatrix}1 \\ 1\end{bmatrix}$ * 得到背後代表的matrix-$\begin{bmatrix}1& 1 \\ -1 & 1\end{bmatrix}$,而且做完RREF之後會發現,這個matrix是invertible,這意味著這個function set-F在微分之後是一個一對一的關聯 ### Matrix Representation of Linear Operator ![](https://i.imgur.com/zUrldRD.png) 這個範例說明,即使你不知道什麼是Antiderivative(反導數),也不知道怎麼求出Antiderivative,但只要你知道那個背後的matrix,就能知道該matrix的inverse(兩者相乘為identity matrix),有了這個inverse的matrix,你就可以直接計算它的Antiderivative。 舉例來說,F的basis為$\left\{e^t \text{cos} t, e^t \text{sin} t \right\}$,求$e^t \text{sin} t$的Antiderivative: * $e^t \text{sin} t$的輸入向量為$\begin{bmatrix}0 \\ 1 \end{bmatrix}$,微分的matrix為$\begin{bmatrix}1 & 1 \\ -1 & 1 \end{bmatrix}$,其inverse為$\begin{bmatrix}1/2 & -1/2 \\ 1/2 & 1/2 \end{bmatrix}$,輸出向量為$\begin{bmatrix}-1/2\\ 1/2 \end{bmatrix}$,意味著Antiderivative為$(-\dfrac{1}{2})e^t \text{cos} t + (\dfrac{1}{2})e^t \text{sin} t$ ### Eigenvalue and Eigenvector ![](https://i.imgur.com/yjXL0qV.png) 與先前的課程一樣,先複習。 $T(v) = \lambda v, v \neq 0$,其中$v$是eigenvector,$\lambda$為eigenvalue ### Eigenvalue and Eigenvector ![](https://i.imgur.com/xnZMnGi.png) 考慮function的eigenvector有什麼樣的組成: * 微分為例,微分為一個linear operator,輸出、入皆為function,那$f(t) = e^{at}$是否為該function的eigenvector?那它的eigenvalue為何? * 它是一個eigenvector,其eigenvalue為$a$,這意味著任何的實數都可以是eigenvalue,因為$a$可以是任意實數 * Transpose為例,Transpose為一個linear opeator,有什麼樣的範例可以表示? * 以Symmetric matrix(對稱矩陣)為例,$A^T=A$,其eigenvalue=1 * Skew-symmetric matrix(扭曲的對稱矩陣),$A^T=-A$其eigenvalue=-1 ### Consider Transpose of 2x2 matrices ![](https://i.imgur.com/BYEJIGb.png) 案例假設是一個2x2的matrices transpose到另一個2x2 matrice: * 將matrix轉為vector,輸入$e_1$,也就是$\begin{bmatrix}1 & 0 \\ 0 & 0 \end{bmatrix} \to \begin{bmatrix}1 \\0 \\0 \\ 0 \end{bmatrix}$,這經過transpose還會是$\begin{bmatrix}1 \\0 \\0 \\ 0 \end{bmatrix}$ * 將matrix轉為vector,輸入$e_2$,也就是$\begin{bmatrix}0 & 1 \\ 0 & 0 \end{bmatrix} \to \begin{bmatrix}0 \\1 \\0 \\ 0 \end{bmatrix}$,這經過transpose會是$\begin{bmatrix}0 \\0 \\1 \\ 0 \end{bmatrix}$ * 將matrix轉為vector,輸入$e_3$,也就是$\begin{bmatrix}0 & 0 \\ 1 & 0 \end{bmatrix} \to \begin{bmatrix}0 \\0 \\1 \\ 0 \end{bmatrix}$,這經過transpose會是$\begin{bmatrix}0 \\1 \\0 \\ 0 \end{bmatrix}$ * 將matrix轉為vector,輸入$e_4$,也就是$\begin{bmatrix}0 & 0 \\ 0 & 1 \end{bmatrix} \to \begin{bmatrix}0 \\0 \\0 \\ 1 \end{bmatrix}$,這經過transpose會是$\begin{bmatrix}0 \\0 \\0 \\ 1 \end{bmatrix}$ 把上面四個vector集合起來得到的就是這背後所代表的matrix,而你只需要交換row2、row3就可以輕易發現,這個matrix是inverable。 ### Eigenvalue and Eigenvector ![](https://i.imgur.com/Ub0XUGH.png) 有了剛剛的matrix,我們可以展開它的characteristic polynomial,就可以找出它的eigenvalue、eigenvector: * 對角線減$t$,計算它的determinant,得到$(t-1)^3(t+1)$,也就得到eigenvalue為1、-1 * $\lambda=1$,對應的就是symmetric matrices,其dimension一定小於等於其對應的degree,因此為3 * $\lambda=-1$,對應的就是skew-symmetric matrices,其dimension一定小於等於其應對的degree,因此為1 ### Inner Product ![](https://i.imgur.com/tz4XE0C.png) 把inner product想成一個operator,它的input是兩個廣義的vector(matrix, function),然後再輸出一個scalar,而廣義的inner product必須符合幾個條件,假設你有$u, v, w$等三個廣義的vector,以及一個scalar_a: 1. 假設$u \neq 0$,那$\langle u, u \rangle >0$ 2. $\langle u, v \rangle = \langle v, u \rangle$ 3. $\langle u + v, w \rangle = \langle u, w \rangle + \langle v, w \rangle$ 4. $\langle au, v \rangle = a \langle u, v \rangle$ ### Inner Product ![](https://i.imgur.com/OQ6gStU.png) 有一種稱為Frobenius inner product:$\langle A, B \rangle = trace(AB^T) = trace(BA^T)$,其中trace為斜對角線值的和,那其實它計算的就是兩兩元素相乘之和,可見上範例。又或者你可以把矩陣轉向量之後做inner product也是可以。 矩陣本身也可以計算其長度,只要計算它的Norm,也就是自己跟自己的Frobenius inner product。 ### Inner Product ![](https://i.imgur.com/AcRlCw0.png) Inner Product也可以定義在function上面: * $\langle g, h \rangle = \int^1_{-1} g(x)h(x)dx$ * 兩個函數相乘,從-1積分到1,因此,$g, h$的輸入範圍是落於-1~1之間 * 當$g(x)=1$且$h(x) = x$,那$g, h$為orthogonal 但如果是$\langle g, h \rangle = \sum^10_{-1-} g(i/10)h(i/10)$就不符合inner product的條件。 ### Orthogonal/Orthonormal Basis ![](https://i.imgur.com/xdZ2aMd.png) 上面快速的複習課程提過的Orthogonal/Orthonormal,值得注意的是,$u \cdot v_i$可以以inner product來取代 ### Orthogonal Basis ![](https://i.imgur.com/zfiOlDY.png) 這邊說明的是,可以利用Gram-Schmidt Process將vector set轉為orthogonal basis,一樣的,如果是應用在general case上,那就可以直接將dot product轉為inner product。 ### Orthogonal/Orthonormal Basis ![](https://i.imgur.com/9NZ2FGm.png) 對於degree小於等於2的所有polynomial_$P_2$,其basis為$\left\{1, x, x^2\right\$,並且輸入範圍為-1~1之間的數值: * 定義$P_2$的inner product,也就是將兩個函數相乘取-1~1的積分,即$\langle f(x), g(x) rangle = \int^1_{-1} f(t)g(t)dt$ * 其basis_$\left\{1, x, x^2\right\$($u_1, u_2, u_3$)不為orthogonal basis * 套用Gram-Schmide將其轉為orthogonal basis * $v_1 = u_1 = 1$ * $v_2 = u_2 - \dfrac{\langle u_2, v_1 \rangle}{\Vert v_1 \Vert^2}v_1 = x - \dfrac{\int^1_{-1} t \cdot 1 dt}{\int^1_{-1} 1^2 dt}(1) = x - 0 cdot 1 = x$(因為$x$與1原本就是orthogonal,因此得到$x$) * $v_3 = x^2 - \dfrac{1}{3}$ * 得到orthogonal basis,即$1, x, x^2 - \dfrac{1}{3}$ ### Orthogonal/Orthonormal Basis ![](https://i.imgur.com/b4uGdsi.png) 對剛才得到的orthogonal basis的長度做正規化,得到orthonormal basis ### Orthogonal/Orthonormal Basis ![](https://i.imgur.com/MtRnxxc.png) orthonormal basis劃出來,得到上圖

    Import from clipboard

    Paste your markdown or webpage here...

    Advanced permission required

    Your current role can only read. Ask the system administrator to acquire write and comment permission.

    This team is disabled

    Sorry, this team is disabled. You can't edit this note.

    This note is locked

    Sorry, only owner can edit this note.

    Reach the limit

    Sorry, you've reached the max length this note can be.
    Please reduce the content or divide it to more notes, thank you!

    Import from Gist

    Import from Snippet

    or

    Export to Snippet

    Are you sure?

    Do you really want to delete this note?
    All users will lose their connection.

    Create a note from template

    Create a note from template

    Oops...
    This template has been removed or transferred.
    Upgrade
    All
    • All
    • Team
    No template.

    Create a template

    Upgrade

    Delete template

    Do you really want to delete this template?
    Turn this template into a regular note and keep its content, versions, and comments.

    This page need refresh

    You have an incompatible client version.
    Refresh to update.
    New version available!
    See releases notes here
    Refresh to enjoy new features.
    Your user state has changed.
    Refresh to load new user state.

    Sign in

    Forgot password
    or
    Sign in via Google Sign in via Facebook Sign in via X(Twitter) Sign in via GitHub Sign in via Dropbox Sign in with Wallet
    Wallet ( )
    Connect another wallet

    New to HackMD? Sign up

    By signing in, you agree to our terms of service.

    Help

    • English
    • 中文
    • Français
    • Deutsch
    • 日本語
    • Español
    • Català
    • Ελληνικά
    • Português
    • italiano
    • Türkçe
    • Русский
    • Nederlands
    • hrvatski jezik
    • język polski
    • Українська
    • हिन्दी
    • svenska
    • Esperanto
    • dansk

    Documents

    Help & Tutorial

    How to use Book mode

    Slide Example

    API Docs

    Edit in VSCode

    Install browser extension

    Contacts

    Feedback

    Discord

    Send us email

    Resources

    Releases

    Pricing

    Blog

    Policy

    Terms

    Privacy

    Cheatsheet

    Syntax Example Reference
    # Header Header 基本排版
    - Unordered List
    • Unordered List
    1. Ordered List
    1. Ordered List
    - [ ] Todo List
    • Todo List
    > Blockquote
    Blockquote
    **Bold font** Bold font
    *Italics font* Italics font
    ~~Strikethrough~~ Strikethrough
    19^th^ 19th
    H~2~O H2O
    ++Inserted text++ Inserted text
    ==Marked text== Marked text
    [link text](https:// "title") Link
    ![image alt](https:// "title") Image
    `Code` Code 在筆記中貼入程式碼
    ```javascript
    var i = 0;
    ```
    var i = 0;
    :smile: :smile: Emoji list
    {%youtube youtube_id %} Externals
    $L^aT_eX$ LaTeX
    :::info
    This is a alert area.
    :::

    This is a alert area.

    Versions and GitHub Sync
    Get Full History Access

    • Edit version name
    • Delete

    revision author avatar     named on  

    More Less

    Note content is identical to the latest version.
    Compare
      Choose a version
      No search result
      Version not found
    Sign in to link this note to GitHub
    Learn more
    This note is not linked with GitHub
     

    Feedback

    Submission failed, please try again

    Thanks for your support.

    On a scale of 0-10, how likely is it that you would recommend HackMD to your friends, family or business associates?

    Please give us some advice and help us improve HackMD.

     

    Thanks for your feedback

    Remove version name

    Do you want to remove this version name and description?

    Transfer ownership

    Transfer to
      Warning: is a public team. If you transfer note to this team, everyone on the web can find and read this note.

        Link with GitHub

        Please authorize HackMD on GitHub
        • Please sign in to GitHub and install the HackMD app on your GitHub repo.
        • HackMD links with GitHub through a GitHub App. You can choose which repo to install our App.
        Learn more  Sign in to GitHub

        Push the note to GitHub Push to GitHub Pull a file from GitHub

          Authorize again
         

        Choose which file to push to

        Select repo
        Refresh Authorize more repos
        Select branch
        Select file
        Select branch
        Choose version(s) to push
        • Save a new version and push
        • Choose from existing versions
        Include title and tags
        Available push count

        Pull from GitHub

         
        File from GitHub
        File from HackMD

        GitHub Link Settings

        File linked

        Linked by
        File path
        Last synced branch
        Available push count

        Danger Zone

        Unlink
        You will no longer receive notification when GitHub file changes after unlink.

        Syncing

        Push failed

        Push successfully