机器人中常用矩阵等式-I (汇总)

# 机器人中常用矩阵等式

机器人相关领域看论文或推公式时, 经常会遇到一些不那么直观的矩阵等式需要查书确认. 这里简单汇总一下, 方便翻查.

I. 摘要

NameMatrix Identities
[Identity 1] Matrix Trace t r ( A B ) = t r ( B A ) {\rm tr}(\mathbf{A}\mathbf{B}) = {\rm tr}(\mathbf{B}\mathbf{A}) tr(AB)=tr(BA)
[Identity 2-a] Derivative of Vector with Respect to Vector (Denominator-Layout Notation) ∂ y ∂ x ≜ [ ∂ y 1 ∂ x 1 ∂ y 2 ∂ x 1 ⋯ ∂ y m ∂ x 1 ∂ y 1 ∂ x 2 ∂ y 2 ∂ x 2 ⋯ ∂ y m ∂ x 2 ⋮ ⋮ ⋱ ⋮ ∂ y 1 ∂ x n ∂ y 2 ∂ x n ⋯ ∂ y m ∂ x n ] \frac{\partial \mathbf{y}}{\partial \mathbf{x}} \triangleq \begin{bmatrix} \frac{\partial y_1}{\partial x_1} &\frac{\partial y_2}{\partial x_1} &\cdots &\frac{\partial y_m}{\partial x_1}\\ \frac{\partial y_1}{\partial x_2} &\frac{\partial y_2}{\partial x_2} &\cdots &\frac{\partial y_m}{\partial x_2}\\ \vdots &\vdots & \ddots &\vdots\\\frac{\partial y_1}{\partial x_n} &\frac{\partial y_2}{\partial x_n} &\cdots &\frac{\partial y_m}{\partial x_n}\end{bmatrix} xy x1y1x2y1xny1x1y2x2y2xny2x1ymx2ymxnym
[Identity 2-b] Derivative of Vector with Respect to Vector (Numerator-Layout Notation - in common use) ∂ y ∂ x ≜ [ ∂ y 1 ∂ x 1 ∂ y 1 ∂ x 2 ⋯ ∂ y 1 ∂ x n ∂ y 2 ∂ x 1 ∂ y 2 ∂ x 2 ⋯ ∂ y 2 ∂ x n ⋮ ⋮ ⋱ ⋮ ∂ y m ∂ x 1 ∂ y m ∂ x 2 ⋯ ∂ y m ∂ x n ] \frac{\partial \mathbf{y}}{\partial \mathbf{x}} \triangleq \begin{bmatrix} \frac{\partial y_1}{\partial x_1} &\frac{\partial y_1}{\partial x_2} &\cdots &\frac{\partial y_1}{\partial x_n}\\ \frac{\partial y_2}{\partial x_1} &\frac{\partial y_2}{\partial x_2} &\cdots &\frac{\partial y_2}{\partial x_n}\\ \vdots &\vdots & \ddots &\vdots\\\frac{\partial y_m}{\partial x_1} &\frac{\partial y_m}{\partial x_2} &\cdots &\frac{\partial y_m}{\partial x_n}\end{bmatrix} xy x1y1x1y2x1ymx2y1x2y2x2ymxny1xny2xnym
[Identity 3] Derivative of Scale with Respect to Matrix (Denominator-Layout Notation) ∂ f ∂ X ≜ [ ∂ f ∂ X 11 ∂ f ∂ X 12 ⋯ ∂ f ∂ X 1 n ∂ f ∂ X 21 ∂ f ∂ X 22 ⋯ ∂ f ∂ X 2 n ⋮ ⋮ ⋱ ⋮ ∂ f ∂ X m 1 ∂ f ∂ X m 2 ⋯ ∂ f ∂ X m n ] \frac{\partial f}{\partial \mathbf X} \triangleq \begin{bmatrix} \frac{\partial f}{\partial X_{11}} & \frac{\partial f}{\partial X_{12}} &\cdots & \frac{\partial f}{\partial X_{1n}} \\ \frac{\partial f}{\partial X_{21}} & \frac{\partial f}{\partial X_{22}} &\cdots & \frac{\partial f}{\partial X_{2n}} \\ \vdots &\vdots &\ddots &\vdots\\ \frac{\partial f}{\partial X_{m1}} & \frac{\partial f}{\partial X_{m2}} &\cdots & \frac{\partial f}{\partial X_{mn}} \end{bmatrix} Xf X11fX21fXm1fX12fX22fXm2fX1nfX2nfXmnf
[Identity 4] Partial Derivative of a Matrix Trace of the First Order (1) ∂ t r X Y ∂ X = ∂ t r Y X ∂ X = Y T \frac{\partial {\rm tr}{\mathbf X}{\mathbf Y}}{\partial \mathbf X} = \frac{\partial {\rm tr}{\mathbf Y} {\mathbf X}}{\partial \mathbf X} = {\mathbf Y}^{\small \rm T} XtrXY=XtrYX=YT
[Identity 5] Partial Derivative of a Matrix Trace of the First Order (2) ∂ t r X T Y ∂ X = ∂ t r Y X T ∂ X = Y \frac{\partial {\rm tr}{{\mathbf X}^{\small\rm T}} {\mathbf Y}}{\partial \mathbf X} = \frac{\partial {\rm tr}{\mathbf Y} {{\mathbf X}^{\small\rm T}} } {\partial \mathbf X} = {\mathbf Y} XtrXTY=XtrYXT=Y
[Identity 6] Partial Derivative of a Matrix Trace of the Second Order (1) ∂ t r X Z X T ∂ X = X Z T + X Z \frac{\partial {\rm tr}{\mathbf X}{\mathbf Z}{\mathbf X}^{\small \rm T}}{\partial \mathbf X} = {\mathbf X}{\mathbf Z}^{\small\rm T} + {\mathbf X}{\mathbf Z} XtrXZXT=XZT+XZ
[Identity 7] Partial Derivative of a Matrix Trace of the Second Order (2) ∂ t r X T Z X ∂ X = Z X + Z T X \frac{\partial {\rm tr} {{\mathbf X}^{\small \rm T}} {\mathbf Z}{\mathbf X}}{\partial \mathbf X} = {\mathbf Z}{\mathbf X} + {{\mathbf Z}^{\small\rm T}}{\mathbf X} XtrXTZX=ZX+ZTX
[Identity 8-a] Partial Derivative of a Quadratic Form (Denominator-Layout Notation) ∂ x T A x ∂ x = ( A + A T )   x \frac{\partial {\mathbf x}^{\small \rm T} \mathbf{A} {\mathbf x}}{\partial \mathbf{x}} = (\mathbf{A} + \mathbf{A}^{\small \rm T})\,\mathbf{x} xxTAx=(A+AT)x
[Identity 8-b] Partial Derivative of a Quadratic Form (Numerator-Layout Notation) ∂ x T A x ∂ x = x T ( A + A T ) \frac{\partial {\mathbf x}^{\small \rm T} \mathbf{A} {\mathbf x}}{\partial \mathbf{x}} = \mathbf{x}^{\small\rm T}(\mathbf{A} + \mathbf{A}^{\small \rm T}) xxTAx=xT(A+AT)
[Identity 9] Vector Triple Product A × ( B × C ) = B ( A ⋅ C ) − C ( A ⋅ B ) \mathbf{A}\times (\mathbf{B} \times \mathbf{C}) = \mathbf{B}(\mathbf{A}\cdot\mathbf{C}) - \mathbf{C}(\mathbf{A}\cdot\mathbf{B}) A×(B×C)=B(AC)C(AB)
[Identity 10] Matrix Inversion lemmas ( A − B D − 1 C ) − 1 = A − 1 + A − 1 B ( D − C A − 1 B ) − 1 C A − 1 (\mathbf{A}- {\mathbf{B}} {\mathbf{D}^{-1}}{\mathbf{C}})^{-1} = \mathbf{A}^{-1}+\mathbf{A}^{-1}\mathbf{B}(\mathbf{D}-\mathbf{C}{\mathbf{A}^{-1}}\mathbf{B})^{-1} \mathbf{C}\mathbf{A}^{-1} (ABD1C)1=A1+A1B(DCA1B)1CA1
 " ( D − C A − 1 B ) − 1 = D − 1 + D − 1 C ( A − B D − 1 C ) − 1 B D − 1 (\mathbf{D}-\mathbf{C}{\mathbf{A}^{-1}}\mathbf{B})^{-1} = \mathbf{D}^{-1} + {\mathbf{D}^{-1}}\mathbf{C}(\mathbf{A}- {\mathbf{B}} {\mathbf{D}^{-1}}{\mathbf{C}})^{-1} \mathbf{B}\mathbf{D}^{-1} (DCA1B)1=D1+D1C(ABD1C)1BD1
 " A − 1 B ( D − C A − 1 B ) − 1 = ( A − B D − 1 C ) − 1 B D − 1 \mathbf{A}^{-1}\mathbf{B}(\mathbf{D}-\mathbf{C}{\mathbf{A}^{-1}}\mathbf{B})^{-1} = (\mathbf{A}- {\mathbf{B}} {\mathbf{D}^{-1}}{\mathbf{C}})^{-1} \mathbf{B}\mathbf{D}^{-1} A1B(DCA1B)1=(ABD1C)1BD1
 " ( D − C A − 1 B ) − 1 C A − 1 = D − 1 C ( A − B D − 1 C ) − 1 (\mathbf{D}-\mathbf{C}{\mathbf{A}^{-1}}\mathbf{B})^{-1}\mathbf{C}\mathbf{A}^{-1} = {\mathbf{D}^{-1}}\mathbf{C}(\mathbf{A}- {\mathbf{B}} {\mathbf{D}^{-1}}{\mathbf{C}})^{-1} (DCA1B)1CA1=D1C(ABD1C)1
 " ( A + B C ) − 1 = A − 1 − A − 1 B ( I + C A − 1 B ) − 1 C A − 1 (\mathbf{A}+ {{\mathbf{B}}} {\mathbf{C}})^{-1} = \mathbf{A}^{-1} - \mathbf{A}^{-1}{\mathbf{B}}(\mathbf{I}+\mathbf{C}{\mathbf{A}^{-1}}{\mathbf{B}})^{-1} \mathbf{C}\mathbf{A}^{-1} (A+BC)1=A1A1B(I+CA1B)1CA1

