I am working on a problem connected to shallow water waves. I have a vector:
$U = \begin{bmatrix} h \\ h \cdot v_1\\ h \cdot v_2\end{bmatrix}$
and a function
$f(U) = \begin{bmatrix} h \cdot v_1 \\ h \cdot v_1^2 + 0.5\cdot gh^2\\ h \cdot v_1 \cdot v_2\end{bmatrix}$
I now want to calculate the Jacobian Matrix of $f(U)$.
However, I am lost at how to calculate the partial derivatives when it comes to differentiating through a product. I.e.:
$\frac{\partial (h \cdot v_1^2 + 0.5 \cdot gh^2)}{\partial (h \cdot v_1)} = \frac{\partial (h \cdot v_1^2) }{\partial (h \cdot v_1)} + \frac{\partial (0.5 \cdot gh^2)}{\partial (h \cdot v_1)} = v_1 + ? \dots$
or
$\frac{\partial (h \cdot v_1^2 + 0.5 \cdot gh^2)}{\partial (h \cdot v_2)} = \frac{\partial (h \cdot v_1^2) }{\partial (h \cdot v_2)} + \frac{\partial (0.5 \cdot gh^2)}{\partial (h \cdot v_2)} = \dots$
Googling it is really difficult and brought no result, since I only ever find explanations for the product rule... Maybe someone here could enlighten me! Any kind of pointer in the right direction is highly appreciated! Thanks so much in advance!
In the final analysis your $f$ is a function $f:\>{\mathbb R}^3\to{\mathbb R}^3$ taking the variables $h$, $v_1$, $v_2$ as input and producing three scalar values $$u:=hv_1,\quad v:=hv_1^2+{g\over2}h^2,\quad w:=hv_1v_2$$ as output, whereby $g$ seems to be some constant. By definition the Jacobian of $f$ is the matrix of partial derivatives $$\left[\matrix{u_h& u_{v_1}&u_{v_2}\cr v_h& v_{v_1}&v_{v_2}\cr w_h& w_{v_1}&w_{v_2}\cr}\right]=\left[\matrix{v_1& h&0\cr v_1^2+gh& 2v_1h&0\cr v_1v_2&hv_2&hv_1\cr}\right]\ .$$