Sedov blast solution#

This example shows how to plot the analytical solution to the sedov blast

 9 import matplotlib.pyplot as plt
10 import numpy as np
11
12 import shamrock

Use shamrock documentation style for matplotlib

16 shamrock.matplotlib.set_shamrock_mpl_style()
23 x = np.linspace(0, 1, 300)
24 p = []
25 vr = []
26 rho = []
27 for i in range(len(x)):
28     _rho, _vr, _p = sedov_sol.get_value(x[i])
29     p.append(_p)
30     vr.append(_vr)
31     rho.append(_rho)
34 plt.plot(x, rho, label="rho")
35 plt.plot(x, vr, label="vr")
36 plt.plot(x, p, label="p")
37 plt.xlabel("r")
38 plt.legend()
39 plt.tight_layout()
40 plt.show()
run sedov soluce

Total running time of the script: (0 minutes 0.813 seconds)

Estimated memory usage: 159 MB

Gallery generated by Sphinx-Gallery