[补充一]

NameMatrix Identities
[Identity 11] Identity About Rotation [ R θ ] × = R [ θ ] × R T [\mathbf{R}\boldsymbol\theta]_{\times} = \mathbf{R}[\boldsymbol{\theta}]_{\times}\mathbf{R}^{\small\rm T} [Rθ]×=R[θ]×RT
[Identity 12] Identity About Skew-Symmetric Matrix x T [ θ ] × x = 0 \mathbf{x}^{\rm \small T} [\boldsymbol\theta]_{\times} \mathbf{x} = 0 xT[θ]×x=0

[补充二]

NameMatrix Identities
[Identity 13-a] Derivative of a Matrix’s Determinant ∂ d e t ( A ) ∂ A = a d j ( A ) T = ( d e t ( A ) A − 1 ) T \frac{\partial {\rm det}(\mathbf{A})}{\partial \mathbf{A}} = {\rm adj}(\mathbf{A})^{\rm T} = \left({\rm det}(\mathbf{A}) \mathbf{A}^{-1} \right)^{\rm T} Adet(A)=adj(A)T=(det(A)A1)T
[Identity 13-b] Derivative of a Rotation Matrix’s Determinant ∂ d e t ( R ) ∂ R = R \frac{\partial {\rm det}(\mathbf{R})}{\partial \mathbf{R}} = \mathbf{R} Rdet(R)=R
[Identity 14-a] Derivative of a Matrix Trace ∂ t r [ A X B ] ∂ X = A T   B T \frac{\partial {\rm tr}[\mathbf{AXB}]}{\partial \mathbf{X}} = {\mathbf{A}^{\small\rm T}}\, {\mathbf{B}^{\small \rm T}} Xtr[AXB]=ATBT
[Identity 14-b] Derivative of a Matrix Trace ∂ t r [ A X T B ] ∂ X = B A \frac{\partial {\rm tr}[\mathbf{A} {\mathbf{X}^{\small\rm T}} \mathbf{B}]}{\partial \mathbf{X}} = {\mathbf{B}}{\mathbf{A}} Xtr[AXTB]=BA

II. 具体展开及证明

[Identity 1] ~ [Identity 6] 的证明请参看

[Identity 7] ~ [Identity 10] 的证明请参看

[Identity 11] ~ [Identity 14] 的证明请参看


  • 1
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 1
    评论
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值