Chain rule in matrix derivative

matricesmatrix-calculuspartial derivative

Let $\eta$ given by $\eta = x^T\beta$, where $x$ and $\beta$ are vectors with $p\times 1$ and $p\times 1$, respectively. I have the expression given by $S = exp(\eta)$. I'd like to calculate the derivatives $\frac{\partial S}{\partial \beta}$ and $\frac{\partial S^T}{\partial \beta}$.

I tried to calculate and concluded that $\frac{\partial S}{\partial \beta} = exp(x^T\beta) x^T$, and $\frac{\partial S^T}{\partial \beta} = exp(\beta^Tx)x$, but in this case I have incorret dimension product in the second derivative.

Best Answer

$S$ is a scalar, $S=S^T$, hence

$$\frac{\partial S}{\partial \beta}=\frac{\partial S^T}{\partial \beta}$$

There are two conventions, numerator layout or denominator layout, you can write your derivative as a row or a column but just be consistent.

Related Question