美丽的心形函数
1,使用docker 刚刚使用docker 安装了,TensorFlow 的环境: http://blog.csdn.net/freewebsys/article/details/70237003 发现上面的带了好多的画图的函数。于是研究起心型函数。 2,公式 使用np画图: from matplotlib import pyplot as plt import numpy as np size = 2 x = np.linspace(-size, size, 400) #print(x) #参考函数 http://www.guokr.com/post/498800/ plt.plot(x, np.sqrt(1-(np.abs(x)-1)*(np.abs(x)-1))) plt.plot(x, np.arccos(1-np.abs(x))-np.pi) plt.show() 效果: 3,数学公式 https://docs.scipy.org/doc/numpy/reference/routines.math.html 常用的 sin cos tan sqrt abs 等等都有。 可绘制...