返回列表 回复 发帖
44# 榕坚
不知是不是UF中的算法与我们画板的算法有别,我们没找到二者的契合点。或者软件在运行代码时处理特殊,与画板有别。
位于mt.ufm
mt-attractor-julia {
; Mark Townsend, 29 Mar 1999
;
; Julia sets that bail out when the orbit reaches
; (hopefully) a periodic attractor. I iterate the
; critical point z = (0,0) before the main loop
; and test against the resulting value. In the
; hope of speeding the process up I include
; the option to give up the search when z
; grows too large.
;
init:
  w = 0
  u = #pixel
  int iter = 0
  if @no_bail
    while iter < @max
      w = w^2 + @c
      iter = iter + 1
    endwhile
  else
    while (iter <= @max) && (|u| < 10)
      w = w^2 + @c
      u = u^2 + @c
      iter = iter + 1
    endwhile
  endif  
  z = #pixel
loop:
  z = z^2 + @c  
bailout:
  |w - z| > @epsilon && |z| < @bailout
default:
  title = "Attractor Julia"
  maxiter = 1000
  periodicity = 0
  param c
    caption = "Julia seed"
    default = (-0.12,0.74)
  endparam
  param epsilon
    caption = "Epsilon"
    default = 1e-6
    hint = "This is the bailout value for convergent orbits."
  endparam
  param bailout
    caption = "Bailout value"
    default = 100.0
    hint = "This is the bailout value for divergent orbits."
  endparam
  param max
    caption = "Search maxiter"
    default = 100
    hint = "The is the maxiter value for the attractor \
           search."
  endparam  
  param no_bail
    caption = "Every pixel"
    default = false
    hint = "This determines whether to bailout of the attractor \
           search when z grows too large. Enable this when the \
           image is mainly inside."
  endparam  
switch:
  type = "mt-attractor-m"
  max = max
  epsilon = epsilon
  bailout = bailout
  no_bail = no_bail
}
我老是作不出此图。UF效果是:
Fractal2.jpg
我整出来的,五块较大的中间,只有两个中间出现帖图中的等势圈,而其它块没有。文件在学校里。
我按上面的程序做,为何中间没有方形等势圈,中间象撒了些星粒呢?象仙人掌。请看:
未命名.JPG
我重做一遍,还是这个问题,这是问题文件。
3.gsp (43.19 KB)
谢过榕坚兄帮忙找问题,原来问题与我前面做的分形一样,均出在阈值设置上。昨晚我也试着改变阈值,居然没扫出UF中的那图。按你后面帖的代码,造起来比我帖的原代码简单了许多,但效果一样,但是为何UF软件的发明人要在这范例中故弄玄虚呢,这实在令人费解。
Carr1484 {
; Updated for UF2 by Erik Reckase, Feb 2000
           ; Julia?
init:
  z=(pixel+pixel)/(sqr(1/pixel))
  c=((pixel-1.5)^1.637)/(z-1.2/pixel)
loop:
  z=(z*z+c)
  c=((1+flip(imag(sqrt(sin(c)))))*real(sqrt(tan(c)))/9+z)
bailout:
  |z| <=4
default:
  title = "Carr 1484"
  periodicity = 0
  maxiter = 500
  magn = 1.3
  center = (0,0)
  method = multipass
}
Fractal2.png
未命名.jpg
我搞了六遍,其中一遍有明显错误,后几遍整出的效果与此图差别较大,这是我扫出的文件:
carr1484a.gsp (55.01 KB)
原来是程序中的一步弄错了,昨天干了好几遍,居然没发现,今天小心翼翼地再作了一遍,对了。
未命名.jpg
Carr2129,接着的2130,充满魅力,可惜空操劳几个小时,未果。
不知何故,这与前面的分形结构完全相类,为何一个能成功,另一个总是历尽劫难而未成正果,奇哉怪也。
Fractal2.jpg
59# 榕坚
我主要是死在2129h上,接下来的2130应该不成问题。请问2129的制作要点是什么?我扫出的图是下图:
未命名(2).jpg
返回列表