0
$\begingroup$

I have this objective function, I want to find its derivative with respect to $U_i$ and $V_j$, I don't know how should I approach these kind of functions, it would be helpful if any one could tell me how should I tackle this kind of problems!

$$ E = \frac{1}{2} \sum_{i=1}^{N}\sum_{j=1}^{M}I_{ij}(R_{ij} - U_i^TV_j)^2 + \frac{\lambda _U}{2}\sum_{i=1}^{N}||U_i||^2 + \frac{\lambda _V}{2}\sum_{j=1}^{M}||V_j||^2 $$

Here is what I have come so far:

$$ \frac{\partial E}{\partial U_i} = \sum_{j=1}^{M}(R_{ij} - U_i^TV_j)V_j + \lambda_V U_i $$

I want to find $\frac{\partial E}{\partial V_j}$ too, but I don't know how to handle the part which includes norm.

$\endgroup$

1 Answer 1

1
$\begingroup$

Consider a vector $\mathbf{u}$ with components $u_j$. Then, $$ a := \lVert \mathbf{u} \rVert = \sqrt{u_p u_p} $$ where summation over the index $p$ is implied. Therefore, $$ b := a^2 = \lVert \mathbf{u} \rVert^2 = u_p u_p $$ The derivative of $b$ with respect to $u_j$ is $$ \frac{\partial b}{\partial u_j} = \frac{\partial}{\partial u_j}(u_p u_p) = 2 u_p \frac{\partial u_p}{\partial u_j} = 2 u_p \delta_{pj} = 2 u_j $$ where $\delta_{pj} = 1$ if $p = j$ and $\delta_{pj} = 0$ if $p \ne j$. In vector notation, $$ \frac{\partial b}{\partial \mathbf{u}} = \frac{\partial a^2}{\partial \mathbf{u}} = \frac{\partial}{\partial \mathbf{u}} \left( \lVert \mathbf{u} \rVert\right)^2 = 2 \mathbf{u} $$

$\endgroup$

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .