I need to solve with basic methods this simple Shallow Water Model:

$$\begin{bmatrix}h\\ hv\end{bmatrix}_t+\begin{bmatrix}hv\\ hv^2+\frac{1}{2}gh^2\end{bmatrix}_x=\begin{bmatrix}0\\ 0\end{bmatrix}$$

where $h$ is the height of the water, $v$ is the horizontal velocity of the fluid and $g$ is the gravitational constant.

Writing in quasilinear form, I've got

$$\begin{bmatrix}h\\ hv\end{bmatrix}_t+\begin{bmatrix}0&1\\ gh-v^2&2v\end{bmatrix}\begin{bmatrix}h\\ hv\end{bmatrix}_x=\begin{bmatrix}0\\ 0\end{bmatrix}$$

The Jacobian can be diagonalized as $J=RDR^{-1}$ where

$$R=\begin{bmatrix}\dfrac{1}{v-\sqrt{gh}}&\dfrac{1}{v+\sqrt{gh}}\\ 1&1\end{bmatrix}$$

$$R^{-1}=\begin{bmatrix}\dfrac{v^2-gh}{2\sqrt{gh}}&\dfrac{1}{2}-\dfrac{v}{2\sqrt{gh}}\\ \dfrac{gh-v^2}{2\sqrt{gh}}&\dfrac{1}{2}\bigg(\dfrac{v}{\sqrt{gh}}+1\bigg)\end{bmatrix}$$

$$D=\begin{bmatrix}v-\sqrt{gh}&0\\0&v+\sqrt{gh}\end{bmatrix}$$

I've done the change of variables

$$\begin{bmatrix}\overline{h}\\ \overline{k}\end{bmatrix}=R^{-1}\begin{bmatrix}h\\ hv\end{bmatrix}$$

$$\begin{bmatrix}\overline{h}\\ \overline{k}\end{bmatrix}=\begin{bmatrix}\frac{h}{2}(v+\sqrt{gh})\\ \frac{h}{2}(v-\sqrt{gh})\end{bmatrix}$$

Geting the system

$$\begin{bmatrix}\overline{h}\\ \overline{k}\end{bmatrix}_t+\begin{bmatrix}v-\sqrt{gh}&0\\0&v+\sqrt{gh}\end{bmatrix}\begin{bmatrix}\overline{h}\\ \overline{k}\end{bmatrix}_x=\begin{bmatrix}0\\ 0\end{bmatrix}$$

ie

$$\overline{h}_t+(v-\sqrt{gh})\overline{h}_x=0\\ \overline{k}_t+(v+\sqrt{gh})\overline{k}_x=0$$

Trying to solve this conservation laws by the characteristic method, I've got to the first

$$x(t)=(v_0(x_0)-\sqrt{gh_0(x_0)})t+x_0\qquad (i)$$

and to the second

$$x(t)=(v_0(\overline{x}_0)+\sqrt{gh_0(\overline{x}_0)})t+\overline{x}_0\qquad (ii)$$

where $v_0,h_0$ are the initial conditions.

To find the solution at time $(x,t)$, I need to solve $(i)$ for $x_0$ and take $\overline{h}(x,t)=\overline{h}_0(x_0)$ and solve $(ii)$ for $\overline{x}_0$, taking $\overline{k}(x,t)=\overline{k}_0(\overline{x}_0)$.

The solution in time $(x,t)$ may be the solution of the system

$$\begin{bmatrix}\overline{h}_0(x_0)\\ \overline{k}_0(\overline{x}_0)\end{bmatrix}=\begin{bmatrix}\frac{h}{2}(v+\sqrt{gh})\\ \frac{h}{2}(v-\sqrt{gh})\end{bmatrix} $$

That is

$$hv(x,t)=\overline{h}_0(x_0)+\overline{k}_0(\overline{x}_0)$$

$$h(x,t)=\bigg(\dfrac{\overline{h}_0(x_0)-\overline{k}_0(\overline{x}_0)}{\sqrt{g}}\bigg)^{2/3}$$

Or better

$$hv(x,t)=\frac{h_0(x_0)(v_0(x_0)+\sqrt{gh_0(x_0)})+h_0(\overline{x}_0)(v_0(\overline{x}_0)-\sqrt{gh_0(\overline{x}_0)})}{2}$$

$$h(x,t)=\bigg(\dfrac{h_0(x_0)(v_0(x_0)+\sqrt{gh_0(x_0)})-h_0(\overline{x}_0)(v_0(\overline{x}_0)-\sqrt{gh_0(\overline{x}_0)})}{2\sqrt{g}}\bigg)^{2/3}$$

