You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Unfortunately, the time rate of change of variables is very small at the moment and I suspect I am not normalizing correctly terms corresponding to g\partial_x h.
In other terms, I am missing the A term in the KleinGordon example.
If anybody has an idea, I would be most grateful.
The text was updated successfully, but these errors were encountered:
Hi
I had a quick look and I see two issues. One is as you mention, you are missing division by A in rhs terms that are not using forward, i.e., du_hat[:] = Cu*h_hat and dv_hat[:] = Cv*h_hat and dh_hat[:] = Chu*u_hat + Chv*v_hat. Note that forward here, with only Fourier bases, is just short for inner product divided by diagonal mass matrix, i.e., A. You can get A as A=inner(hh,hh_test) or simply A=(2*np.pi)**2. Second, you should expect min(du_hat) and min(dh_hat) to be zero, since these are in spectral space. What you ought to use is norms, like np.linalg.norm(u_hat).
Hope this helps.
Hi,
I am trying to build upon KleinGordon in order to setup a 1 layer shallow water model:
https://github.com/apatlpo/shenfun_trial/blob/master/swater_1L/swater_1L.py
Unfortunately, the time rate of change of variables is very small at the moment and I suspect I am not normalizing correctly terms corresponding to
g\partial_x h
.In other terms, I am missing the
A
term in the KleinGordon example.If anybody has an idea, I would be most grateful.
The text was updated successfully, but these errors were encountered: