I want to plot phase properly in a 2d image using matlibplot and in particular the cyclic colormaps. I however get a weird line that I want to get rid of. Can anyone help me, I think there might be something wrong in the code. This is my code and the output:
def vortex(x,y,mux,muy):
return np.angle((x-mux)+1j*(y-mux))
x=np.linspace(0,1,101)
y=np.linspace(0,1,101)
xx, yy = np.meshgrid(x, y)
z=vortex(xx,yy,0.5,0.5)
pos=plt.imshow(z,'hsv')
plt.colorbar(pos)
plt.show()
This is the output image: you can see a line through the center: