使用python绘制标准心形线

#标准心形线r=sin(t)*sqrt(|cos(t)|)/(sin(t)+7/5)-2sin(t)+2
import math
import numpy as np
import matplotlib.pyplot as plt
r=[]
angle=[]
for i in np.arange(0,101):
    x=2*math.pi/100*i
    angle.append(x)
    y=(math.sin(x)*math.sqrt(abs(math.cos(x))))/(math.sin(x)+7/5)-2*math.sin(x)+2
    r.append(y)
fig=plt.figure()
ax1=fig.add_axes([0.1,0.1,0.8,0.8],projection='polar')
ax1.set_rgrids(np.arange(2,2,1))
ax1.set_rlabel_position(90)
ax1.plot(angle,r,'-r',linewidth=2.5)#lw=2.5
plt.savefig('heart1.png',dpi=600)
plt.show()