返回列表 回复 发帖
481# 榕坚


跟UF中的这种效果有点象,那个图形应该有经过改造:

Fractal3.JPG (56.38 KB)

Fractal3.JPG

490# changxde


没办法处理(0,0)^p,p∈C。在做的过程发现一个有趣的东西:atan(a/b),当a≠0,b=0时几何画板可以计算,而且计算结果没问题,可是计算a/b却出了问题,显示未定义。它的函数计算原理不明白。
又回来弄假3D,结果没处理好小M,失败了:

捕获.JPG (47.23 KB)

捕获.JPG

et对靠近M集处是不敏感的,我没用et来处理高度,用DEM中的到边界距离为参数。
无限风光在险峰,就是扫这幅图时发现画板一个有趣的问题,下半平面没了,保存完这幅图后重扫时发现再也扫不出来了:

7.JPG (16.14 KB)

7.JPG

499# mjj_ljh


下半部分空白,不知是不是几何画板的bug:http://www.inrm3d.cn/viewthread.php?tid=3376&extra=page%3D1
这种用到边界距离为参数的做法还是有不尽人意的地方,M集以外的部分会卷起来,我希望它是平的。继续改进中:

5'.JPG (35.29 KB)

5'.JPG

来一张特大图:

12.JPG (68.23 KB)

12.JPG

这是用et做为高度参数的结果:

4 (2).JPG (38.09 KB)

4 (2).JPG

506# xuefeiyang
有啊,不过很难用几何画板完成:
Slope_Apollonian {
; Ron Barnett April 23, 2005
; Implements the mapping algorithm of Susan Chambless
; Implements fBm in the global section using a noise array
; and modification of Damien's fBm code
; Circle perturbations added August 13, 2005
; improved duplicate removal code, November 18, 2005

global:
  int w = 0
  int h = 0
  float Inc = @percentInc*0.01
  float wd = Inc*#width
  float ht = Inc*#height
  int wd2 = round(wd*0.5)
  int ht2 = round(ht*0.5)
  float count[round(#width*(1+@percentInc*0.01)),round(#height*(1+@percentInc*0.01))]
  float agree = 100
  float thresh = @scircle/agree
  int l = 0
  int ir = 0
  int si = 0
  int sj = 0
  bool continue = true
  complex rra = 0
  float rrb = 0
  float c = 0
  float ddx = 0
  float fx = 0.0
  float ffx = 0.0
  float xx = 0.0
  float fy = 0.0
  float ffy = 0.0
  int px = 0
  int py = 0
  float cy = imag(#center)
  float cx = real(#center)
  float txmax = 4.0/#magn
  float tymax = txmax*#height/#width
  float xmin = cx - txmax/2
  float ymin = cy - tymax/2
  int MaxLevel = @level
  int level = MaxLevel
  complex cs[1000000]
  float rad[1000000]
  float ang = 2*#pi/3
  complex ipi = flip(#pi);
  float ar = 0
  float br = 0
  complex a = 0
  complex b = 0
  float temp = 0
  int ii = 0
  int i = 0
  int j = 0
  int k = 0
  int ib = 0
  int start = 0
  int finish = 0
  int lev = 2
  float ddx = 0
  float ddy = 0
  float ddr = 0
  int pert = @pert
  pert = 11 - pert
  float scle2 = 0
  float scle = 0
  if (@ptype == "None")
    scle = 2 + sqrt(3)
    scle2 = 1
  elseif (@ptype == "Outer Circles")
    scle = (2 + sqrt(3))*cos(#pi/(pert+6))
    scle2 = (scle-sqrt(3)-1.5)/0.5
  else  ; distance to origin for base spheres
    scle = 2 + sqrt(3)
    if pert == 10
      scle2 = 1.0041268407
    elseif pert == 9
      scle2 = 1.0049465720
    elseif pert == 8
      scle2 = 1.0060422243
    elseif pert == 7
      scle2 = 1.0075560883
    elseif pert == 6
      scle2 = 1.0097381547
    elseif pert == 5
      scle2 = 1.0130643119
    elseif pert == 4
      scle2 = 1.0185254
    elseif pert == 3
      scle2 = 1.0286754
    elseif pert == 2
      scle2 = 1.0515254
    elseif pert == 1
      scle2 = 1.1277437913
    endif
  endif
  int maxi
  float gsum[round(#width*(1+@percentInc*0.01)),round(#height*(1+@percentInc*0.01))]
  complex gr = (1,1)
  complex gr2 = (0,1) ^ 0.411111111111
  float gfreq = 1.0
  int gi = 0
  complex gp = 0
  float gbx0 = 0
  float gby0 = 0
  float gbx1 = 0
  float gby1 = 0
  float grx0 = 0
  float gry0 = 0
  float grx1 = 0
  float gry1 = 0
  float gb00 = 0
  float gb10 = 0
  float gb01 = 0
  float gb11 = 0
  float gg_b00_0 = 0
  float gg_b10_0 = 0
  float gg_b01_0 = 0
  float gg_b11_0 = 0
  float gg_b00_1 = 0
  float gg_b10_1 = 0
  float gg_b01_1 = 0
  float gg_b11_1 = 0
  float gd = 0.0
  float gu1 = 0
  float gv1 = 0
  float gu2 = 0
  float gv2 = 0
  float gsx = 0
  float gsy = 0
  float ga = 0
  float gb = 0
  complex gpixel=0
  complex gp = 0
  float fsum = 0


;
  while (h < #height+ht)
    while (w < #width+wd)
      gpixel = w/(#width+wd) + flip(h/(#height+ht))
      gp = gpixel * @gnscale * gr + @gnoffset
      gi = @giter
      gfreq = @gfreq
      gsum[w,h] = 0
      WHILE (gi > 0)
        gbx0 = floor(real(gp)) % 256
        gby0 = floor(imag(gp)) % 256
        IF (gbx0 < 0)
          gbx0 = gbx0 + 256
        ENDIF
        IF (gby0 < 0)
          gby0 = gby0 + 256
        ENDIF
        gbx1 = (gbx0 + 1) % 256
        gby1 = (gby0 + 1) % 256

        grx0 = real(gp) - floor(real(gp))
        gry0 = imag(gp) - floor(imag(gp))
        grx1 = grx0 - 1
        gry1 = gry0 - 1

        gb00 = (gbx0^2 % 65536 + gby0)^2 % 65536
        gb10 = (gbx1^2 % 65536 + gby0)^2 % 65536
        gb01 = (gbx0^2 % 65536 + gby1)^2 % 65536
        gb11 = (gbx1^2 % 65536 + gby1)^2 % 65536

       太长了,超出论坛权限,只截取一段。详见UF

Fractal1.jpg (30.59 KB)

Fractal1.jpg

返回列表