Matrix calculus Information & Matrix calculus Links at HealthHaven.com
advertise
add site
services
publishers
database
health videos
Bookmark and Share

search wiki for    ?
web dir firms image gallery news pdf wiki shop video 
about
toolbar
stats
live show
health store
more stuff
JOIN/LOGIN
Featured Results:
ASMB - American Society for Matrix Biology - Matrix Biology Journal
ASMB - American Society for Matrix Biology - Matrix Biology Journal
asmb.net
 Lumbar Matrix Scan Training || Spine Matrix
Lumbar Matrix Scan Training || Spine Matrix
spinematrix.com
  Matrix Institute The Matrix Model
Matrix Institute The Matrix Model
matrixinstitute.org
 Cal Matrix by Metagenics: Cal Matrix 180 tablets 204 milligrams...
Cal Matrix by Metagenics: Cal Matrix 180 tablets 204 milligrams...
acuatlanta.net
 
Topics in Calculus

Fundamental theorem
Limits of functions
Continuity
Mean value theorem

Multivariable calculus 

Matrix calculus
Partial derivative
Multiple integral
Line integral
Surface integral
Volume integral
Jacobian

In mathematics, matrix calculus is a specialized notation for doing multivariable calculus, especially over spaces of matrices, where it defines the matrix derivative. This notation is well-suited to describing systems of differential equations, and taking derivatives of matrix-valued functions with respect to matrix variables. This notation is commonly used in statistics and engineering, while the tensor index notation is preferred in physics.

Contents

[edit] Notice

This article uses another definition for vector and matrix calculus than the form often encountered within the field of estimation theory and pattern recognition. The resulting equations will therefore appear to be transposed when compared to the equations used in textbooks within these fields.

[edit] Notation

Let M(n,m) denote the space of real n×m matrices with n rows and m columns, such matrices will be denoted using bold capital letters: A, X, Y, etc. An element of M(n,1), that is, a column vector, is denoted with a boldface lowercase letter: a, x, y, etc. An element of M(1,1) is a scalar, denoted with lowercase italic typeface: a, t, x, etc. XT denotes matrix transpose, tr(X) is trace, and det(X) is the determinant. All functions are assumed to be of differentiability class C1 unless otherwise noted. Generally letters from first half of the alphabet (a, b, c, …) will be used to denote constants, and from the second half (t, x, y, …) to denote variables.

[edit] Vector calculus

Because the space M(n,1) is identified with the Euclidean space Rn and M(1,1) is identified with R, the notations developed here can accommodate the usual operations of vector calculus.

[edit] Matrix calculus

For the purposes of defining derivatives of simple functions, not much changes with matrix spaces; the space of n×m matrices is isomorphic to the vector space Rnm. The three derivatives familiar from vector calculus have close analogues here, though beware the complications that arise in the identities below.

  • The tangent vector of a curve F : RM(n,m)
     \frac{\partial \mathbf{F}}{\partial t} = \begin{bmatrix} \frac{\partial F_{1,1}}{\partial t} & \cdots & \frac{\partial F_{1,m}}{\partial t}\\ \vdots & \ddots & \vdots\\ \frac{\partial F_{n,1}}{\partial t} & \cdots & \frac{\partial F_{n,m}}{\partial t}\\ \end{bmatrix}.
  • The gradient of a scalar function f : M(n,m) → R
     \frac{\partial f}{\partial \mathbf{X}} = \begin{bmatrix} \frac{\partial f}{\partial X_{1,1}} & \cdots & \frac{\partial f}{\partial X_{n,1}}\\ \vdots & \ddots & \vdots\\ \frac{\partial f}{\partial X_{1,m}} & \cdots & \frac{\partial f}{\partial X_{n,m}}\\ \end{bmatrix}.
    Notice that the indexing of the gradient with respect to X is transposed as compared with the indexing of X. The directional derivative of f in the direction of matrix Y is given by
    \nabla_\mathbf{Y} f = \operatorname{tr} \left(\frac{\partial f}{\partial \mathbf{X}} \mathbf{Y}\right).
  • The differential or the matrix derivative of a function F : M(n,m) → M(p,q) is an element of M(p,q) M(m,n), a fourth-rank tensor (the reversal of m and n here indicates the dual space of M(n,m)). In short it is an m×n matrix each of whose entries is a p×q matrix.[citation needed]
    \frac{\partial\mathbf{F}} {\partial\mathbf{X}}= \begin{bmatrix} \frac{\partial\mathbf{F}}{\partial X_{1,1}} & \cdots & \frac{\partial \mathbf{F}}{\partial X_{n,1}}\\ \vdots & \ddots & \vdots\\ \frac{\partial\mathbf{F}}{\partial X_{1,m}} & \cdots & \frac{\partial \mathbf{F}}{\partial X_{n,m}}\\ \end{bmatrix},
    and note that each ∂F/∂Xi,j is a p×q matrix defined as above. Note also that this matrix has its indexing transposed; m rows and n columns. The pushforward along F of an n×m matrix Y in M(n,m) is then
    d\mathbf{F}(\mathbf{Y}) = \operatorname{tr}\left(\frac{\partial\mathbf{F}} {\partial\mathbf{X}}\mathbf{Y}\right), as formal block matricies.
    Note that this definition encompasses all of the preceding definitions as special cases.

