Title: Using 2 formulae to generate fractals Post by: element90 on September 12, 2011, 12:29:01 PM When I added transforms to my programs I included two sets of transforms, "Transforms A" and "Transforms B" and a "Transform Sequence" to control which set of transforms of transforms is applied at a given iteration. So if the transform sequence is "AB" then the transform set applied for the first iteration is A, the second set B is applied for the second iteration, the sequence is then repeated. For "AAB" transform set A is used twice as often as set B.
So using the formula Zacpac: z = transform(z) z = (z + c)^alpha Using Transforms A power, 2 translation, 0.5 and Transform B power, 2 I have two formulae to play with namely: z = z^2 + 0.5 + c z = z^2 + c Using a transform sequence of AAAAAAAABA I found this: (http://nocache-nocookies.digitalgott.com/gallery/8/5522_12_09_11_12_06_33.jpeg) Changing the translation constant to 0.125 and the sequence to AAAAAAAAAB I found this: (http://nocache-nocookies.digitalgott.com/gallery/8/5522_12_09_11_12_04_17.jpeg) Only two images so far, as I can easily add two sets of transforms to all my fractals (except Lyapunov and Pickover Popcorn) it is going to interesting playing with this facility. Title: Re: Using 2 formulae to generate fractals Post by: cKleinhuis on September 12, 2011, 02:30:14 PM hi there, i like the attempt on ordering the alternating/hybrid generation of formulas, i recently used another method,
which is more like a biased alternate: range - a integer value bias - a integer value <range and then for each iteration the test is if(iteration%range>bias){ useFormulaA }else{ useFormulaB } it is not perfect, i know, but it could produce sequences like AAAAABBBBBB AAAAAABBBBB ... when seeing those "AB.." strings, i have to think about l-systems, to produce longer - and more complicated - rule sequences ... it is all about, "how to define an endless formula lookup table".... Title: Re: Using 2 formulae to generate fractals Post by: element90 on September 12, 2011, 04:17:49 PM I got the idea for using the sequence string from the way Lyapunov fractals are generated.
cKleinhuls, your method only produces a subset of the sequences possible with my transform sequence. I knew I couldn't be the only experimenting with swapping between formulae. So far it appears that sequences that favour a given formula over the other give better results. The first formula dictates the overall shape of the picture for example swapping between the Mandelbrot and a Cubic Mandelbrot results in a ghostly outline of the standard Mandelbrot. I haven't save an example of this effect yet, when I do I'll add it to this thread. Here is an other example using Quadratic: z = transform(z) z = alpha*z^2 + beta*z + c A Transforms top right, i.e. force both components of z to be positive B Transforms bottom right, i.e. force both components of z to be negative Transform sequence: AAAB (http://nocache-nocookies.digitalgott.com/gallery/8/5522_12_09_11_3_58_43.jpeg) Title: Re: Using 2 formulae to generate fractals Post by: cKleinhuis on September 12, 2011, 05:57:20 PM cKleinhuls, your method only produces a subset of the sequences possible with my transform sequence. it is just a subset i know ;) but it is only 3 lines of code to implement more variance when you only have 2 formulas ;) to understand what is possible, with alternation/hybrid methods, make sure you understand that once an iteration has been escaped its form wont change in further iterations, this is the reason why the "1st" formula defines the overall shape this effect can be understood best if you define an iteration when to swith it, this way you could display a fractal in the "black" area of another, but it is not leading to that interesting effects ;) to your method: you know you have limitations as well ? e.g. for a 24 iteration the sequence "AAAABBBB" would look like: "AAAABBBBAAAABBBBAAAABBBB" the sequences could grow bigger, but at the end you are just modulo+iterating over the chars in the string if your iteration exceeds the string length .... so, i like the way to define some kind of language ( perhaps branching would also make sense ... ) similar to the LSYSTEMs http://de.wikipedia.org/wiki/Lindenmayer-System Title: Re: Using 2 formulae to generate fractals Post by: cKleinhuis on September 12, 2011, 06:07:48 PM additionally i believe it is getting more interesting at deeper zoom levels ;)
Title: Re: Using 2 formulae to generate fractals Post by: element90 on September 12, 2011, 06:20:21 PM I could add additional transform sets to my software, I'll continue with the 2 set version for the time being as I've only just scratched the surface of this class of fractals. At the moment all my formulae are coded in C++ in the main body of the program, at some point I'll have to investigate how to incorporate some sort of fractal programming language along the same lines as UF, Fractal Science Kit and others.
cKleinhuls, do you have any example pictures using your technique? Title: Re: Using 2 formulae to generate fractals Post by: yv3 on September 12, 2011, 10:03:02 PM Intresting approach, i must try this out! I thought about something similar before, i combined the mandelbrot and julia formula to a single one where both formulas take effect in a single iteration. This a sample rendering:
Desert Sunrise (http://yv3.bplaced.net/forum/Misc/FAC2011/2.jpg) full size image (http://yv3.bplaced.net/forum/Misc/FAC2011/2.jpg) A warm sunrise in a desert with a a starry sky. A beauty with long black hair lies beside you ;) another one Addicted (http://yv3.bplaced.net/forum/Misc/FAC2011/3.jpg) full size image (http://yv3.bplaced.net/forum/Misc/FAC2011/3.jpg) greetings Title: Re: Using 2 formulae to generate fractals Post by: cKleinhuis on September 13, 2011, 11:55:57 AM Intresting approach, i must try this out! I thought about something similar before, i combined the mandelbrot and julia formula to a single one where both formulas take effect in a single iteration. This a sample rendering: there exist plenty of methods to create new formula ( e.g. spherical/polar interpolation of 2 different formula in one iteration ) adding/dividing/multiplying/subtracting is also easy to achieve and try out you are right that implementing a hybrid in one single iter step leads to different results, i can imagine a formula editor that has checkboxes for each formula in the created hybrid that can be checked as ( bailout test ) so that "simple" formulas like adding/subtracting wouldnt lead to a bailout condition.... this way every form could be doable ... i would love to see a drag&drop formula editor with simple operators to combine different fractal formula.... or create new ones i would love to see a language that lets define a logic for at which iteration step wich formula to use ( similar ot the above "AAABAABA" style ) , i can think of many more hybrid options, like: Base Formula would be A "use formula X at Iteration Y" "use formula X at Iteration Y1 to Y2" "use formula X at every nth Iteration" "if |z|<Y use formula X else use formula X2" ... and so on, some of these hybrids are available in my ultrafractal formula collection remember that each formula can have its own variable settings... in fact you could define a different formula at each iteration, but this would certainly lead to crappy results gotta open up ultra fractals formula editor now .... Title: Re: Using 2 formulae to generate fractals Post by: M Benesi on September 15, 2011, 07:49:49 PM Here is an other example using Quadratic: z = transform(z) z = alpha*z^2 + beta*z + c A Transforms top right, i.e. force both components of z to be positive B Transforms bottom right, i.e. force both components of z to be negative Transform sequence: AAAB (http://nocache-nocookies.digitalgott.com/gallery/8/5522_12_09_11_3_58_43.jpeg) This one produces a sort of "double" Burning Ship (http://en.wikipedia.org/wiki/Burning_Ship_fractal) fractal. Title: Re: Using 2 formulae to generate fractals Post by: tit_toinou on January 14, 2012, 03:11:02 PM This is a good idea !
Don't forget that by doing this you are just changing the initial formulae : if you are doing AB with A: "z^2+c" and B: "z^2-c" it is just like iterating over "(z^2+c)^2-c". Great images btw. Title: Re: Using 2 formulae to generate fractals Post by: cKleinhuis on January 14, 2012, 03:34:11 PM thats correct tit, but the alternation allows an easy set up of new formulas, as i stated earlier, in this approach it isnt neccesary to use different formulas, it is enough to use different parameters for the same formula, in this way transforms or pertubations are created that allow finer control over the deformations of the underlying formula, in fact with the alternation hybrid method it is possible to
create an arbitrary set of parameters that can be used to control the fractal .... Title: Re: Using 2 formulae to generate fractals Post by: hobold on January 14, 2012, 07:24:02 PM It might be an option to use algorithmically specified sequences instead of fixed strings consisting of A and B. These can be aperiodic, and so avoid the problem that one really just iterates a larger, composited, function. For example the Thue-Morse-Sequence: http://en.wikipedia.org/wiki/Thue–Morse_sequence . |