本文主要是介绍矩阵的迹的性质,希望对大家解决编程问题提供一定的参考价值,需要的开发者们随着小编来一起学习吧!
1. 定义
矩阵的迹(trace
)即对角线的和
t r ( M ) = ∑ i M i i tr(M)=\sum_{i}M_{ii} tr(M)=i∑Mii
2. 性质
t r ( I n ) = n t r ( A ⊤ ) = t r ( A ) t r ( α A ) = α t r ( A ) t r ( A + B ) = t r ( A ) + t r ( B ) t r ( A B ) = t r ( B A ) \begin{align} &tr(I_n)=n\\ &tr(A^{\top})=tr(A)\\ & tr(\alpha A)=\alpha \ tr(A)\\ & tr(A+B) =tr(A) +tr(B)\\ & tr(AB) = tr(BA)\\ \end{align} tr(In)=ntr(A⊤)=tr(A)tr(αA)=α tr(A)tr(A+B)=tr(A)+tr(B)tr(AB)=tr(BA)
l e t A 1 , A 2 , ⋯ A k : M a t r i x ( n , n ) t r ( A 1 A 2 ⋯ A k ) = t r ( A 2 ⋯ A k A 1 ) i f A X = X Λ , A = X Λ X − 1 → t r ( A ) = t r ( X Λ X − 1 ) = t r ( Λ X X − 1 ) = t r ( Λ ) let A_1, A_2, \cdots A_k:Matrix(n,n)\\ \begin{align} &tr(A_1A_2\cdots A_k)=tr(A_2\cdots A_k A_1) \\ if\ AX=X\Lambda ,A=X\Lambda X^{-1} \rightarrow \nonumber\\ tr(A)=tr(X\Lambda X^{-1})=tr(\Lambda XX^{-1})=tr(\Lambda) \end{align} letA1,A2,⋯Ak:Matrix(n,n)if AX=XΛ,A=XΛX−1→tr(A)=tr(XΛX−1)=tr(ΛXX−1)=tr(Λ)tr(A1A2⋯Ak)=tr(A2⋯AkA1)
性质 5 5 5证明
t r ( A B ) = ∑ i = 1 n ∑ k = 1 n a i k b k i t r ( B A ) = ∑ u = 1 n ∑ v = 1 n b u v a v u 求和项数均为 n × n , 对于任一项 a i k b k i 都能找到 b u v a v u 与之对应。 所以 t r ( A B ) = t r ( B A ) tr(AB) = \sum_{i=1}^n\sum_{k=1}^n a_{ik}b_{ki}\\ tr(BA) = \sum_{u=1}^n\sum_{v=1}^n b_{uv}a_{vu}\\ 求和项数均为 n \times n, 对于任一项a_{ik}b_{ki}都能找到b_{uv}a_{vu}与之对应。\\ 所以tr(AB)=tr(BA) tr(AB)=i=1∑nk=1∑naikbkitr(BA)=u=1∑nv=1∑nbuvavu求和项数均为n×n,对于任一项aikbki都能找到buvavu与之对应。所以tr(AB)=tr(BA)
性质 6 6 6证明
数学归纳法 k = 2 , t r ( A 1 A 2 ) = t r ( A 2 A 1 ) 成立 假设 k 时成立 令 B = A 2 ⋯ A k + 1 t r ( A 1 ⋯ A k + 1 ) = t r ( A 1 ( A 2 ⋯ A k + 1 ) ) = t r ( A 1 B ) = t r ( B A 1 ) = t r ( A 2 ⋯ A k + 1 A 1 ) 数学归纳法\\ k=2, tr(A_1A_2) = tr(A_2A_1)成立\\ 假设k时成立\\ 令B=A_2\cdots A_{k+1}\\ tr(A_1\cdots A_{k+1}) = tr(A_1(A_2\cdots A_{k+1}))=tr(A_1B)=tr(BA_1)\\=tr(A_2\cdots A_{k+1}A_1) 数学归纳法k=2,tr(A1A2)=tr(A2A1)成立假设k时成立令B=A2⋯Ak+1tr(A1⋯Ak+1)=tr(A1(A2⋯Ak+1))=tr(A1B)=tr(BA1)=tr(A2⋯Ak+1A1)
3. 叉乘矩阵
叉乘的矩阵形式,又叫dual matrix
。
向量叉乘
a → × b → = [ i → j → k → x a y a z a x b y b z b ] = ( y a z b − y b z a , x b z a − x a z b , x a y b − x b y a ) \overrightarrow a \times \overrightarrow b= \begin{bmatrix} \overrightarrow i & \overrightarrow j & \overrightarrow k\\ x_a & y_a & z_a\\ x_b & y_b & z_b\\ \end{bmatrix}=(y_az_b-y_bz_a, x_bz_a-x_az_b,x_ay_b-x_by_a) a×b= ixaxbjyaybkzazb =(yazb−ybza,xbza−xazb,xayb−xbya)
a → × b → = [ 0 z a − y a − z a 0 x a y a − x a 0 ] [ x b y b z b ] \overrightarrow a \times \overrightarrow b= \begin{bmatrix} 0 & z_a & -y_a \\ -z_a & 0 &x_a\\ y_a & -x_a & 0 \end{bmatrix} \begin{bmatrix} x_b\\ y_b\\ z_b \\ \end{bmatrix} a×b= 0−zayaza0−xa−yaxa0 xbybzb
u × = [ 0 z − y − z 0 x y − x 0 ] u_{\times}= \begin{bmatrix} 0 & z & -y \\ -z & 0 &x\\ y & -x & 0 \end{bmatrix} u×= 0−zyz0−x−yx0
u × u_{\times} u×就是叉乘矩阵。
叉乘矩阵具有反对称性。矩阵的反对称性即 A ⊤ = − A A^{\top}=-A A⊤=−A
4. 向量三重积
又叫BAC-CAB
准则
A × ( B × C ) = B ( A ∗ C ) − C ( A ∗ B ) A\times (B \times C)=B(A *C)-C(A*B) A×(B×C)=B(A∗C)−C(A∗B)
证明
取 x 方向分量 ( A × ( B × C ) ) x B × C = [ i j k x b y b z b x c y c z c ] = ( y b z c − y c z b , x c z b − x b z c , x b y c − x c y b ) ( A × ( B × C ) ) x = y a ( x b y c − x c y b ) − z a ( x c z b − x b z c ) = x b y a y c − x c y a y b − x c z a z b + x b z a z c = x b ( y a y c + z a z c ) − x c ( y a y b + z a z b ) = x b ( y a y c + z a z c ) + x b x a x c − x c x a x b − x c ( y a y b + z a z b ) = x b ( x a x c + y a y c + z a z c ) − x c ( x a x b + y a y b + z a z b ) = x b ( A ∗ C ) − x c ( A ∗ B ) 其余两个方向分量证明类似 A × ( B × C ) = B ( A ∗ C ) − C ( A ∗ B ) 取x方向分量\\ (A\times (B \times C))_x\\ B\times C= \begin{bmatrix} i & j & k \\ x_b & y_b &z_b\\ x_c & y _c & z_c \end{bmatrix}=(y_bz_c-y_cz_b,x_cz_b-x_bz_c,x_by_c-x_cy_b)\\ \begin{align} (A\times (B \times C))_x &= y_a(x_by_c-x_cy_b)-z_a(x_cz_b-x_bz_c)\nonumber\\ &= x_by_ay_c-x_cy_ay_b-x_cz_az_b+x_bz_az_c\nonumber\\ &= x_b(y_ay_c+z_az_c)-x_c(y_ay_b+z_az_b)\nonumber\\ &= x_b(y_ay_c+z_az_c)+x_bx_ax_c-x_cx_ax_b-x_c(y_ay_b+z_az_b)\nonumber\\ &= x_b(x_ax_c+y_ay_c+z_az_c)-x_c(x_ax_b+y_ay_b+z_az_b)\nonumber\\ &= x_b(A *C)-x_c(A *B)\nonumber\\ \end{align}\\ 其余两个方向分量证明类似\\ A\times(B \times C)=B(A*C)-C(A*B) 取x方向分量(A×(B×C))xB×C= ixbxcjybyckzbzc =(ybzc−yczb,xczb−xbzc,xbyc−xcyb)(A×(B×C))x=ya(xbyc−xcyb)−za(xczb−xbzc)=xbyayc−xcyayb−xczazb+xbzazc=xb(yayc+zazc)−xc(yayb+zazb)=xb(yayc+zazc)+xbxaxc−xcxaxb−xc(yayb+zazb)=xb(xaxc+yayc+zazc)−xc(xaxb+yayb+zazb)=xb(A∗C)−xc(A∗B)其余两个方向分量证明类似A×(B×C)=B(A∗C)−C(A∗B)
参考
linear_algebra
百度百科_向量三重积
mathworld
这篇关于矩阵的迹的性质的文章就介绍到这儿,希望我们推荐的文章对编程师们有所帮助!