Import these libraries (the sea coast just makes the graphics pretty).
from matplotlib import pyplot as plt
import seaborn as sns
import numpy as np
Then apply this to the end. This will determine the time, t, against speed, v (t).
func = lambdify(t, equation.rhs,'numpy')
xvals = np.arange(0,10,.1)
yvals = func(xvals)
fig, ax = plt.subplots(1,1,subplot_kw=dict(aspect='equal'))
ax.plot(xvals, yvals)
ax.set_xlabel('t')
ax.set_ylabel('v(t)')
plt.show()
I get such a graph for mass 2 and resistance coefficient 2.

source
share