数学图形(2.5)Loxodrome曲线
这也是一种贴在球上的曲线
#http://www.mathcurve.com/courbes3d/loxodromie/sphereloxodromie.shtml
vertices = 1000
t = from (-PI*0.5) to (PI*0.5)
k = rand2(0, 2*PI)
r = 10
x = r*cos(t)/ch(k*t)
y = r*sin(t)/ch(k*t)
z = r*th(k*t)
这个曲线看上去很普通,不过将上述代码中的k改为一个维度输入:
vertices = D1:360 D2:100 u = from (-PI) to (PI) D1 v = from (-PI) to (PI) D2 r = 10 x = r*cos(u)/ch(v*u) y = r*sin(u)/ch(v*u) z = r*th(v*u)
生成一个有两个缺口的球: