Can I swap the positions in this equation?

51 Views Asked by At

I am looking at this question. I wonder if I have:

$$\left\|Y-XW\right\|_{\text{F}}^2$$

Does taking derivative w.r.t $W$ yields this?

$$-2X^T(Y-XW)$$