From e5b77c7c0bb25f81dbe6f927dafd7cec8089ed9f Mon Sep 17 00:00:00 2001 From: Stein_van_vliet Date: Wed, 28 Feb 2024 16:47:32 +0100 Subject: [PATCH] acceleratie plot --- src/casus.py | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/casus.py b/src/casus.py index 5a8550d..6a821a1 100644 --- a/src/casus.py +++ b/src/casus.py @@ -19,6 +19,7 @@ time = 20 dt = 0.01 F_list = [] +a_list = [] v_list = [] s_list = [] t_list = [] @@ -36,12 +37,13 @@ for i in range(round(10/dt)): F_eff = (F_aan-F_rol-Fzt) F_list.append(F_eff) + a_list.append(a_kar) v_list.append(v_kar) s_list.append(s_kar) t_list.append(dt*i) #""" -# """ +""" #SCENARIO 2a Fn = Fz F_rol = Fn*mu_r @@ -57,6 +59,7 @@ for i in range(round(time/dt)): F_eff = (F_aan-F_rol) F_list.append(F_eff) + a_list.append(a_kar) v_list.append(v_kar) s_list.append(s_kar) t_list.append(dt*i) @@ -76,6 +79,7 @@ for i in range(round(10/dt)): F_eff = (F_aan-F_rol+Fzt) F_list.append(F_eff) + a_list.append(a_kar) v_list.append(v_kar) s_list.append(s_kar) t_list.append(dt*i) @@ -83,7 +87,8 @@ for i in range(round(10/dt)): plt.plot(t_list,F_list) +plt.plot(t_list,a_list) plt.plot(t_list,v_list) plt.plot(t_list,s_list) -plt.legend(['Kracht','Snelheid','Afstand']) +plt.legend(['Kracht','Acceleratie','Snelheid','Afstand']) plt.show() \ No newline at end of file