December 2017
Intermediate to advanced
386 pages
10h 42m
English
Here, we have an one example to give away the details:
from scipy.integrate import solve_bvpres_a = solve_bvp(fun, bc, x, y_a)res_b = solve_bvp(fun, bc, x, y_b)x_plot = np.linspace(0, 1, 100)y_plot_a = res_a.sol(x_plot)[0]y_plot_b = res_b.sol(x_plot)[0]import matplotlib.pyplot as pltplt.plot(x_plot, y_plot_a, label='y_a')plt.plot(x_plot, y_plot_b, label='y_b')plt.legend()plt.xlabel("x")plt.ylabel("y")plt.show()
This is the result of the execution:

This is the code of the other solution:
x_plot = np.linspace(0, 1, 100)y_plot = res_b.sol(x_plot)[1]plt.plot(x_plot, y_plot)plt.xlabel("x")plt.ylabel("y")plt.show()
The final result ...
Read now
Unlock full access