makeMotionFiles.py 文件源码

python
阅读 26 收藏 0 点赞 0 评论 0

项目:DW-POSSUM 作者: marksgraham 项目源码 文件源码
def plot_motion(motion_mat):
    time = motion_mat[:,0]
    plt.figure(figsize=(15,5))
    plt.subplot(1,2,1)
    plt.plot(time,motion_mat[:,1]* 1000,label='x')
    plt.plot(time,motion_mat[:,2]* 1000,label='y')
    plt.plot(time,motion_mat[:,3]* 1000,label='z')
    plt.xlabel('Time / s')
    plt.ylabel('Translation / mm')
    plt.legend()
    plt.subplot(1,2,2)
    plt.plot(time,np.degrees(motion_mat[:,4]),label='x')
    plt.plot(time,np.degrees(motion_mat[:,5]),label='y')
    plt.plot(time,np.degrees(motion_mat[:,6]),label='z')
    plt.ylabel('Rotations / degrees')
    plt.xlabel('Time / s')
    plt.legend()
    plt.show()
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号