more equations
This commit is contained in:
@@ -570,6 +570,34 @@ From this we have, using the definition of the Jacobian
|
||||
!split
|
||||
===== Example 2 =====
|
||||
|
||||
We define a scalar (our cast functions are in general also scalars, think of the mean squared error) as the result of some matrix vector multiplications
|
||||
|
||||
!bt
|
||||
\[
|
||||
\alpha = \bm{y}^T\bm{A}\bm{x}$,
|
||||
\]
|
||||
!et
|
||||
with $\bm{y}$ a vector of length $m$, $\bm{A}$ an $m\times n$ matrix and $\bm{x}$ a vector of length $n$. We assume also that $\bm{A}$ does not depend on any of the two vectors.
|
||||
In order to find the derivative of $\alpha$ with respect to the two vectors, we define an intermediate vector $\bm{z}$. We define first
|
||||
$\bm{z}^T=\bm{y}^T\bm{A}$, a vector of length $n$. We have then
|
||||
!bt
|
||||
\[
|
||||
\alpha = \bm{z}^T\bm{x}$,
|
||||
\]
|
||||
!et
|
||||
which means that (using our previous example) we have
|
||||
!bt
|
||||
\[
|
||||
\frac{\partial \alpha}{\partial \bm{x}} = \bm{z}^T=\bm{y}^T\bm{A}.
|
||||
\]
|
||||
!et
|
||||
|
||||
Since $\alpha$ is a scalar we have $\alpha =\alpha^T=\bm{x}^T\bm{A}^T\bm{y}$. Defining now $\bm{z}=\bm{x}^T\bm{A}^T$ we find that
|
||||
!bt
|
||||
\[
|
||||
\frac{\partial \alpha}{\partial \bm{y}} = \bm{z}^T=\bm{x}^T\bm{A}^T..
|
||||
\]
|
||||
!et
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user