clawpack / riemann_book

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

Avoid plotting too-short arrows #245

Closed ketch closed 1 year ago

ketch commented 1 year ago

This removes a visual bug, shown in the attachment. In this visualization, short arrows go past where they should end. And one arrow is plotted with length zero, which seems to result in a vertical line. This PR just avoids plotting any arrows until there is enough space for them in the plot (second screenshot).

Screen Shot 2023-01-22 at 8 52 36 AM Screen Shot 2023-01-22 at 8 56 16 AM
rjleveque commented 1 year ago

Looks good thanks!

Presumably we should merge this and some other recent changes into the FA16 branch too, the one linked from the book.