数学图形(1.27) 花

特殊点的圆内轮旋线.生成花一样的图形,挺漂亮的.

相关软件参见:数学图形可视化工具,使用自己定义语法的脚本代码生成数学图形.该软件免费开源.QQ交流群: 367752815

#http://www.mathcurve.com/courbes2d/conchoidderosace/conchoidderosace.shtml
vertices = 12000
t = from 0 to (40*PI)
a = 10
#e = rand2(1, 10)
e = 1
n = rand2(0.1, 10)
p = a*(1 + e*cos(n*t))
x = p*cos(t)
y = p*sin(t)

另一种花的写法:

#http://www.mathcurve.com/courbes2d/folioide/folioide.shtml
vertices = 12000
t = from (-20*PI) to (20*PI)
e = rand2(0.1, 10)
a = 10 / e
i = rand_int2(2, 10)
j = rand_int2(1, 10)
n = i/j
p = a*(e*cos(n*t) + sign(t)*e*sqrt(1 - pow(cos(n*t), 2)))
x = p*cos(t)
y = p*sin(t)

 

 

 

 

posted on 2014-07-08 13:08  叶飞影  阅读(1322)  评论(0编辑  收藏  举报