clawpack / riemann_book

An interactive book about the Riemann problem for hyperbolic PDEs, using Jupyter notebooks.
BSD 3-Clause "New" or "Revised" License
266 stars 96 forks source link

Changed some figures and default t values of some notebooks #207

Closed maojrs closed 4 years ago

maojrs commented 4 years ago

Here I added some modifications following Randy's comments.

rjleveque commented 4 years ago

Some more suggestions:

  1. In the last cell of Shallow_water_approximate, maybe add a line to the def'n of plot_frame:

    plt.title('Depth h at t = %.2f' % t)
  2. In Euler_approximate, it would be nice if the plots generated by compare_solutions had a title t = ... below the "Waves in x-t plane" plot and on top of the density,velocity,pressure plots, but that seems perhaps hard to do and I didn't want to monkey with the code in utils/riemann_tools.py that makes these plots. The time is implicitly indicated by where the dashed line is in the x-t plot, maybe that's enough but it would be nice to indicate more clearly. Another possibility is to put it in the legend, e.g. "Exact at t=0.2" and "Roe at t=0.2".

  3. For the pdf version, if possible it would be nice if only the later time plot appeared and not the one at t=0 since it's rather boring and doesn't show more than can be deduced from the later time, and the pdf file is a bit figure-heavy in these chapters.

  4. I also think these 4 plots are too close together and it would be nice to have a bit of a gap between them for more clarity, though I don't feel strongly about that.

  5. In Euler_compare, for the W-C blast wave, the grid is so fine that plotting symbols with '-ob' and '-or' obscures the lines and it's impossible to compare them. Perhaps just use '-b' and '-r'?

  6. For the other plots in this notebook the dots are ok, but maybe a bit too large? Perhaps add markersize=4 to these plot commands.

maojrs commented 4 years ago

Randy, I just incorporated your suggestions. Summary of changes:

Happy to add more modifications if needed.

rjleveque commented 4 years ago

Looks good, thanks!