一、一图一线
import numpy as np
import matplotlib.pyplot as plt
t1 = np.arange(0, 5, 0.1)
plt.plot(t1, t2, 'r--')
plt.show()
二、一图多线
import numpy as np
import matplotlib.pyplot as plt
t1 = np.arange(0, 5, 0.1)
t2 = np.arange(0, 10, 0.2)
plt.plot(t1, t2, 'r--')
plt.plot(t1, t3, 'b--')
plt.show()
三、多图一线
import numpy as np
import matplotlib.pyplot as plt
t1 = np.arange(0, 5, 0.1)
t2 = np.arange(0,