[edit] Identities

Note that matrix multiplication is not commutative, so in these identities, the order must not be changed.

  • Chain rule: If Z is a function of Y which in turn is a function of X, and these are all column vectors, then[citation needed]
     \frac{\partial \mathbf{Z}} {\partial \mathbf{X}} = \frac{\partial \mathbf{Z}} {\partial \mathbf{Y}} \frac{\partial \mathbf{Y}} {\partial \mathbf{X}}
  • Product rule:In all cases where the derivatives do not involve tensor products (for example, Y has more than one row and X has more than one column),[citation needed]
     \frac{\partial (\mathbf{Y}\mathbf{Z})}{\partial \mathbf{X}} = \frac{\partial\mathbf{Y}}{\partial\mathbf{X}}{\mathbf{Z}} + \mathbf{Y}\frac{\partial\mathbf{Z}}{\partial \mathbf{X}}

[edit] Examples

[edit] Derivative of linear functions

This section lists some commonly used vector derivative formulas for linear equations evaluating to a vector.

 \frac{\partial \; \textbf{a}^T\textbf{x}}{\partial \; \textbf{x}} = \frac{\partial \; \textbf{x}^T\textbf{a}}{\partial \; \textbf{x}} = \textbf{a}^T
 \frac{\partial \; \textbf{A}\textbf{x}}{\partial \; \textbf{x}} = \frac{\partial \; \textbf{x}^T\textbf{A}}{\partial \; \textbf{x}^T} = \textbf{A}^T

[edit] Derivative of quadratic functions

This section lists some commonly used vector derivative formulas for quadratic matrix equations evaluating to a scalar.

 \frac{\partial \; \textbf{x}^T \textbf{A}\textbf{x}}{\partial \; \textbf{x}} =  \textbf{x}^T(\textbf{A}^T + \textbf{A})
 \frac{\partial \; (\textbf{A}\textbf{x} + \textbf{b})^T \textbf{C} (\textbf{D}\textbf{x} + \textbf{e})     }{\partial \; \textbf{x}} =  (\textbf{D}\textbf{x} + \textbf{e})^T \textbf{C}^T \textbf{A} +  (\textbf{A}\textbf{x} + \textbf{b})^T \textbf{C} \textbf{D}

Related to this is the derivative of the Euclidean norm:

 \frac{\partial \; \|\mathbf{x}-\mathbf{a}\|}{\partial \; \textbf{x}} = \frac{(\mathbf{x}-\mathbf{a})^T}{\|\mathbf{x}-\mathbf{a}\|}.

[edit] Derivative of matrix traces

This section shows examples of matrix differentiation of common trace equations.

 \frac{\partial \; \operatorname{tr}( \textbf{A} \textbf{X} \textbf{B})}{\partial \; \textbf{X}} = \frac{\partial \; \operatorname{tr}( \textbf{B}^T \textbf{X}^T \textbf{A}^T)}{\partial \; \textbf{X}} = \textbf{B} \textbf{A}
 \frac{\partial \; \operatorname{tr}( \textbf{A} \textbf{X} \textbf{B} \textbf{X}^T \textbf{C}) }{\partial \; \textbf{X}} =  \textbf{B} \textbf{X}^T \textbf{C} \textbf{A} + \textbf{B}^T \textbf{X}^T \textbf{A}^T \textbf{C}^T

[edit] Derivative of matrix determinant

 \frac{\partial \det\mathbf{X}}{\partial \mathbf{X}}= \operatorname{adj}\,\mathbf{X}= \det\mathbf{X}\cdot \mathbf{X}^{-1}.

[edit] Relation to other derivatives

The matrix derivative is a convenient notation for keeping track of partial derivatives for doing calculations. The Fréchet derivative is the standard way in the setting of functional analysis to take derivatives with respect to vectors. In the case that a matrix function of a matrix is Fréchet differentiable, the two derivatives will agree up to translation of notations. As is the case in general for partial derivatives, some formulae may extend under weaker analytic conditions than the existence of the derivative as approximating linear mapping.

[edit] Usages

Matrix calculus is used for deriving optimal stochastic estimators, often involving the use of Lagrange multipliers. This includes the derivation of:

[edit] Alternatives

The tensor index notation with its Einstein summation convention is very similar to the matrix calculus, except one writes only a single component at a time. It has the advantage that one can easily manipulate arbitrarily high rank tensors, whereas tensors of rank higher than two are quite unwieldy with matrix notation. Note that a matrix can be considered simply a tensor of rank two.

[edit] See also

[edit] External links

  • Matrix Calculus appendix from Introduction to Finite Element Methods book on University of Colorado at Boulder. Uses the Hessian (transpose to Jacobian) definition of vector and matrix derivatives.
  • Matrix calculus Matrix Reference Manual , Imperial College London.
  • The Matrix Cookbook, with a derivatives chapter. Uses the Hessian definition.



Product Results (view all...)

search wiki for    ?
web dir firms image gallery news pdf wiki shop video 



↑ top of page ↑about thumbshots