Skip to content

Commit 42947dd

Browse files
author
Murilo Marinho
committed
[dq5,dq7] Added missing plot files to repository.
1 parent 776a2e9 commit 42947dd

4 files changed

Lines changed: 25487 additions & 24400 deletions

File tree

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
import matplotlib.pyplot as plt
2+
import numpy as np
3+
4+
def plot_td_dot_and_t_dot(np_stored_td_dot: np.array, np_stored_t_dot: np.array, np_stored_time: np.array):
5+
"""
6+
plot_td_dot_and_t_dot Example function to plot the task-space velocity
7+
and desired task-space velocity for the open-loop velocity controller
8+
"""
9+
10+
# x-axis
11+
ax1 = plt.subplot(1,3,1)
12+
plt.plot(np_stored_time,np_stored_td_dot[:,0])
13+
plt.plot(np_stored_time,np_stored_t_dot[:,0])
14+
plt.title('x-axis velocity')
15+
plt.ylabel('Velocity [m/s]')
16+
plt.ylim([-5, 5])
17+
plt.xlabel('Time [s]')
18+
ax1.legend(['desired','actual','Location','southeast'])
19+
20+
# y-axis
21+
ax2 = plt.subplot(1,3,2)
22+
plt.plot(np_stored_time,np_stored_td_dot[:,1])
23+
plt.plot(np_stored_time,np_stored_t_dot[:,1])
24+
plt.title('y-axis velocity')
25+
plt.ylabel('Velocity [m/s]')
26+
plt.ylim([-5, 5])
27+
plt.xlabel('Time [s]')
28+
ax2.legend(['desired','actual','Location','southeast'])
29+
30+
# z-axis
31+
ax3 = plt.subplot(1,3,3)
32+
plt.plot(np_stored_time,np_stored_td_dot[:,2])
33+
plt.plot(np_stored_time,np_stored_t_dot[:,2])
34+
plt.title('z-axis velocity')
35+
plt.ylabel('Velocity [m/s]')
36+
plt.ylim([-5, 5])
37+
plt.xlabel('Time [s]')
38+
ax3.legend(['desired','actual','Location','southeast'])
39+
40+

0 commit comments

Comments
 (0)