I would like to know:

1) If my idea is correct (mainly about characteristics: is it valid? I think there is troubles with this part)

2) If these calculus are sufficient to "solve" the system. In other words, what mean the "solution" of the system? The question that I am dealing is only the following:

Find the solution to the model.

I think this is something vague once I don't have any data. What do you understand as the "solution of the system"?

3) And if the characteristics crosses or occur some problem with this method? Or if (i) and (ii) don't have solutions? With some simulations that I've tried the equations (i) and (ii) don't had solutions for a great number of points $(x,t)$. Without the initial conditions, how can I know about possible troubles?

Many thanks.

==========================

Edit

If we wish to study waves with very small amplitude, then we can linearize these equations around some constant state $(\hat{h},\hat{h}\hat{v})$ to obtain a linear system.

$$\begin{bmatrix}h\\ hv\end{bmatrix}_t+\begin{bmatrix}0&1\\ g\hat{h}-\hat{v}^2&2\hat{v}\end{bmatrix}\begin{bmatrix}h\\ hv\end{bmatrix}_x=\begin{bmatrix}0\\ 0\end{bmatrix}$$

Getting the system

$$\begin{bmatrix}\overline{h}\\ \overline{k}\end{bmatrix}_t+\begin{bmatrix}\hat{v}-\sqrt{g\hat{h}}&0\\0&\hat{v}+\sqrt{g\hat{h}}\end{bmatrix}\begin{bmatrix}\overline{h}\\ \overline{k}\end{bmatrix}_x=\begin{bmatrix}0\\ 0\end{bmatrix}$$

where

$$\begin{bmatrix}\overline{h}\\ \overline{k}\end{bmatrix}=R^{-1}\begin{bmatrix}h\\ hv\end{bmatrix}=\begin{bmatrix}\dfrac{\hat{v}^2-g\hat{h}}{2\sqrt{g\hat{h}}}&\dfrac{1}{2}-\dfrac{\hat{v}}{2\sqrt{g\hat{h}}}\\ \dfrac{g\hat{h}-\hat{v}^2}{2\sqrt{g\hat{h}}}&\dfrac{1}{2}\bigg(\dfrac{\hat{v}}{\sqrt{g\hat{h}}}+1\bigg)\end{bmatrix}\begin{bmatrix}h\\ hv\end{bmatrix}$$

The solution is

$$\begin{bmatrix}\overline{h}\\ \overline{k}\end{bmatrix}(x,t)=\begin{bmatrix}\overline{h}_0(x-(\hat{v}-\sqrt{g\hat{h}})t)\\ \overline{k}_0(x-(\hat{v}+\sqrt{g\hat{h}})t)\end{bmatrix}$$

Or better

$$\begin{bmatrix}h\\ hv\end{bmatrix}(x,t)=R\begin{bmatrix}\overline{h}\\ \overline{k}\end{bmatrix}(x,t)$$

$$\begin{bmatrix}h\\ hv\end{bmatrix}(x,t)=\begin{bmatrix}\dfrac{1}{\hat{v}-\sqrt{g\hat{h}}}&\dfrac{1}{\hat{v}+\sqrt{g\hat{h}}}\\ 1&1\end{bmatrix}\begin{bmatrix}\overline{h}_0(x-(\hat{v}-\sqrt{g\hat{h}})t)\\ \overline{k}_0(x-(\hat{v}+\sqrt{g\hat{h}})t)\end{bmatrix}$$

For instance, let take $\hat{h}=1$ and $\hat{v}=0$, considering $g=1$ (in some dimension).

So,

$$\begin{bmatrix}\overline{h}\\ \overline{k}\end{bmatrix}=\begin{bmatrix}\dfrac{-1}{2}&\dfrac{1}{2}\\ \dfrac{1}{2}&\dfrac{1}{2}\end{bmatrix}\begin{bmatrix}h\\ hv\end{bmatrix}=\begin{bmatrix}\dfrac{(hv-h)}{2}\\ \dfrac{(h+hv)}{2}\end{bmatrix}$$

$$\begin{bmatrix}\overline{h}\\ \overline{k}\end{bmatrix}_t+\begin{bmatrix}-1&0\\0&1\end{bmatrix}\begin{bmatrix}\overline{h}\\ \overline{k}\end{bmatrix}_x=\begin{bmatrix}0\\ 0\end{bmatrix}$$

The solution is

