# SIFT About Difference-of-Gaussian function extrema?

How to get formula (2) by formula(1)?

You have to take the derivative with respect to the vector $x$ and set it equal to zero. For a constant matrix $A$, the derivative of $A^Tx$ is $A$, and the derivative of $\frac12 x^TA^Tx=Ax$. So taking the derivative of $(1)$ gives
$$\frac{\partial D}{\partial x}+\frac{\partial^2D}{\partial x^2}x\tag{1}$$
Setting $(1)$ equal to zero results in $(2)$.
• $\frac12 x^TA^Tx$ is a constant,$Ax$ is a vector? – zychen Aug 31 '18 at 8:57
• you say "a constant matrix A ",do you mean $(\frac{\partial D}{\partial x})^T$ is a constant and $(\frac{\partial^2D}{\partial x^2})^T$ also is a constant? – zychen Aug 31 '18 at 9:08
• @zychen: Yes, to both questions, but I would say $\frac12x^TA^Tx$ is a scalar, which is probably what you meant. So $(1)$ is a scalar, and $(2)$ is a vector. And the derivatives of $D$ are evaluated at $x=0$, that's why they're constant. – Matt L. Aug 31 '18 at 10:52