如何制作等高线测绘的方位角曲线图

问题描述 投票:0回答:1

我正在开发一个机器人系统,在一篇论文中发现了这个有趣的图。

enter image description here

论文的题目是 "A Comparison of Robot Wrist Implementations for the iCub Humanoid".该图描述了机器人手腕的两个自由度的耦合。我想为我的应用做一些类似的事情,但我不知道从哪里开始,而且论文也没有解释它是如何做的.如果有人在过去做过类似的事情,我会非常感谢任何投入。

matplotlib plot robotics
1个回答
1
投票

这看起来就像一个演示什么 meshgrid 确实如此。 请注意,这里通常是 Z 在等高线图中,现在是 XY.

enter image description here

import numpy as np
import matplotlib.pyplot as plt

x = np.arange(-90, 91, 15)
X, Y = np.meshgrid(x, x)

fig, ax = plt.subplots(figsize=(5,5))
cs = ax.contour(X, Y, X, colors=['blue'], levels=x) # Z = X
ax.clabel(cs, inline=1, fontsize=7)
cs = ax.contour(X, Y, Y, colors=['red'], levels=x) # Z = Y
ax.clabel(cs, inline=1, fontsize=7)
© www.soinside.com 2019 - 2024. All rights reserved.