$$\begin{bmatrix}\overline{h}\\ \overline{k}\end{bmatrix}(x,t)=\begin{bmatrix}\overline{h}_0(x+t)\\ \overline{k}_0(x-t)\end{bmatrix}=\begin{bmatrix}\dfrac{(h_0v_0-h_0)(x+t)}{2}\\ \dfrac{(h_0v_0+h_0)(x-t)}{2}\end{bmatrix}$$

Or better

$$\begin{bmatrix}h\\ hv\end{bmatrix}(x,t)=R\begin{bmatrix}\overline{h}\\ \overline{k}\end{bmatrix}(x,t)=\begin{bmatrix}-1&1\\1&1 \end{bmatrix}\begin{bmatrix}\dfrac{(h_0v_0-h_0)(x+t)}{2}\\ \dfrac{(h_0v_0+h_0)(x-t)}{2}\end{bmatrix}$$

$$\begin{bmatrix}h\\ hv\end{bmatrix}(x,t)=\begin{bmatrix}\dfrac{(-h_0v_0+h_0)(x+t)+(h_0v_0+h_0)(x-t)}{2}\\ \dfrac{(h_0v_0-h_0)(x+t)+(h_0v_0+h_0)(x-t)}{2}\end{bmatrix}$$

Taking $v_0\equiv0$ and $h_0=1+\frac{2}{5}e^{-5x^2}$ as in [1], we have

$$\begin{bmatrix}h\\ hv\end{bmatrix}(x,t)=\begin{bmatrix}\dfrac{h_0(x+t)+h_0(x-t)}{2}\\ \dfrac{-h_0(x+t)+h_0(x-t)}{2}\end{bmatrix}$$

$$\begin{bmatrix}h\\ hv\end{bmatrix}(x,t)=\begin{bmatrix}\dfrac{1+\frac{2}{5}e^{-5(x+t)^2}+1+\frac{2}{5}e^{-5(x-t)^2}}{2}\\ \dfrac{-1-\frac{2}{5}e^{-5(x+t)^2}+1+\frac{2}{5}e^{-5(x-t)^2}}{2}\end{bmatrix}$$

$$\begin{bmatrix}h\\ hv\end{bmatrix}(x,t)=\begin{bmatrix}1+\frac{1}{5}(e^{-5(x+t)^2}+e^{-5(x-t)^2})\\ \frac{1}{5}(-e^{-5(x+t)^2}+e^{-5(x-t)^2})\end{bmatrix}$$

[1] CROWHURST, Peter. Numerical Solutions of One-Dimensional Shallow Water Equations. Australian Mathematical Science Institute, School Of Computing And Mathematics, Charles Sturt University, Feb. 2013.


Thanks for the effort. However, the diagonalisation approach as applied here doesn't work for nonlinear systems. Indeed, using the product rule $$ \begin{bmatrix} \bar h\\ \bar k \end{bmatrix}_t = (R^{-1})_t \begin{bmatrix} h\\ hv \end{bmatrix} + R^{-1} \begin{bmatrix} h_t\\ (hv)_t \end{bmatrix} $$ and $$ D \begin{bmatrix} \bar h\\ \bar k \end{bmatrix}_x = D (R^{-1})_x \begin{bmatrix} h\\ hv \end{bmatrix} + D R^{-1} \begin{bmatrix} h_x\\ (hv)_x \end{bmatrix} , $$ which obviously gives $$ \begin{bmatrix} \bar h\\ \bar k \end{bmatrix}_t + D \begin{bmatrix} \bar h\\ \bar k \end{bmatrix}_x \neq \underbrace{ R^{-1} \left(\begin{bmatrix} h_t\\ (hv)_t \end{bmatrix} + J \begin{bmatrix} h_x\\ (hv)_x \end{bmatrix}\right) }_{= 0} $$ contrary to the linear case. Therefore, the quasi-linear diagonal system solved in OP isn't actually satisfied by the unknowns (except in the small-amplitude limit).

Nevertheless, an analytical solution may be derived by using the Riemann invariants $w^\mp = v \pm 2\sqrt{gh}$ corresponding to the characteristic speeds $\lambda^\mp = v \mp\sqrt{gh}$. The Riemann invariants $w^\mp$ are constant along their family of integral curves, and therefore also constant along the simple wave. A simple wave is a solution of the form $U(x,t) = U(\xi)$, where $U = (h, hv)^T$ and $$ \xi_t + \lambda^\mp(U(\xi)) \, \xi_x = 0 $$ (see Chapter 13 of Ref. [1]). Without using the previous concepts, one could try an Ansatz of the form $v = F(h)$, as proposed in this post where a similar system is solved analytically.

[1] RJ LeVeque, Finite-Volume Methods for Hyperbolic Problems, Cambridge University Press, 2002.