我尝试绘制流线型,然后看到错误的结果。 我检查颤抖,然后得到正确的结果。 两者都使用相同的数据。为什么地块如此不同?
fig = plt.figure()
axs = plt.axes(polar=True)
axs.set_theta_zero_location("N")
axs.set_theta_direction(-1)
YL, ZL = zip(*list(zip(YLr,ZLr))/np.linalg.norm(list(zip(YLr,ZLr)),axis=1, keepdims=True))
YLi = scipy.interpolate.griddata(((np.radians(a_izogn), izogn)),YL,(a_izogn_rad_i[None,:], izogn_i[:,None]),method='cubic')
ZLi = scipy.interpolate.griddata(((np.radians(a_izogn), izogn)),ZL,(a_izogn_rad_i[None,:], izogn_i[:,None]),method='cubic')
r = izogn_i
phi = a_izogn_rad_i
r, phi = np.meshgrid(r, phi)
axs.streamplot(phi.transpose(), r.transpose(),ZLi, YLi, color='red',density=1, linewidth=0.5)
axs.quiver(phi.transpose(), r.transpose(), ZLi, YLi,units='xy',scale=10., zorder=3, color='blue',width=0.007, headwidth=3., headlength=4.)
axs.set_ylim([min(izogn_i), max(izogn_i)])
fig.show();