home *** CD-ROM | disk | FTP | other *** search
/ Computer Buyer 1996 June / BUYER_696.iso / features / fractal / fractint / fractint.frm < prev    next >
Text File  |  1995-03-08  |  38KB  |  1,577 lines

  1. comment {
  2.  This iteration of FRACTINT.FRM was first released with Fractint 19.0
  3.  
  4.  The formulas at the beginning of this file are from Mark Peterson, who
  5.  built this fractal interpreter feature.  The rest are grouped by contributor.
  6.  Formulas by unidentified authors are grouped at the end.
  7.  
  8.  If you would like to contribute formulas for future versions of this file,
  9.  please contact one of the authors listed in FRACTINT.DOC.
  10.  All contributions are assumed to belong to the public domain.
  11.  
  12.  There are several hard-coded restrictions in the formula interpreter:
  13.  
  14.  1) The fractal name through the open curly bracket must be on a single line.
  15.  2) There is a hard-coded limit of 2000 formulas per formula file, only
  16.     because of restrictions in the prompting routines.
  17.  3) Formulas can contain at most 250 operations (references to variables and
  18.     arithmetic); this is bigger than it sounds.
  19.  4) Comment blocks can be set up using dummy formulas with no formula name
  20.     or with the special name "comment".
  21.  
  22.  Note that the builtin "cos" function had a bug which was corrected in
  23.  version 16.  To recreate an image from a formula which used cos before
  24.  v16, change "cos" in the formula to "cosxx" which is a new function
  25.  provided for backward compatibility with that bug.
  26.  }
  27.  
  28. {--- MARK PETERSON -------------------------------------------------------}
  29.  
  30. Mandelbrot(XAXIS) {; Mark Peterson
  31.   ; Classical fractal showing LastSqr speedup
  32.   z = Pixel, z = Sqr(z):  ; Start with z**2 to initialize LastSqr
  33.    z = z + Pixel
  34.    z = Sqr(z)
  35.     LastSqr <= 4      ; Use LastSqr instead of recalculating
  36.   }
  37.  
  38. Dragon (ORIGIN) {; Mark Peterson
  39.   z = Pixel:
  40.    z = sqr(z) + (-0.74543, 0.2)
  41.     |z| <= 4
  42.   }
  43.  
  44. Daisy (ORIGIN) {; Mark Peterson
  45.   z = pixel:
  46.    z = z*z + (0.11031, -0.67037)
  47.     |z| <= 4
  48.   }
  49.  
  50. InvMandel (XAXIS) {; Mark Peterson
  51.   c = z = 1 / pixel:
  52.    z = sqr(z) + c
  53.     |z| <= 4
  54.   }
  55.  
  56. DeltaLog(XAXIS) {; Mark Peterson
  57.   z = pixel, c = log(pixel):
  58.    z = sqr(z) + c
  59.     |z| <= 4
  60.   }
  61.  
  62. Newton4(XYAXIS) {; Mark Peterson
  63.   ; Note that floating-point is required to make this compute accurately
  64.   z = pixel, Root = 1:
  65.    z3 = z*z*z
  66.    z4 = z3 * z
  67.    z = (3 * z4 + Root) / (4 * z3)
  68.     .004 <= |z4 - Root|
  69.   }
  70.  
  71. {--- DON ARCHER ----------------------------------------------------------}
  72.  
  73. DAFRM01 {;  Don Archer, 1993
  74.   z = pixel :
  75.    z = z ^ (z - 1) * (fn1(z) + pixel)
  76.     |z| <= 4
  77.   }
  78.  
  79. DAFRM07 {
  80.   z = pixel, c = p1 :
  81.    z = z ^ (z - 1) * fn1(z) + pixel
  82.     |z| <= 4
  83.   }
  84.  
  85. DAFRM09 {
  86.   z = pixel, c = z + z^ (z - 1):
  87.    tmp = fn1(z)
  88.    real(tmp) = real(tmp) * real(c) - imag(tmp) * imag(c)
  89.    imag(tmp) = real(tmp) * imag(c) - imag(tmp) * real(c)
  90.    z = tmp + pixel + 12
  91.     |z| <= 4
  92.   }
  93.  
  94. dafrm21 {
  95.   z = pixel:
  96.    x = real(z), y = imag(z)
  97.    x1 = -fn1((x*x*x + y*y*y - 1) - 6*x)*x/(2*x*x*x + y*y*y - 1)
  98.    y1 = -fn2((x*x*x + y*y*y - 1) + 6*x)*y/(2*x*x*x + y*y*y - 1)
  99.    x2 = x1*x1*x1 - y1*y1*y1 + p1 + 5
  100.    y2 = 4*x*y - 18
  101.    z = x2 + flip(y2)
  102.     |z| <= 100
  103.   }
  104.  
  105. 3daMand01 {; Mandelbrot/Zexpe via Lee Skinner
  106.   ; based on 4dFRACT.FRM by Gordon Lamb (CIS: 100272,3541)
  107.   z=real(pixel)+flip(imag(pixel)*p1)
  108.   c=p2+p1*real(pixel)+flip(imag(pixel)):
  109.    z=z^2.71828182845905 + c
  110.     |z|<=100
  111.   }
  112.  
  113. 3daMand02 {; Mandelbrot/Xexpe/Feigenbaum's alpha constant=exponent
  114.   ; based on 4dFRACT.FRM by Gordon Lamb (CIS: 100272,3541)
  115.   z=real(pixel)+flip(imag(pixel)*p1)
  116.   c=p2+p1*real(pixel)+flip(imag(pixel)):
  117.    z=z^2.502907875095 + c
  118.     |z|<=100
  119.   }
  120.  
  121. {--- RON BARNETT ---------------------------------------------------------}
  122.  
  123. Julike { ; Ron Barnett, 1993
  124.   ; a Julia function based upon the Ikenaga function
  125.   z = Pixel:
  126.    z = z*z*z + (P1-1)*z - P1
  127.     |z| <= 4
  128.   }
  129.  
  130. Mask { ; Ron Barnett, 1993
  131.   ; try fn1 = log, fn2 = sinh, fn3 = cosh
  132.   ;P1 = (0,1), P2 = (0,1)
  133.   ;Use floating point
  134.   z = fn1(pixel):
  135.    z = P1*fn2(z)^2 + P2*fn3(z)^2 + pixel
  136.     |z| <= 4
  137.   }
  138.  
  139. JMask {  ; Ron Barnett, 1993
  140.   z = fn1(pixel):
  141.    z = P1*fn2(z)^2 + P2
  142.     |z| <= 4
  143.   }
  144.  
  145. PseudoZeePi {; Ron Barnett, 1993
  146.   z = pixel:
  147.    x = 1-z^p1;
  148.    z = z*((1-x)/(1+x))^(1/p1) + p2
  149.     |z| <= 4
  150.   }
  151.  
  152. ZeePi {  ; Ron Barnett, 1993
  153.   ; This Julia function is based upon Ramanujan's iterative
  154.   ; function for calculating pi
  155.   z = pixel:
  156.    x = (1-z^p1)^(1/p1)
  157.    z = z*(1-x)/(1+x) + p2
  158.     |z| <= 4
  159.   }
  160.  
  161. IkeNewtMand {; Ron Barnett, 1993
  162.   z = c = pixel:
  163.    zf = z*z*z + (c-1)*z - c
  164.    zd = 3*z*z + c-1
  165.    z = z - p1*zf/zd
  166.     0.001 <= |zf|
  167.   }
  168.  
  169. Frame-RbtM(XAXIS) {; Ron Barnett, 1993
  170.   ; from Mazes for the Mind by Pickover
  171.   z = c = pixel:
  172.    z = z*z*z/5 + z*z + c
  173.     |z| <= 100
  174.   }
  175.  
  176. FrRbtGenM {; Ron Barnett, 1993
  177.   z = pixel:
  178.    z = p1*z*z*z + z*z + pixel
  179.     |z| <= 100
  180.   }
  181.  
  182. FlipLambdaJ { ; Ron Barnett, 1993
  183.   z = pixel:
  184.    z = p1*z*(1-flip(z)*flip(z))
  185.     |z| <= 100
  186.   }
  187.  
  188. REBRefInd2 {  ; Ron Barnett, 1993
  189.   ; Use floating point
  190.   z = pixel:
  191.    z = (z*z-1)/(z*z+2)*fn1(z)*fn2(z) + p1
  192.     |z| <= 100
  193.   }
  194.  
  195. GopalsamyFn {
  196.   z = pixel:
  197.    x = real(z), y = imag(z)
  198.    x1 = fn1(x)*fn2(y)
  199.    y1 = fn3(x)*fn4(y)
  200.    x2 = -2*x1*y1 + p1
  201.    y = y1*y1 - x1*x1
  202.    z = x2 + flip(y)
  203.     |z| <= 100
  204.   }
  205.  
  206. REB004A {; Ron Barnett, 1993
  207.   z = pixel:
  208.    z =p1*fn1(z) + p1*p1*fn2(p2*z) + pixel
  209.     |z| <= 100
  210.   }
  211.  
  212. REB004K {; Ron Barnett, 1993
  213.   ; floating point required
  214.   z = pixel:
  215.    x = flip(pixel + fn1(3/z - z/4))
  216.    z = x*z + p1
  217.     |z| <= 100
  218.   }
  219.  
  220. REB004L {; Ron Barnett, 1993
  221.   ; floating point required
  222.   z = pixel:
  223.    x = flip(pixel + fn1(p1/z - z/(p2+1)))
  224.    z = x*z + pixel
  225.     |z| <= 100
  226.   }
  227.  
  228. REB004M {; Ron Barnett, 1993
  229.   ; floating point required
  230.   z = pixel:
  231.    x = real(z), y = imag(z)
  232.    const = x*x + y*y
  233.    x1 = -fn1(const - 12*x)*x/(4*const)
  234.    y1 = -fn2(const + 12*x)*y/(4*const)
  235.    x2 = x1*x1 - y1*y1 + p1
  236.    y2 = 2*x*y
  237.    z = x2 + flip(y2)
  238.     |z| <= 100
  239.   }
  240.  
  241. REB005A {; Ron Barnett, 1993
  242.   ; floating point required
  243.   z = pixel:
  244.    x = real(z), y = imag(z)
  245.    const = x*x + y*y
  246.    x1 = -fn1(const - 12*x)*x/(4*const)
  247.    y1 = -fn2(const + 12*y)*y/(4*const)
  248.    x2 = x1*x1 - y1*y1 + p1
  249.    y2 = 2*x1*y1
  250.    z = x2 + flip(y2)
  251.     |z| <= 100
  252.   }
  253.  
  254. REB005E {; Ron Barnett, 1993
  255.   ; floating point required
  256.   z = pixel:
  257.    x = real(z), y = imag(z)
  258.    const = x*x + y*y
  259.    x1 = -fn1((const - x)*x/const)
  260.    y1 = -fn2((const + y)*y/const)
  261.    x2 = x1*x1 - y1*y1 + p1
  262.    y2 = 2*x1*y1
  263.    z = x2 + flip(y2)
  264.     |z| <= 100
  265.   }
  266.  
  267. REB005F {; Ron Barnett, 1993
  268.   ; floating point required
  269.   z = pixel:
  270.    x = real(z), y = imag(z)
  271.    const = x*x + y*y
  272.    x1 = -fn1((const - 12*x)*x/(4*const))
  273.    y1 = -fn2((const + 12*y)*y/(4*const))
  274.    x2 = x1*x1 - y1*y1 + p1
  275.    y2 = 2*x1*y1
  276.    z = x2 + flip(y2)
  277.     |z| <= 100
  278.   }
  279.  
  280. REB005G {; Ron Barnett, 1993
  281.   ; floating point required
  282.   z = pixel:
  283.    x = real(z), y = imag(z)
  284.    const = x*x + y*y
  285.    x1 = -fn1(const + p1*x)*y/const
  286.    y1 = -fn2(const + y)*x/const
  287.    x2 = x1*x1 - y1*y1 + p2
  288.    y2 = 2*x1*y1
  289.    z = x2 + flip(y2)
  290.     |z| <= 100
  291.   }
  292.  
  293.  
  294. {--- BRADLEY BEACHAM -----------------------------------------------------}
  295.  
  296. OK-01 { ;TRY P1 REAL = 10000, FN1 = SQR
  297.   z = 0, c = pixel:
  298.    z = (c^z) + c
  299.    z = fn1(z)
  300.     |z| <= (5 + p1)
  301.   }
  302.  
  303. OK-04 { ;TRY FN2 = SQR, DIFFERENT FUNCTIONS FOR FN1
  304.   z = 0, c = fn1(pixel):
  305.    z = fn2(z) + c
  306.     |z| <= (5 + p1)
  307.   }
  308.  
  309. OK-08 {
  310.   z = pixel, c = fn1(pixel):
  311.    z = z^z / fn2(z)
  312.    z = c / z
  313.     |z| <= (5 + p1)
  314.   }
  315.  
  316. OK-21 {
  317.   z = pixel, c = fn1(pixel):
  318.    z = fn2(z) + c
  319.     fn3(z) <= p1
  320.   }
  321.  
  322. OK-22 {
  323.   z = v = pixel:
  324.    v = fn1(v) * fn2(z)
  325.    z = fn1(z) / fn2(v)
  326.     |z| <= (5 + p1)
  327.   }
  328.  
  329. OK-32 {
  330.   z = y = x = pixel, k = 1 + p1:
  331.    a = fn1(z)
  332.    b = (a <= y) * ((a * k) + y)
  333.    e = (a > y) * ((a * k) + x)
  334.    x = y
  335.    y = z
  336.    z = b + e
  337.     |z| <= (5 + p2)
  338.   }
  339.  
  340. OK-34 {
  341.   z = pixel, c = (fn1(pixel) * p1):
  342.    x = abs(real(z))
  343.    y = abs(imag(z))
  344.    a = (x <= y) * (fn2(z) + y + c)
  345.    b = (x > y) * (fn2(z) + x + c)
  346.    z = a + b
  347.     |z| <= (10 + p2)
  348.   }
  349.  
  350. OK-35 {
  351.   z = pixel, k = 1 + p1:
  352.    v = fn1(z)
  353.    x = (z*v)
  354.    y = (z/v)
  355.    a = (|x| <= |y|) * ((z + y) * k)
  356.    b = (|x| > |y|) * ((z + x) * k)
  357.    z = fn2((a + b) * v) + v
  358.     |z| <= (10 + p2)
  359.   }
  360.  
  361. OK-36 { ; DISSECTED MANDELBROT
  362.   ; TO GENERATE "STANDARD" MANDELBROT, SET P1 = 0,0 & ALL FN = IDENT
  363.   z = pixel, cx = fn1(real(z)), cy = fn2(imag(z)), k = 2 + p1:
  364.    zx = real(z), zy = imag(z)
  365.    x = fn3(zx*zx - zy*zy) + cx
  366.    y = fn4(k * zx * zy) + cy
  367.    z = x + flip(y)
  368.     |z| <  (10 + p2)
  369.   }
  370.  
  371. OK-38 { ; DISSECTED CUBIC MANDELBROT
  372.   ; TO GENERATE "STANDARD" CUBIC MANDELBROT, SET P1 = 0,0 & ALL FN = IDENT
  373.   z = pixel,  cx = fn1(real(pixel)), cy = fn2(imag(pixel)), k = 3 + p1:
  374.    zx = real(z), zy = imag(z)
  375.    x = fn3(zx*zx*zx - k*zx*zy*zy) + cx
  376.    y = fn4(k*zx*zx*zy - zy*zy*zy) + cy
  377.    z =  x + flip(y)
  378.     |z| <  (4 + p2)
  379.   }
  380.  
  381. OK-42 { ; MUTATION OF FN + FN
  382.   z = pixel, p1x = real(p1)+1, p1y = imag(p1)+1
  383.   p2x = real(p2)+1, p2y = imag(p2)+1:
  384.    zx = real(z), zy = imag(z)
  385.    x = fn1(zx*p1x - zy*p1y) + fn2(zx*p2x - zy*p2y)
  386.    y = fn3(zx*p1y + zy*p1x) + fn4(zx*p2y + zy*p2x)
  387.    z = x + flip(y)
  388.     |z| <= 20
  389.   }
  390.  
  391. OK-43 { ; DISSECTED SPIDER
  392.   ; TO GENERATE "STANDARD" SPIDER, SET P1 = 0,0 & ALL FN = IDENT
  393.   z = c = pixel, k = 2 + p1:
  394.    zx = real(z), zy = imag(z)
  395.    cx = real(c), cy = imag(c)
  396.    x = fn1(zx*zx - zy*zy) + cx
  397.    y = fn2(k*zx*zy) + cy
  398.    z = x + flip(y)
  399.    c = fn3((cx + flip(cy))/k) + z
  400.     |z| <  (10 + p2)
  401.   }
  402.  
  403. Larry { ; Mutation of 'Michaelbrot' and 'Element'
  404.   ; Original formulas by Michael Theroux [71673,2767]
  405.   ; For 'Michaelbrot', set FN1 & FN2 =IDENT and P1 & P2 = default
  406.   ; For 'Element', set FN1=IDENT & FN2=SQR and P1 & P2 = default
  407.   ; p1 = Parameter (default 0.5,0), real(p2) = Bailout (default 4)
  408.   z = pixel
  409.   ; The next line sets c=default if p1=0, else c=p1
  410.   c = ((0.5,0) * (|p1|<=0) + p1)
  411.   ; The next line sets test=4 if real(p2)<=0, else test=real(p2)
  412.   test = (4 * (real(p2)<=0) + real(p2) * (0<p2)):
  413.    z = fn1(fn2(z*z)) + c
  414.     |z| <= test
  415.   }
  416.  
  417. Moe { ; Mutation of 'Zexpe'.
  418.   ; Original formula by Lee Skinner [75450,3631]
  419.   ; For 'Zexpe', set FN1 & FN2 =IDENT and P1 = default
  420.   ; real(p1) = Bailout (default 100)
  421.   s = exp(1.,0.), z = pixel, c = fn1(pixel)
  422.   ; The next line sets test=100 if real(p1)<=0, else test=real(p1)
  423.   test = (100 * (real(p1)<=0) + real(p1) * (0<p1)):
  424.    z = fn2(z)^s + c
  425.     |z| <= test
  426.   }
  427.  
  428. Groucho { ; Mutation of 'Fish2'.
  429.   ; Original formula by Dave Oliver via Tim Wegner
  430.   ; For 'Fish2', set FN1 & FN2 =IDENT and P1 & P2 = default
  431.   ; p1 = Parameter (default 1,0), real(p2) = Bailout (default 4)
  432.   z = c = pixel
  433.   ; The next line sets k=default if p1=0, else k=p1
  434.   k = ((1,0) * (|p1|<=0) + p1)
  435.   ; The next line sets test=4 if real(p2)<=0, else test=real(p2)
  436.   test = (4 * (real(p2)<=0) + real(p2) * (0<p2)):
  437.    z1 = c^(fn1(z)-k)
  438.    z = fn2(((c*z1)-k)*(z1))
  439.     |z| <= test
  440.   }
  441.  
  442. Zeppo { ; Mutation of 'Liar4'.
  443.   ; Original formula by Chuck Ebbert [76306,1226]
  444.   ; For 'Liar4' set FN1 & FN2 =IDENT and P1 & P2 = default
  445.   ; p1 & p2 = Parameters (default 1,0 and 0,0)
  446.   z = pixel
  447.   ; The next line sets p=default if p1=0, else p=p1
  448.   p = (1 * (|p1|<=0) + p1):
  449.    z =fn1(1-abs(imag(z)*p-real(z)))+flip(fn2(1-abs(1-real(z)-imag(z))))-p2
  450.     |z| <= 1
  451.   }
  452.  
  453. inandout02 {
  454.   ;p1 = Parameter (default 0), real(p2) = Bailout (default 4)
  455.   ;The next line sets test=4 if real(p2)<=0, else test=real(p2)
  456.   test = (4 * (real(p2)<=0) + real(p2) * (0<p2))
  457.   z = oldz = pixel:
  458.    a = (|z| <= |oldz|) * (fn1(z)) ;IN
  459.    b = (|oldz| < |z|) * (fn2(z))  ;OUT
  460.    oldz = z
  461.    z = a + b + p1
  462.     |z| <= test
  463.   }
  464.  
  465. inandout03 {
  466.   ;p1 = Parameter (default 0), real(p2) = Bailout (default 4)
  467.   ;The next line sets test=4 if real(p2)<=0, else test=real(p2)
  468.   test = (4 * (real(p2)<=0) + real(p2) * (0<p2))
  469.   z = oldz = c = pixel:
  470.    a = (|z| <= |oldz|) * (c)    ;IN
  471.    b = (|oldz| < |z|)  * (z*p1) ;OUT
  472.    c = fn1(a + b)
  473.    oldz = z
  474.    z = fn2(z*z) + c
  475.     |z| <= test
  476.   }
  477.  
  478. inandout04 {
  479.   ;p1 = Parameter (default 1), real(p2) = Bailout (default 4)
  480.   ;The next line sets k=default if p1=0, else k=p1
  481.   k = ((1) * (|p1|<=0) + p1)
  482.   ;The next line sets test=4 if real(p2)<=0, else test=real(p2)
  483.   test = (4 * (real(p2)<=0) + real(p2) * (0<p2))
  484.   z = oldz = c = pixel:
  485.    a = (|z| <= |oldz|) * (c)   ;IN
  486.    b = (|oldz| < |z|)  * (c*k) ;OUT
  487.    c = a + b
  488.    oldz = z
  489.    z = fn1(z*z) + c
  490.     |z| <= test
  491.   }
  492.  
  493.  
  494. {--- PIETER BRANDERHORST -------------------------------------------------}
  495.  
  496. { The following resulted from a FRACTINT bug. Version 13 incorrectly
  497.   calculated Spider (see above). We fixed the bug, and reverse-engineered
  498.   what it was doing to Spider - so here is the old "spider" }
  499.  
  500. Wineglass(XAXIS) {; Pieter Branderhorst
  501.   c = z = pixel:
  502.    z = z * z + c
  503.    c = (1+flip(imag(c))) * real(c) / 2 + z
  504.     |z| <= 4
  505.   }
  506.  
  507. {--- JM COLLARD-RICHARD --------------------------------------------------}
  508.  
  509. { These are the original "Richard" types sent by Jm Collard-Richard. Their
  510.   generalizations are tacked on to the end of the "Jm" list below, but
  511.   we felt we should keep these around for historical reasons.}
  512.  
  513. Richard1 (XYAXIS) {; Jm Collard-Richard
  514.   z = pixel:
  515.    sq=z*z, z=(sq*sin(sq)+sq)+pixel
  516.     |z|<=50
  517.   }
  518.  
  519. Richard2 (XYAXIS) {; Jm Collard-Richard
  520.   z = pixel:
  521.    z=1/(sin(z*z+pixel*pixel))
  522.     |z|<=50
  523.   }
  524.  
  525. Richard3 (XAXIS) {; Jm Collard-Richard
  526.   z = pixel:
  527.    sh=sinh(z), z=(1/(sh*sh))+pixel
  528.     |z|<=50
  529.   }
  530.  
  531. Richard4 (XAXIS) {; Jm Collard-Richard
  532.   z = pixel:
  533.    z2=z*z, z=(1/(z2*cos(z2)+z2))+pixel
  534.     |z|<=50
  535.   }
  536.  
  537. Richard5 (XAXIS) {; Jm Collard-Richard
  538.   z = pixel:
  539.    z=sin(z*sinh(z))+pixel
  540.     |z|<=50
  541.   }
  542.  
  543. Richard6 (XYAXIS) {; Jm Collard-Richard
  544.   z = pixel:
  545.    z=sin(sinh(z))+pixel
  546.     |z|<=50
  547.   }
  548.  
  549. Richard7 (XAXIS) {; Jm Collard-Richard
  550.   z=pixel:
  551.    z=log(z)*pixel
  552.     |z|<=50
  553.   }
  554.  
  555. Richard8 (XYAXIS) {; Jm Collard-Richard
  556.   ; This was used for the "Fractal Creations" cover
  557.   z=pixel,sinp = sin(pixel):
  558.    z=sin(z)+sinp
  559.     |z|<=50
  560.   }
  561.  
  562. Richard9 (XAXIS) {; Jm Collard-Richard
  563.   z=pixel:
  564.    sqrz=z*z, z=sqrz + 1/sqrz + pixel
  565.     |z|<=4
  566.   }
  567.  
  568. Richard10(XYAXIS) {; Jm Collard-Richard
  569.   z=pixel:
  570.    z=1/sin(1/(z*z))
  571.     |z|<=50
  572.   }
  573.  
  574. Richard11(XYAXIS) {; Jm Collard-Richard
  575.   z=pixel:
  576.    z=1/sinh(1/(z*z))
  577.     |z|<=50
  578.   }
  579.  
  580. { These types are generalizations of types sent to us by the French
  581.   mathematician Jm Collard-Richard. If we hadn't generalized them
  582.   there would be --ahhh-- quite a few. With 26 possible values for
  583.   each fn variable, Jm_03, for example, has 456,976 variations! }
  584.  
  585. Jm_01 {; generalized Jm Collard-Richard type
  586.   z=pixel,t=p1+4:
  587.    z=(fn1(fn2(z^pixel)))*pixel
  588.     |z|<=t
  589.   }
  590.  
  591. Jm_02 {; generalized Jm Collard-Richard type
  592.   z=pixel,t=p1+4:
  593.    z=(z^pixel)*fn1(z^pixel)
  594.     |z|<=t
  595.   }
  596.  
  597. Jm_03 {; generalized Jm Collard-Richard type
  598.   z=pixel,t=p1+4:
  599.    z=fn1((fn2(z)*pixel)*fn3(fn4(z)*pixel))*pixel
  600.     |z|<=t
  601.   }
  602.  
  603. Jm_03a {; generalized Jm Collard-Richard type
  604.   z=pixel,t=p1+4:
  605.    z=fn1((fn2(z)*pixel)*fn3(fn4(z)*pixel))+pixel
  606.     |z|<=t
  607.   }
  608.  
  609. Jm_04 {; generalized Jm Collard-Richard type
  610.   z=pixel,t=p1+4:
  611.    z=fn1((fn2(z)*pixel)*fn3(fn4(z)*pixel))
  612.     |z|<=t
  613.   }
  614.  
  615. Jm_05 {; generalized Jm Collard-Richard type
  616.   z=pixel,t=p1+4:
  617.    z=fn1(fn2((z^pixel)))
  618.     |z|<=t
  619.   }
  620.  
  621. Jm_06 {; generalized Jm Collard-Richard type
  622.   z=pixel,t=p1+4:
  623.    z=fn1(fn2(fn3((z^z)*pixel)))
  624.     |z|<=t
  625.   }
  626.  
  627. Jm_07 {; generalized Jm Collard-Richard type
  628.   z=pixel,t=p1+4:
  629.    z=fn1(fn2(fn3((z^z)*pixel)))*pixel
  630.     |z|<=t
  631.   }
  632.  
  633. Jm_08 {; generalized Jm Collard-Richard type
  634.   z=pixel,t=p1+4:
  635.    z=fn1(fn2(fn3((z^z)*pixel)))+pixel
  636.     |z|<=t
  637.   }
  638.  
  639. Jm_09 {; generalized Jm Collard-Richard type
  640.   z=pixel,t=p1+4:
  641.    z=fn1(fn2(fn3(fn4(z))))+pixel
  642.     |z|<=t
  643.   }
  644.  
  645. Jm_10 {; generalized Jm Collard-Richard type
  646.   z=pixel,t=p1+4:
  647.    z=fn1(fn2(fn3(fn4(z)*pixel)))
  648.     |z|<=t
  649.   }
  650.  
  651. Jm_11 {; generalized Jm Collard-Richard type
  652.   z=pixel,t=p1+4:
  653.    z=fn1(fn2(fn3(fn4(z)*pixel)))*pixel
  654.     |z|<=t
  655.   }
  656.  
  657. Jm_11a {; generalized Jm Collard-Richard type
  658.   z=pixel,t=p1+4:
  659.    z=fn1(fn2(fn3(fn4(z)*pixel)))+pixel
  660.     |z|<=t
  661.   }
  662.  
  663. Jm_12 {; generalized Jm Collard-Richard type
  664.   z=pixel,t=p1+4:
  665.    z=fn1(fn2(fn3(z)*pixel))
  666.     |z|<=t
  667.   }
  668.  
  669. Jm_13 {; generalized Jm Collard-Richard type
  670.   z=pixel,t=p1+4:
  671.    z=fn1(fn2(fn3(z)*pixel))*pixel
  672.     |z|<=t
  673.   }
  674.  
  675. Jm_14 {; generalized Jm Collard-Richard type
  676.   z=pixel,t=p1+4:
  677.    z=fn1(fn2(fn3(z)*pixel))+pixel
  678.     |z|<=t
  679.   }
  680.  
  681. Jm_15 {; generalized Jm Collard-Richard type
  682.   z=pixel,t=p1+4:
  683.    f2=fn2(z),z=fn1(f2)*fn3(fn4(f2))*pixel
  684.     |z|<=t
  685.   }
  686.  
  687. Jm_16 {; generalized Jm Collard-Richard type
  688.   z=pixel,t=p1+4:
  689.    f2=fn2(z),z=fn1(f2)*fn3(fn4(f2))+pixel
  690.     |z|<=t
  691.   }
  692.  
  693. Jm_17 {; generalized Jm Collard-Richard type
  694.   z=pixel,t=p1+4:
  695.    z=fn1(z)*pixel*fn2(fn3(z))
  696.     |z|<=t
  697.   }
  698.  
  699. Jm_18 {; generalized Jm Collard-Richard type
  700.   z=pixel,t=p1+4:
  701.    z=fn1(z)*pixel*fn2(fn3(z)*pixel)
  702.     |z|<=t
  703.   }
  704.  
  705. Jm_19 {; generalized Jm Collard-Richard type
  706.   z=pixel,t=p1+4:
  707.    z=fn1(z)*pixel*fn2(fn3(z)+pixel)
  708.     |z|<=t
  709.   }
  710.  
  711. Jm_20 {; generalized Jm Collard-Richard type
  712.   z=pixel,t=p1+4:
  713.    z=fn1(z^pixel)
  714.     |z|<=t
  715.   }
  716.  
  717. Jm_21 {; generalized Jm Collard-Richard type
  718.   z=pixel,t=p1+4:
  719.    z=fn1(z^pixel)*pixel
  720.     |z|<=t
  721.   }
  722.  
  723. Jm_22 {; generalized Jm Collard-Richard type
  724.   z=pixel,t=p1+4:
  725.    sq=fn1(z), z=(sq*fn2(sq)+sq)+pixel
  726.     |z|<=t
  727.   }
  728.  
  729. Jm_23 {; generalized Jm Collard-Richard type
  730.   z=pixel,t=p1+4:
  731.    z=fn1(fn2(fn3(z)+pixel*pixel))
  732.     |z|<=t
  733.   }
  734.  
  735. Jm_24 {; generalized Jm Collard-Richard type
  736.   z=pixel,t=p1+4:
  737.    z2=fn1(z), z=(fn2(z2*fn3(z2)+z2))+pixel
  738.     |z|<=t
  739.   }
  740.  
  741. Jm_25 {; generalized Jm Collard-Richard type
  742.   z=pixel,t=p1+4:
  743.    z=fn1(z*fn2(z)) + pixel
  744.     |z|<=t
  745.   }
  746.  
  747. Jm_26 {; generalized Jm Collard-Richard type
  748.   z=pixel,t=p1+4:
  749.    z=fn1(fn2(z)) + pixel
  750.     |z|<=t
  751.   }
  752.  
  753. Jm_27 {; generalized Jm Collard-Richard type
  754.   z=pixel,t=p1+4:
  755.    sqrz=fn1(z), z=sqrz + 1/sqrz + pixel
  756.     |z|<=t
  757.   }
  758.  
  759. Jm_ducks(XAXIS) {; Jm Collard-Richard
  760.   ; Not so ugly at first glance and lot of corners to zoom in.
  761.   ; try this: corners=-1.178372/-0.978384/-0.751678/-0.601683
  762.   z=pixel,tst=p1+4,t=1+pixel:
  763.    z=sqr(z)+t
  764.     |z|<=tst
  765.   }
  766.  
  767. Gamma(XAXIS) { ; first order gamma function from Prof. Jm
  768.   ; "It's pretty long to generate even on a 486-33 comp but there's a lot
  769.   ; of corners to zoom in and zoom and zoom...beautiful pictures :)"
  770.   z=pixel,twopi=6.283185307179586,r=10:
  771.    z=(twopi*z)^(0.5)*(z^z)*exp(-z)+pixel
  772.     |z|<=r
  773.   }
  774.  
  775. ZZ(XAXIS) { ; Prof Jm using Newton-Raphson method
  776.   ; use floating point with this one
  777.   z=pixel,solution=1:
  778.    z1=z^z
  779.    z2=(log(z)+1)*z1
  780.    z=z-(z1-1)/z2
  781.     0.001 <= |solution-z1|
  782.   }
  783.  
  784. ZZa(XAXIS) { ; Prof Jm using Newton-Raphson method
  785.   ; use floating point with this one
  786.   z=pixel,solution=1:
  787.    z1=z^(z-1)
  788.    z2=(((z-1)/z)+log(z))*z1
  789.    z=z-((z1-1)/z2)
  790.     .001 <= |solution-z1|
  791.   }
  792.  
  793. GenInvMand1_N { ; Jm Collard-Richard
  794.   c=z=1/pixel:
  795.    z=fn1(z)*fn2(z)+fn3(fn4(c))
  796.     |z|<=4
  797.   }
  798.  
  799.  
  800. {--- W. LEROY DAVIS ------------------------------------------------------}
  801.  
  802. { These are from: "AKA MrWizard W. LeRoy Davis;SM-ALC/HRUC"
  803.       davisl@sm-logdis1-aflc.af.mil
  804.   The first 3 are variations of:
  805.          z
  806.      gamma(z) = (z/e) * sqrt(2*pi*z) * R
  807. }
  808.  
  809. Sterling(XAXIS) {; davisl
  810.   z = Pixel:
  811.    z = ((z/2.7182818)^z)/sqr(6.2831853*z)
  812.     |z| <= 4
  813.   }
  814.  
  815. Sterling2(XAXIS) {; davisl
  816.   z = Pixel:
  817.    z = ((z/2.7182818)^z)/sqr(6.2831853*z) + pixel
  818.     |z| <= 4
  819.   }
  820.  
  821. Sterling3(XAXIS) {; davisl
  822.   z = Pixel:
  823.    z = ((z/2.7182818)^z)/sqr(6.2831853*z) - pixel
  824.     |z| <= 4
  825.   }
  826.  
  827. PsudoMandel(XAXIS) {; davisl - try center=0,0/magnification=28
  828.   z = Pixel:
  829.    z = ((z/2.7182818)^z)*sqr(6.2831853*z) + pixel
  830.     |z| <= 4
  831.   }
  832.  
  833. {--- ROB DEN BRAASEM -----------------------------------------------------}
  834.  
  835. J_TchebychevC3 {
  836.   c = pixel, z = P1:
  837.    z = c*z*(z*z-3)
  838.     |z|<100
  839.   }
  840.  
  841. J_TchebychevC7 {
  842.   c = pixel, z = P1:
  843.    z = c*z*(z*z*(z*z*(z*z-7)+14)-7)
  844.     |z|<100
  845.   }
  846.  
  847. J_TchebychevS4 {
  848.   c = pixel, z = P1:
  849.    z = c*(z*z*(z*z-3)+1)
  850.     |z|<100
  851.   }
  852.  
  853. J_TchebychevS6 {
  854.   c = pixel, z = P1:
  855.    z = c*(z*z*(z*z*(z*z-5)+6)-1)
  856.     |z|<100
  857.   }
  858.  
  859. J_TchebychevS7 {
  860.   c = pixel, z = P1:
  861.    z = c*z*(z*z*(z*z*(z*z-6)+10)-4)
  862.     |z|<100
  863.   }
  864.  
  865. J_Laguerre2 {
  866.   c = pixel, z = P1:
  867.    z = (z*(z - 4) +2 ) / 2 + c
  868.     |z| < 100
  869.   }
  870.  
  871. J_Laguerre3 {
  872.   c = pixel, z = P1:
  873.    z = (z*(z*(-z + 9) -18) + 6 ) / 6 + c
  874.     |z| < 100
  875.   }
  876.  
  877. J_Lagandre4 {
  878.   c = pixel, z = P1:
  879.    z = (z*z*(35 * z*z - 30) + 3) / 8 + c
  880.     |z| < 100
  881.   }
  882.  
  883. M_TchebychevT5 {
  884.   c = P1, z = Pixel:
  885.    z = c*(z*(z*z*(16*z*z-20)+5))
  886.     |z|<100
  887.   }
  888.  
  889. M_TchebychevC5 {
  890.   c = P1, z = Pixel:
  891.    z = c*z*(z*z*(z*z-5)+5)
  892.     |z|<100
  893.   }
  894.  
  895. M_TchebychevU3 {
  896.   c = P1, z = Pixel:
  897.    z = c*z*(8*z*z-4)
  898.     |z|<100
  899.   }
  900.  
  901. M_TchebychevS3 {
  902.   c = P1, z = Pixel:
  903.    z = c*z*(z*z-2)
  904.     |z|<100
  905.   }
  906.  
  907. M_Lagandre2 {
  908.   c = P1, z = Pixel:
  909.    z = (3 * z*z - 1) / 2 + c
  910.     |z| < 100
  911.   }
  912.  
  913. M_Lagandre6 {
  914.   c = P1, z = Pixel:
  915.    z = (z*z*(z*z*(231 * z*z - 315)  + 105 ) - 5) / 16 + c
  916.     |z| < 100
  917.   }
  918.  
  919.  
  920. {--- CHUCK EBBERT & JON HORNER -------------------------------------------}
  921.  
  922. comment {
  923.   Chaotic Liar formulas for FRACTINT. These formulas reproduce some of the
  924.   pictures in the paper 'Pattern and Chaos: New Images in the Semantics of
  925.   Paradox' by Gary Mar and Patrick Grim of the Department of Philosophy,
  926.   SUNY at Stony Brook. "...what is being graphed within the unit square is
  927.   simply information regarding the semantic behavior for different inputs
  928.   of a pair of English sentences:"
  929.   }
  930.  
  931. Liar1 { ; by Chuck Ebbert.
  932.   ; X: X is as true as Y
  933.   ; Y: Y is as true as X is false
  934.   ; Calculate new x and y values simultaneously.
  935.   ; y(n+1)=abs((1-x(n) )-y(n) ), x(n+1)=1-abs(y(n)-x(n) )
  936.   z = pixel:
  937.    z = 1 - abs(imag(z)-real(z) ) + flip(1 - abs(1-real(z)-imag(z) ) )
  938.     |z| <= 1
  939.   }
  940.  
  941. Liar3 { ; by Chuck Ebbert.
  942.   ; X: X is true to P1 times the extent that Y is true
  943.   ; Y: Y is true to the extent that X is false.
  944.   ; Sequential reasoning.  P1 usually 0 to 1.  P1=1 is Liar2 formula.
  945.   ; x(n+1) = 1 - abs(p1*y(n)-x(n) );
  946.   ; y(n+1) = 1 - abs((1-x(n+1) )-y(n) );
  947.   z = pixel:
  948.    x = 1 - abs(imag(z)*real(p1)-real(z) )
  949.    z = flip(1 - abs(1-real(x)-imag(z) ) ) + real(x)
  950.     |z| <= 1
  951.   }
  952.  
  953. Liar4 { ; by Chuck Ebbert.
  954.   ; X: X is as true as (p1+1) times Y
  955.   ; Y: Y is as true as X is false
  956.   ; Calculate new x and y values simultaneously.
  957.   ; Real part of p1 changes probability.  Use floating point.
  958.   ; y(n+1)=abs((1-x(n) )-y(n) ), x(n+1)=1-abs(y(n)-x(n) )
  959.   z = pixel, p = p1 + 1:
  960.    z = 1-abs(imag(z)*p-real(z))+flip(1-abs(1-real(z)-imag(z)))
  961.     |z| <= 1
  962.   }
  963.  
  964. F'Liar1 { ; Generalization by Jon Horner of Chuck Ebbert formula.
  965.   ; X: X is as true as Y
  966.   ; Y: Y is as true as X is false
  967.   ; Calculate new x and y values simultaneously.
  968.   ; y(n+1)=abs((1-x(n) )-y(n) ), x(n+1)=1-abs(y(n)-x(n) )
  969.   z = pixel:
  970.    z = 1 - abs(imag(z)-real(z) ) + flip(1 - abs(1-real(z)-imag(z) ) )
  971.     fn1(abs(z))<p1
  972.   }
  973.  
  974. M-SetInNewton(XAXIS) {; use float=yes
  975.   ; jon horner 100112,1700, 12 feb 93
  976.   z = 0,  c = pixel,  cminusone = c-1:
  977.    oldz = z, nm = 3*c-2*z*cminusone, dn = 3*(3*z*z+cminusone)
  978.    z = nm/dn+2*z/3
  979.     |(z-oldz)|>=|0.01|
  980.   }
  981.  
  982. F'M-SetInNewtonA(XAXIS) {; use float=yes
  983.   ; jon horner 100112,1700, 12 feb 93
  984.   z = 0,  c = fn1(pixel),  cminusone = c-1:
  985.    oldz = z, nm = p1*c-2*z*cminusone, dn = p1*(3*z*z+cminusone)
  986.    z = nm/dn+2*z/p1
  987.     |(z-oldz)|>=|0.01|
  988.   }
  989.  
  990. F'M-SetInNewtonC(XAXIS) { ; same as F'M-SetInNewtonB except for bailout
  991.   ; use float=yes, periodicity=no
  992.   ; (3 <= p1 <= ?) and (1e-30 < p2 < .01)
  993.   z=0, c=fn1(pixel), cm1=c-1, cm1x2=cm1*2, twoop1=2/p1, p1xc=c*real(p1):
  994.    z = (p1xc - z*cm1x2 )/( (sqr(z)*3 + cm1 ) * real(p1) ) + z*real(twoop1)
  995.     abs(|z| - real(lastsqr) ) >= p2
  996.   }
  997.  
  998.  
  999. {--- CHRIS GREEN ---------------------------------------------------------}
  1000.  
  1001. comment {
  1002.   These fractals all use Newton's or Halley's formula for approximation of
  1003.   a function.  In all of these fractals, p1 real is the "relaxation
  1004.   coefficient". A value of 1 gives the conventional newton or halley
  1005.   iteration. Values <1 will generally produce less chaos than values >1.
  1006.   1-1.5 is probably a good range to try.  P1 imag is the imaginary
  1007.   component of the relaxation coefficient, and should be zero but maybe a
  1008.   small non-zero value will produce something interesting.  Who knows?
  1009.   For more information on Halley maps, see "Computers, Pattern, Chaos, and
  1010.   Beauty" by Pickover.
  1011.   }
  1012.  
  1013. Halley (XYAXIS) {; Chris Green. Halley's formula applied to x^7-x=0.
  1014.   ; P1 real usually 1 to 1.5, P1 imag usually zero. Use floating point.
  1015.   ; Setting P1 to 1 creates the picture on page 277 of Pickover's book
  1016.   z=pixel:
  1017.    z5=z*z*z*z*z
  1018.    z6=z*z5
  1019.    z7=z*z6
  1020.    z=z-p1*((z7-z)/ ((7.0*z6-1)-(42.0*z5)*(z7-z)/(14.0*z6-2)))
  1021.     0.0001 <= |z7-z|
  1022.   }
  1023.  
  1024. CGhalley (XYAXIS) {; Chris Green -- Halley's formula
  1025.   ; P1 real usually 1 to 1.5, P1 imag usually zero. Use floating point.
  1026.   z=(1,1):
  1027.    z5=z*z*z*z*z
  1028.    z6=z*z5
  1029.    z7=z*z6
  1030.    z=z-p1*((z7-z-pixel)/ ((7.0*z6-1)-(42.0*z5)*(z7-z-pixel)/(14.0*z6-2)))
  1031.     0.0001 <= |z7-z-pixel|
  1032.   }
  1033.  
  1034. halleySin (XYAXIS) {; Chris Green. Halley's formula applied to sin(x)=0.
  1035.   ; Use floating point.
  1036.   ; P1 real = 0.1 will create the picture from page 281 of Pickover's book.
  1037.   z=pixel:
  1038.    s=sin(z), c=cos(z)
  1039.    z=z-p1*(s/(c-(s*s)/(c+c)))
  1040.     0.0001 <= |s|
  1041.   }
  1042.  
  1043. NewtonSinExp (XAXIS) {; Chris Green
  1044.   ; Newton's formula applied to sin(x)+exp(x)-1=0.
  1045.   ; Use floating point.
  1046.   z=pixel:
  1047.    z1=exp(z)
  1048.    z2=sin(z)+z1-1
  1049.    z=z-p1*z2/(cos(z)+z1)
  1050.     .0001 < |z2|
  1051.   }
  1052.  
  1053. CGNewtonSinExp (XAXIS) {
  1054.   z=pixel:
  1055.    z1=exp(z)
  1056.    z2=sin(z)+z1-z
  1057.    z=z-p1*z2/(cos(z)+z1)
  1058.     .0001 < |z2|
  1059.   }
  1060.  
  1061. CGNewton3 {; Chris Green -- A variation on newton iteration.
  1062.   ; The initial guess is fixed at (1,1), but the equation solved
  1063.   ; is different at each pixel ( x^3-pixel=0 is solved).
  1064.   ; Use floating point.
  1065.   ; Try P1=1.8.
  1066.   z=(1,1):
  1067.    z2=z*z
  1068.    z3=z*z2
  1069.    z=z-p1*(z3-pixel)/(3.0*z2)
  1070.     0.0001 < |z3-pixel|
  1071.   }
  1072.  
  1073. HyperMandel {; Chris Green.
  1074.   ; A four dimensional version of the mandelbrot set.
  1075.   ; Use P1 to select which two-dimensional plane of the
  1076.   ; four dimensional set you wish to examine.
  1077.   ; Use floating point.
  1078.   a=(0,0),b=(0,0):
  1079.    z=z+1
  1080.    anew=sqr(a)-sqr(b)+pixel
  1081.    b=2.0*a*b+p1
  1082.    a=anew
  1083.     |a|+|b| <= 4
  1084.   }
  1085.  
  1086. OldHalleySin (XYAXIS) {
  1087.   z=pixel:
  1088.    s=sin(z)
  1089.    c=cosxx(z)
  1090.    z=z-p1*(s/(c-(s*s)/(c+c)))
  1091.     0.0001 <= |s|
  1092.   }
  1093.  
  1094.  
  1095. {--- RICHARD HUGHES ------------------------------------------------------}
  1096.  
  1097. phoenix_m { ; Mandelbrot style map of the Phoenix curves
  1098.   z=x=y=nx=ny=x1=y1=x2=y2=0:
  1099.    x2 = sqr(x), y2 = sqr(y)
  1100.    x1 = x2 - y2 + real(pixel) + imag(pixel) * nx
  1101.    y1 = 2 * x * y + imag(pixel) * ny
  1102.    nx=x, ny=y, x=x1, y=y1, z=x + flip(y)
  1103.     |z| <= 4
  1104.   }
  1105.  
  1106.  
  1107. {--- GORDON LAMB ---------------------------------------------------------}
  1108.  
  1109. SJMAND01 {;Mandelbrot
  1110.   z=real(pixel)+flip(imag(pixel)*p1)
  1111.   c=p2+p1*real(pixel)+flip(imag(pixel)):
  1112.    z=z*z+c
  1113.     |z|<=64
  1114.   }
  1115.  
  1116. 3RDIM01 {;Mandelbrot
  1117.   z=p1*real(pixel)+flip(imag(pixel))
  1118.   c=p2+real(pixel)+flip(imag(pixel)*p1):
  1119.    z=z*z+c
  1120.     |z|<=64
  1121.   }
  1122.  
  1123. SJMAND03 {;Mandelbrot function
  1124.   z=real(pixel)+p1*(flip(imag(pixel)))
  1125.   c=p2+p1*real(pixel)+flip(imag(pixel)):
  1126.    z=fn1(z)+c
  1127.     |z|<=64
  1128.   }
  1129.  
  1130. SJMAND05 {;Mandelbrot lambda function
  1131.   z=real(pixel)+flip(imag(pixel)*p1)
  1132.   c=p2+p1*real(pixel)+flip(imag(pixel)):
  1133.    z=fn1(z)*c
  1134.     |z|<=64
  1135.   }
  1136.  
  1137. 3RDIM05 {;Mandelbrot lambda function
  1138.   z=p1*real(pixel)+flip(imag(pixel))
  1139.   c=p2+real(pixel)+flip(imag(pixel)*p1):
  1140.    z=fn1(z)*c
  1141.     |z|<=64
  1142.   }
  1143.  
  1144. SJMAND10 {;Mandelbrot power function
  1145.   z=real(pixel),c=p2+flip(imag(pixel)):
  1146.    z=(fn1(z)+c)^p1
  1147.     |z|<=4
  1148.   }
  1149.  
  1150. SJMAND11 {;Mandelbrot lambda function - lower bailout
  1151.   z=real(pixel)+flip(imag(pixel)*p1)
  1152.   c=p2+p1*real(pixel)+flip(imag(pixel)):
  1153.    z=fn1(z)*c
  1154.     |z|<=4
  1155.   }
  1156.  
  1157.  
  1158. {--- KEVIN LEE -----------------------------------------------------------}
  1159.  
  1160. LeeMandel1(XYAXIS) {; Kevin Lee
  1161.   z=Pixel:
  1162. ;; c=sqr(pixel)/z, c=z+c, z=sqr(z),  this line was an error in v16
  1163.    c=sqr(pixel)/z, c=z+c, z=sqr(c)
  1164.     |z|<4
  1165.   }
  1166.  
  1167. LeeMandel2(XYAXIS) {; Kevin Lee
  1168.   z=Pixel:
  1169.    c=sqr(pixel)/z, c=z+c, z=sqr(c*pixel)
  1170.     |z|<4
  1171.    }
  1172.  
  1173. LeeMandel3(XAXIS) {; Kevin Lee
  1174.   z=Pixel, c=Pixel-sqr(z):
  1175.    c=Pixel+c/z, z=c-z*pixel
  1176.     |z|<4
  1177.   }
  1178.  
  1179. {--- RON LEWEN -----------------------------------------------------------}
  1180.  
  1181. RCL_Cross1 { ; Ron Lewen
  1182.   ; Try p1=(0,1), fn1=sin and fn2=sqr.  Set corners at
  1183.   ; -10/10/-7.5/7.5 to see a cross shape.  The larger 
  1184.   ; lakes at the center of the cross have good detail
  1185.   ; to zoom in on.
  1186.   ; Use floating point.
  1187.   z=pixel:
  1188.    z=p1*fn1(fn2(z+p1))
  1189.     |z| <= 4
  1190.   }
  1191.  
  1192. RCL_Pick13 { ; Ron Lewen
  1193.   ;  Formula from Frontpiece for Appendix C 
  1194.   ;  and Credits in Pickover's book.
  1195.   ;  Set p1=(3,0) to generate the Frontpiece
  1196.   ;  for Appendix C and to (2,0) for Credits
  1197.   ;  Use Floating Point
  1198.   z=.001:
  1199.    z=z^p1+(1/pixel)^p1
  1200.     |z| <= 100
  1201.   }
  1202.  
  1203. RCL_1 (XAXIS) { ; Ron Lewen
  1204.   ;  An interesting Biomorph inspired by Pickover's
  1205.   ;  Computers, Pattern, Choas and Beauty.
  1206.   ;  Use Floating Point
  1207.   z=pixel:
  1208.    z=pixel/z-z^2
  1209.     |real(z)| <= 100 || |imag(z)| <= 100
  1210.   }
  1211.  
  1212. RCL_Cosh (XAXIS) { ; Ron Lewen, 76376,2567
  1213.   ; Try corners=2.008874/-3.811126/-3.980167/3.779833/
  1214.   ; -3.811126/3.779833 to see Figure 9.7 (P. 123) in 
  1215.   ; Pickover's Computers, Pattern, Chaos and Beauty.
  1216.   ; Figures 9.9 - 9.13 can be found by zooming.
  1217.   ; Use floating point
  1218.   z=0:
  1219.    z=cosh(z) + pixel
  1220.     abs(z) < 40
  1221.   }
  1222.  
  1223. Mothra (XAXIS) { ; Ron Lewen, 76376,2567
  1224.   ; Remember Mothra, the giant Japanese-eating moth?
  1225.   ; Well... here he (she?) is as a fractal!
  1226.   z=pixel:
  1227.    a=z^5 + z^3 + z + pixel
  1228.    b=z^4 + z^2 + pixel
  1229.    z=b^2/a,
  1230.     |real(z)| <= 100 || |imag(z)| <= 100
  1231.   }
  1232.  
  1233. RCL_10 { ; Ron Lewen, 76376,2567
  1234.   z=pixel:
  1235.    z=flip((z^2+pixel)/(pixel^2+z))
  1236.     |z| <= 4
  1237.   }
  1238.  
  1239.  
  1240. {--- JONATHAN OSUCH ------------------------------------------------------}
  1241.  
  1242. BirdOfPrey(XAXIS_NOPARM) {
  1243.   z=p1, x=1:
  1244.    (x<10)*(z=sqr(z)+pixel)
  1245.    (10<=x)*(z=cosxx(z)+pixel)
  1246.    x=x+1
  1247.     |z|<=4
  1248.   }
  1249.  
  1250. FractalFenderC(XAXIS_NOPARM) {;Spectacular!
  1251.   z=p1,x=|z|:
  1252.    (z=cosh(z)+pixel)*(1<x)+(z=z)*(x<=1)
  1253.    z=sqr(z)+pixel,x=|z|
  1254.     x<=4
  1255.   }
  1256.  
  1257. {--- LEE SKINNER ---------------------------------------------------------}
  1258.  
  1259. MTet (XAXIS) {; Mandelbrot form 1 of the Tetration formula --Lee Skinner
  1260.   z = pixel:
  1261.    z = (pixel ^ z) + pixel
  1262.     |z| <= (P1 + 3)
  1263.   }
  1264.  
  1265. AltMTet(XAXIS) {; Mandelbrot form 2 of the Tetration formula --Lee Skinner
  1266.   z = 0:
  1267.    z = (pixel ^ z) + pixel
  1268.     |z| <= (P1 + 3)
  1269.   }
  1270.  
  1271. JTet (XAXIS) {; Julia form 1 of the Tetration formula --Lee Skinner
  1272.   z = pixel:
  1273.    z = (pixel ^ z) + P1
  1274.     |z| <= (P2 + 3)
  1275.   }
  1276.  
  1277. AltJTet (XAXIS) {; Julia form 2 of the Tetration formula --Lee Skinner
  1278.   z = P1:
  1279.    z = (pixel ^ z) + P1
  1280.     |z| <= (P2 + 3)
  1281.   }
  1282.  
  1283. Cubic (XYAXIS) {; Lee Skinner
  1284.   p = pixel, test = p1 + 3
  1285.   t3 = 3*p, t2 = p*p
  1286.   a = (t2 + 1)/t3, b = 2*a*a*a + (t2 - 2)/t3
  1287.   aa3 = a*a*3, z = 0 - a :
  1288.    z = z*z*z - aa3*z + b
  1289.     |z| < test
  1290.  }
  1291.  
  1292. Fzppfnre {; Lee Skinner
  1293.   z = pixel, f = 1./(pixel):
  1294.    z = fn1(z) + f
  1295.     |z| <= 50
  1296.   }
  1297.  
  1298. Fzppfnpo {; Lee Skinner
  1299.   z = pixel, f = (pixel)^(pixel):
  1300.    z = fn1(z) + f
  1301.     |z| <= 50
  1302.   }
  1303.  
  1304. Fzppfnsr {; Lee Skinner
  1305.   z = pixel, f = (pixel)^.5:
  1306.    z = fn1(z) + f
  1307.     |z| <= 50
  1308.   }
  1309.  
  1310. Fzppfnta {; Lee Skinner
  1311.   z = pixel, f = tan(pixel):
  1312.    z = fn1(z) + f
  1313.     |z|<= 50
  1314.   }
  1315.  
  1316. Fzppfnct {; Lee Skinner
  1317.   z = pixel, f = cos(pixel)/sin(pixel):
  1318.    z = fn1(z) + f
  1319.     |z|<= 50
  1320.   }
  1321.  
  1322. Fzppfnse {; Lee Skinner
  1323.   z = pixel, f = 1./sin(pixel):
  1324.    z = fn1(z) + f
  1325.     |z| <= 50
  1326.   }
  1327.  
  1328. Fzppfncs {; Lee Skinner
  1329.   z = pixel, f = 1./cos(pixel):
  1330.    z = fn1(z) + f
  1331.     |z| <= 50
  1332.   }
  1333.  
  1334. Fzppfnth {; Lee Skinner
  1335.   z = pixel, f = tanh(pixel):
  1336.    z = fn1(z)+f
  1337.     |z|<= 50
  1338.   }
  1339.  
  1340. Fzppfnht {; Lee Skinner
  1341.   z = pixel, f = cosh(pixel)/sinh(pixel):
  1342.    z = fn1(z)+f
  1343.     |z|<= 50
  1344.   }
  1345.  
  1346. Fzpfnseh {; Lee Skinner
  1347.   z = pixel, f = 1./sinh(pixel):
  1348.    z = fn1(z) + f
  1349.     |z| <= 50
  1350.   }
  1351.  
  1352. Fzpfncoh {; Lee Skinner
  1353.   z = pixel, f = 1./cosh(pixel):
  1354.    z = fn1(z) + f
  1355.     |z| <= 50
  1356.   }
  1357.  
  1358. Zexpe (XAXIS) {
  1359.   s = exp(1.,0.), z = Pixel:
  1360.    z = z ^ s + pixel
  1361.     |z| <= 100
  1362.   }
  1363.  
  1364. comment { s = log(-1.,0.) / (0.,1.)   is   (3.14159265358979, 0.0 }
  1365.  
  1366. Exipi (XAXIS) {
  1367.   s = log(-1.,0.) / (0.,1.), z = Pixel:
  1368.    z = z ^ s + pixel
  1369.     |z| <= 100
  1370.   }
  1371.  
  1372. Fzppchco {
  1373.   z = pixel, f = cosxx (pixel):
  1374.    z = cosh (z) + f
  1375.     |z| <= 50
  1376.   }
  1377.  
  1378. Fzppcosq {
  1379.   z = pixel, f = sqr (pixel):
  1380.    z = cosxx (z)  + f
  1381.     |z| <= 50
  1382.   }
  1383.  
  1384. Fzppcosr {
  1385.   z = pixel, f = (pixel) ^ 0.5:
  1386.    z = cosxx (z)  + f
  1387.     |z| <= 50
  1388.   }
  1389.  
  1390. Leeze (XAXIS) {
  1391.   s = exp(1.,0.), z = Pixel, f = Pixel ^ s:
  1392.    z = cosxx (z) + f
  1393.     |z| <= 50
  1394.   }
  1395.  
  1396. OldManowar (XAXIS) {
  1397.   z0 = 0
  1398.   z1 = 0
  1399.   test = p1 + 3
  1400.   c = pixel :
  1401.    z = z1*z1 + z0 + c
  1402.    z0 = z1
  1403.    z1 = z
  1404.     |z| < test
  1405.   }
  1406.  
  1407. ScSkLMS(XAXIS) {
  1408.   z = pixel, TEST = (p1+3):
  1409.    z = log(z) - sin(z)
  1410.     |z|<TEST
  1411.   }
  1412.  
  1413. ScSkZCZZ(XYAXIS) {
  1414.   z = pixel, TEST = (p1+3):
  1415.    z = (z*cosxx(z)) - z
  1416.     |z|<TEST
  1417.   }
  1418.  
  1419. TSinh (XAXIS) {; Tetrated Hyperbolic Sine - Improper Bailout
  1420.   z = c = sinh(pixel):
  1421.    z = c ^ z
  1422.     z <= (p1 + 3)
  1423.   }
  1424.  
  1425. {--- SCOTT TAYLOR --------------------------------------------------------}
  1426.  
  1427. { The following is from Scott Taylor.
  1428.   Scott says they're "Dog" because the first one he looked at reminded him
  1429.   of a hot dog. This was originally several fractals, we have generalized it. }
  1430.  
  1431. FnDog(XYAXIS) {; Scott Taylor
  1432.   z = Pixel, b = p1+2:
  1433.    z = fn1( z ) * pixel
  1434.     |z| <= b
  1435.   }
  1436.  
  1437. Ent {; Scott Taylor
  1438.   ; Try params=.5/.75 and the first function as exp.
  1439.   ; Zoom in on the swirls around the middle.  There's a
  1440.   ; symmetrical area surrounded by an asymmetric area.
  1441.   z = Pixel, y = fn1(z), base = log(p1):
  1442.    z = y * log(z)/base
  1443.     |z| <= 4
  1444.   }
  1445.  
  1446. Ent2 {; Scott Taylor
  1447.   ; try params=2/1, functions=cos/cosh, potential=255/355
  1448.   z = Pixel, y = fn1(z), base = log(p1):
  1449.    z = fn2( y * log(z) / base )
  1450.     |z| <= 4
  1451.   }
  1452.  
  1453. {--- MICHAEL THEROUX & RON BARNETT ---------------------------------------}
  1454.  
  1455. test3 {; Michael Theroux [71673,2767]
  1456.   ;fix and generalization by Ron Barnett [70153,1233]
  1457.   ;=phi
  1458.   ;try p1 = 2.236067977 for the golden mean
  1459.   z = ((p1 + 1)/2)/pixel:
  1460.    z =  z*z + pixel*((p1 + 1)/2)/((p1 - 1)/2)
  1461.     |z| <= 4
  1462.   }
  1463.  
  1464. {--- TIMOTHY WEGNER ------------------------------------------------------}
  1465.  
  1466. Newton_poly2 { ; Tim Wegner - use float=yes
  1467.   ; fractal generated by Newton formula z^3 + (c-1)z - c
  1468.   ; p1 is c in above formula
  1469.   z = pixel, z2 = z*z, z3 = z*z2:
  1470.    z = (2*z3 + p1) / (3*z2 + (p1 - 1))
  1471.    z2 = z*z
  1472.    z3 = z*z2
  1473.    .004 <= |z3 + (p1-1)*z - p1|
  1474.   }
  1475.  
  1476. Newt_ellipt_oops { ; Tim Wegner - use float=yes and periodicity=0
  1477.   ; fractal generated by Newton formula  (z^3 + c*z^2 +1)^.5
  1478.   ; try p1 = 1 and p2 = .1
  1479.   ; if p2 is small (say .001), converges very slowly so need large maxit
  1480.   ; another "tim's error" - mistook sqr for sqrt (see next)
  1481.   z = pixel, z2 = z*z, z3 = z*z2:
  1482.    num = (z3 + p1*z2 + 1)^.5      ; f(z)
  1483.    denom = (1.5*z2 + p1*z)/num    ; f'(z)
  1484.    z = z - (num/denom)            ; z - f(z)/f'(z)
  1485.    z2 = z*z
  1486.    z3 = z*z2
  1487.     p2 <= |z3 + p1*z2 + 1|  ; no need for sqrt because sqrt(z)==0 iff z==0
  1488.   }
  1489.  
  1490. Newton_elliptic { ; Tim Wegner - use float=yes and periodicity=0
  1491.   ; fractal generated by Newton formula f(z) = (z^3 + c*z^2 +1)^2
  1492.   ; try p1 = 1 and p2 = .0001
  1493.   z = pixel, z2 = z*z, z3 = z*z2:
  1494.    z = z - (z3 + p1*z2 + 1)/(6*z2 + 4*p1*z)      ; z - f(z)/f'(z)
  1495.    z2 = z*z
  1496.    z3 = z*z2
  1497.     p2 <= |z3 + p1*z2 + 1|  ; no need for sqr because sqr(z)==0 iff z==0
  1498.   }
  1499.  
  1500. {--- TIM WEGNER & MARK PETERSON ------------------------------------------}
  1501.  
  1502. comment {
  1503.   These are a few of the examples from the book, Fractal Creations, by Tim
  1504.   Wegner and Mark Peterson.
  1505.   }
  1506.  
  1507. MyFractal {; Fractal Creations example
  1508.   c = z = 1/pixel:
  1509.    z = sqr(z) + c
  1510.     |z| <= 4
  1511.   }
  1512.  
  1513. Bogus1 {; Fractal Creations example
  1514.   z = 0; z = z + * 2
  1515.    |z| <= 4 }
  1516.  
  1517. MandelTangent {; Fractal Creations example (revised for v.16)
  1518.   z = pixel:
  1519.    z = pixel * tan(z)
  1520.     |real(z)| < 32
  1521.   }
  1522.  
  1523. Mandel3 {; Fractal Creations example
  1524.   z = pixel, c = sin(z):
  1525.    z = (z*z) + c
  1526.    z = z * 1/c
  1527.     |z| <= 4
  1528.   }
  1529.  
  1530.  
  1531. {--- AUTHORS UNKNOWN -----------------------------------------------------}
  1532.  
  1533. moc {
  1534.     z=0, c=pixel:
  1535.    z=sqr(z)+c
  1536.    c=c+p1/c
  1537.     |z| <= 4
  1538.     }
  1539.  
  1540. Bali {;The difference of two squares
  1541.   z=x=1/pixel, c= fn1 (z):
  1542.    z = (x+c) * (x-c)
  1543.    x=fn2(z)
  1544.     |z| <=3
  1545.   }
  1546.  
  1547. Fatso {;
  1548.   z=x=1/pixel, c= fn1 (z):
  1549.    z = (x^3)-(c^3)
  1550.    x=fn2(z)
  1551.     |z| <=3
  1552.   }
  1553.  
  1554. Bjax {;
  1555.   z=c=2/pixel:
  1556.    z =(1/((z^(real(p1)))*(c^(real(p2))))*c) + c
  1557. }
  1558.  
  1559. ULI_4 {
  1560.   z = Pixel:
  1561.    z = fn1(1/(z+p1))*fn2(z+p1)
  1562.     |z| <= p2
  1563.   }
  1564.  
  1565. ULI_5 {
  1566.   z = Pixel, c = fn1(pixel):
  1567.    z = fn2(1/(z+c))*fn3(z+c)
  1568.     |z| <= p1
  1569.   }
  1570.  
  1571. ULI_6 {
  1572.   z = Pixel:
  1573.    z = fn1(p1+z)*fn2(p2-z)
  1574.     |z| <= p2+16
  1575.   }
  1576.  
  1577.