Old 19th May 2003, 18:28   #1
unripeLemon
Senior Member
 
unripeLemon's Avatar
 
Join Date: Mar 2003
Location: some place thats green
Posts: 134
Send a message via AIM to unripeLemon
Arrow fractal, and julias?

i'm wondering how to make a fractal and a julia, can anyone help me?
unripeLemon is offline   Reply With Quote
Old 19th May 2003, 20:32   #2
mikm
Major Dude
 
mikm's Avatar
 
Join Date: May 2001
Location: somewhere else
Posts: 1,286
try looking at the code in TFF 2.0 or Whacko I

powered by C₈H₁₀N₄O₂
mikm is offline   Reply With Quote
Old 19th May 2003, 23:06   #3
UnConeD
Whacked Moderator
 
UnConeD's Avatar
 
Join Date: Jun 2001
Posts: 2,104
The easiest way is to make a movement that follows one Julia iteration, and draw something near the middle. The repeated movement will end up similar to the fractal you get using escape-time iteration.

You can't make Mandelbrot sets with this technique though.

UnConeD is offline   Reply With Quote
Old 19th May 2003, 23:33   #4
dirkdeftly
Forum King
 
dirkdeftly's Avatar
 
Join Date: Jun 2001
Location: Cydonia, Mars
Posts: 2,651
Send a message via AIM to dirkdeftly
or in degnic's or nic's or skupers's or avs-king's or anyone else's code...

and i stared at the code in wavs1 for a looong time and couldn't get it at all. before i get into anything else, you need to have a basic understanding of what fractals are and how to generate them point-by-point (e.g. the iteration of complex formulas). i'm not gonna waste my time writing out an explanation of it, so if you don't know already, google for mandelbrot/fractals/etc.

the standard form of a julia fractal is this:
z(n+1)=z(n)^2+c; where c(=cx+icy) is a constant complex number, and z(=x+iy) is any point <x,iy> in the image. multiplying this formula out we get:
x(n+1)+iy(n+1)=x(n)^2+2*x(n)*iy(n)+i^2y(n)^2+cx+icy
or:
x(n+1)+iy(n+1)=x(n)^2+2*x(n)*iy(n)-y(n)^2+cx+icy (since i=sqrt(-1), i^2=sqrt(-1)^2=-1)
what we need to do is seperate this into two formulas in terms of x(n+1) and y(n+1). now since our only y(n+1) term has an i coefficient, it is logical to seperate the terms with i coefficients into the y formula, so we can get rid of i entirely:
x(n+1)=x(n)^2-y(n)^2+cx
iy(n+1)=2*i*x(n)*y(n)+icy, or y(n+1)=2*x(n)*y(n)+cy.

and there you've got your dynamic movement:
x1=x; y1=y;
x=sqr(x1)-sqr(y1)+cx; y=2*x1*y1+cy;

unconed would be better at explaining this though

"guilt is the cause of more disauders
than history's most obscene marorders" --E. E. Cummings
dirkdeftly is offline   Reply With Quote
Old 20th May 2003, 01:15   #5
UnConeD
Whacked Moderator
 
UnConeD's Avatar
 
Join Date: Jun 2001
Posts: 2,104
Well Atero pretty much explained the basics... your standard Julia is calculated using an iterative formula z(n+1) = f[z(n)]

z(n) means the n'th iteration of z.

However the standard method of rendering a Julia or Mandelbrot was not explained. Basically you wish to determine which points will keep 'hanging around' the center area when you're iterating them, and which points will go to infinity. This gives you a black and white julia/mandelbrot image.

To check if a point goes to infinity is rather hard (how can you be sure?), but for the z=z^2+c formula it can be proven that any point with radius > 2 will eventually go to infinity. So you check that instead.

By counting the amount of iterations needed to reach that condition and coloring accordingly, you can get interesting colorpatterns around the edge.

Now why can we do the same with a dynamic movement? Well simple... a point that extends towards infinity will get its colorvalue a large distance away from the center. A point that keeps rotating around in the center gets its colorvalue from the center. By repeatedly applying this movement, the non-julia points will always go dark, while the julia points will scale and stretch the center colors and converge into a rough Julia fractal shape. Instead of determining the exact value for each point, we simply distort the image so that each distortion contributes to a julia-shape.

This works with a DM because for a julia, there is no difference in the constant c across the entire image and per iteration.

Basically you can create fractals in many ways like this. For example, a simple d=d*1.2 movement also results in a 'fractal', just not a very interesting one (if you zoom in by factor 120%, you will see the same image as before). The trick is to have a movement that scales down the image in a certain way, so that it converges into an interesting shape.

UnConeD is offline   Reply With Quote
Old 20th May 2003, 01:27   #6
UnConeD
Whacked Moderator
 
UnConeD's Avatar
 
Join Date: Jun 2001
Posts: 2,104
Here's a simple demo fractal I just came up with. To view it, turn avs' speed all the way down with the "windowed performance slider". Then turn main's clear every frame on and back off again to see it evolve into the fractal.

It starts out with a simple horizontal line (no music). Then a polar transformation is applied that you can imagine like this:

Take the line and bend the two ends towards each other so that you a 180° arc. Take a duplicate and glue them together so that you get a full circle.

This is the movement y=d*4-2;x=cos(r);

However if you repeat this same transformation after another step, you will not just be bending the newly drawn line, but also the circle from the last frame. So each 180° arc will already have a smaller circle in its middle. The end shape will be a large circle with 2 small circles on it.

The next step, two smaller circles will appear next to each of the last 2 circles, and so on and so on, until you get the fractal here.

This is the literal definitial of a fractal: a shape that contains itself transformed, repeated with infinite detail.

You can change x=cos(r) to x=cos(r*1.5) to get a trefoil fractal too. Notice how now with each step, the extra amount of circles triples.
Attached Files
File Type: zip fractal.zip (289 Bytes, 196 views)

UnConeD is offline   Reply With Quote
Old 20th May 2003, 04:48   #7
shreyas_potnis
Major Dude
 
shreyas_potnis's Avatar
 
Join Date: Jan 2003
Location: Mumbai, India
Posts: 787
does anyone know why it was named 'julia'?

http://home.iitb.ac*****~shreyaspotnis
shreyas_potnis is offline   Reply With Quote
Old 20th May 2003, 05:32   #8
Nic01
Major Dude
 
Nic01's Avatar
 
Join Date: Mar 2002
Location: The Biggest Little City
Posts: 508
Send a message via AIM to Nic01
The "inventor", idiot (or founder, whichever word you prefer or is more appropriate)

Go google for it, you'll find the history.

[soon to leave, sirs]
Nic01 is offline   Reply With Quote
Old 20th May 2003, 17:26   #9
unripeLemon
Senior Member
 
unripeLemon's Avatar
 
Join Date: Mar 2003
Location: some place thats green
Posts: 134
Send a message via AIM to unripeLemon
Thanx for the help, but it would be easier to understand if i knew complicated geometric math
unripeLemon is offline   Reply With Quote
Old 20th May 2003, 19:27   #10
UnConeD
Whacked Moderator
 
UnConeD's Avatar
 
Join Date: Jun 2001
Posts: 2,104
unripeLemon: what exactly do you mean? The main thing you might need to learn for julias is complex-numbers. If you've never heard of them, they will sound amazingly weird, but once you know the basics it's not that hard.

UnConeD is offline   Reply With Quote
Old 20th May 2003, 19:28   #11
unripeLemon
Senior Member
 
unripeLemon's Avatar
 
Join Date: Mar 2003
Location: some place thats green
Posts: 134
Send a message via AIM to unripeLemon
oh, sorry
unripeLemon is offline   Reply With Quote
Old 21st May 2003, 00:07   #12
dirkdeftly
Forum King
 
dirkdeftly's Avatar
 
Join Date: Jun 2001
Location: Cydonia, Mars
Posts: 2,651
Send a message via AIM to dirkdeftly
hence my telling you to google for an explanation of fractals. fooling around with fractint for a few weeks and checking out the info files helps

"guilt is the cause of more disauders
than history's most obscene marorders" --E. E. Cummings
dirkdeftly is offline   Reply With Quote
Old 24th May 2003, 04:46   #13
sidd
Major Dude
 
sidd's Avatar
 
Join Date: May 2003
Location: Australia
Posts: 1,353
learning what a fractle is one thing, understanding how to write it in ordinary math is another.
AVS can make the simplest equations into a nightmare, or in the case of fractles, make a difficult concept into a couple of lines.

AVS iterates the same lines of code for every frame, which is basically how a fractle works. So it is really the perfect platform.

"This is the literal definitial of a fractal: a shape that contains itself transformed, repeated with infinite detail."
--- pretty much exactly what a dynamic movement does anyway!
sidd is offline   Reply With Quote
Old 24th May 2003, 10:24   #14
uNDefineD
Senior Member
 
uNDefineD's Avatar
 
Join Date: Jan 2002
Location: Melbourne, Australia
Posts: 297
Send a message via ICQ to uNDefineD Send a message via AIM to uNDefineD
Cone--
A complex number is something like this, right?

sqrt(-4) = 2i

Or something. I dunno, I didn't take Specialist Maths in high school.

BTW, funny story: I have a friend named Julia whose birthday another friend was DJing at last July. I suggested to him to show a Julia fractal using AVS (and take immense pride in knowing that we were the only two who understood ). Too bad he couldn't find a projector though.
uNDefineD is offline   Reply With Quote
Old 24th May 2003, 19:24   #15
dirkdeftly
Forum King
 
dirkdeftly's Avatar
 
Join Date: Jun 2001
Location: Cydonia, Mars
Posts: 2,651
Send a message via AIM to dirkdeftly
sqrt(-4)=2i is an imaginary number; sqrt(4)=2 is a real number. a complex number is a number with real and imaginary components: z=a+bi, where a and b are two real numbers.

"guilt is the cause of more disauders
than history's most obscene marorders" --E. E. Cummings
dirkdeftly is offline   Reply With Quote
Old 25th May 2003, 08:53   #16
sidd
Major Dude
 
sidd's Avatar
 
Join Date: May 2003
Location: Australia
Posts: 1,353
www.thesquarerootof-1.com
sidd is offline   Reply With Quote
Old 26th May 2003, 15:34   #17
skupers
Senior Member
 
skupers's Avatar
 
Join Date: Aug 2002
Location: the Netherlands
Posts: 207
Send a message via AIM to skupers
Curlicue Fractal

I made a preset based around the curlicue fractal some time ago. Since this is a topic about fractals, I thought it might be of interest for some of you guys. I'm especially proud of the morphing between two seeds.

I was also wondering if anyone here knows how to do strange attractor and quaternion julia fractals (damn those 4d fractals )? I have been trying for some time, but without result.
Info about strange attractor
Info about quaternion julia set
Attached Files
File Type: zip s_kupers - curlicue test.zip (464 Bytes, 193 views)
skupers is offline   Reply With Quote
Old 27th May 2003, 00:38   #18
dirkdeftly
Forum King
 
dirkdeftly's Avatar
 
Join Date: Jun 2001
Location: Cydonia, Mars
Posts: 2,651
Send a message via AIM to dirkdeftly
wow...that is just about the coolest superscope i've ever seen.

:claps:

what is the curlicue fractal anyhow...?

<edit> add sx=ax;sy=ayax=0;ay=0; to frame and ax=ax+x/n;ay=ay+y/n;x=x-sx;y=y-sy; to pixel </edit>

"guilt is the cause of more disauders
than history's most obscene marorders" --E. E. Cummings
dirkdeftly is offline   Reply With Quote
Old 27th May 2003, 02:12   #19
sidd
Major Dude
 
sidd's Avatar
 
Join Date: May 2003
Location: Australia
Posts: 1,353
i could never understand how strange attractor works in the first place, i remember reading about it one time when i was working at a library at uni.

never heard of the quantrionatronamajig julia set.

ill download you preset when i get home
sidd is offline   Reply With Quote
Old 27th May 2003, 06:52   #20
skupers
Senior Member
 
skupers's Avatar
 
Join Date: Aug 2002
Location: the Netherlands
Posts: 207
Send a message via AIM to skupers
Info about the curlicue fractal . I didn't know of it either until I read that site.
The problem with Quaternion Julias isn't really the fractal code itself, that's just a more complicated version of normal julia code. In Quaternion Julia's you have q = r + ai + bj + ck instead of z = a + bi. What I have problems with the actual rendering of the fractal. Did you ever try applying the normal julia code to a ssc grid? It doesn't look like a julia fractal at all. This also seems to be the problem for the quaternion julia. My idea was to actually make a 3d block of points and color code accordingly, but that's very slow (a block of 100 x 100 x 100 points needs a N of 1000000). I think I shouldn't go over N=2000, so at best I can have of 2000^(1/3) points per side. That means only 12 points per side and that isn't a accurate as I want it to be.
I could solve this problem with a kind of 3d line scope, somewhat like the 2d-ones used in for example el-vis' fractals.
You still have the problem of the blending then, because replace would leave you with black points covering the screen and with maximum blend you can see the points on the other side of the fractal and that would make it look really weird.
skupers is offline   Reply With Quote
Old 27th May 2003, 08:56   #21
sidd
Major Dude
 
sidd's Avatar
 
Join Date: May 2003
Location: Australia
Posts: 1,353
if you were able to create it at 10,000 points. it would be worth it just for the sake of seeing a strange attractor in AVS.
sidd is offline   Reply With Quote
Old 27th May 2003, 12:12   #22
skupers
Senior Member
 
skupers's Avatar
 
Join Date: Aug 2002
Location: the Netherlands
Posts: 207
Send a message via AIM to skupers
No, i still don't know how to make a strange attractor. That explanation was for a quaternion julia, it's a 4d fractal that has to be shown in 3d. I guess I could try, but I can't give any promises it'll actually work.
skupers is offline   Reply With Quote
Old 27th May 2003, 13:59   #23
sidd
Major Dude
 
sidd's Avatar
 
Join Date: May 2003
Location: Australia
Posts: 1,353
i used to have a link to a site full of nice raytraced 3d fractals.. but now i cant find it.. =(
sidd is offline   Reply With Quote
Old 27th May 2003, 15:52   #24
dirkdeftly
Forum King
 
dirkdeftly's Avatar
 
Join Date: Jun 2001
Location: Cydonia, Mars
Posts: 2,651
Send a message via AIM to dirkdeftly
good fucking luck getting ANY kind of cross section to work in AVS, let alone 4D-3D. i don't think i need to mention how you can't do this with a DM, but i think i do need to mention that you simply *won't* be doing this with an ssc.

as for strange attractors, along with flame fractals, i'm sure it's perfectly possible, since they're just a density plot of points.

"guilt is the cause of more disauders
than history's most obscene marorders" --E. E. Cummings
dirkdeftly is offline   Reply With Quote
Old 27th May 2003, 18:19   #25
skupers
Senior Member
 
skupers's Avatar
 
Join Date: Aug 2002
Location: the Netherlands
Posts: 207
Send a message via AIM to skupers
Well, Atero, did try it with a 21x21x21 cube of points, where the points got their color depending on the amount of iterations it took to get to infinity. But that was really unaccurate and ugly. I also tried that 3d line idea, but that's even worse, because it takes over 10 minutes to render the fractal at 64fps and you can't really tell anything from the picture created. I'll try some more, but I think you're right; it seems almost impossible.
skupers is offline   Reply With Quote
Old 28th May 2003, 05:41   #26
sidd
Major Dude
 
sidd's Avatar
 
Join Date: May 2003
Location: Australia
Posts: 1,353
such a shame....
oh well.. theres always something else to do..
sidd is offline   Reply With Quote
Old 28th May 2003, 10:28   #27
nixa
Senior Member
 
Join Date: Jul 2002
Posts: 149
Skupers that circular fractal scope is just so cool. I made a 3D version and chainged it so its more random but it doesnt have so clean structure anymore.
Attached Files
File Type: zip cirluar fractal 3d.zip (642 Bytes, 205 views)
nixa is offline   Reply With Quote
Old 28th May 2003, 10:58   #28
Magic.X
Major Dude
 
Magic.X's Avatar
 
Join Date: Feb 2002
Location: Leipzig / Germany
Posts: 859
A friend of mine is doing frectals for posters and stuff.

Just go to http://www.psykick.de (its in english) to find some information or links to progs and stuff.


-=[The Ultimate VJ-Tool for AVS]=-

Hotlist 2.3 developement thread (old)
Magic.X is offline   Reply With Quote
Old 28th May 2003, 12:35   #29
shreyas_potnis
Major Dude
 
shreyas_potnis's Avatar
 
Join Date: Jan 2003
Location: Mumbai, India
Posts: 787
lol, Lemon, your sig is actually quite cool I noticed it now.

http://home.iitb.ac*****~shreyaspotnis
shreyas_potnis is offline   Reply With Quote
Old 28th May 2003, 13:02   #30
sidd
Major Dude
 
sidd's Avatar
 
Join Date: May 2003
Location: Australia
Posts: 1,353
that one fucking awesome remix nixa!
sidd is offline   Reply With Quote
Old 28th May 2003, 14:55   #31
skupers
Senior Member
 
skupers's Avatar
 
Join Date: Aug 2002
Location: the Netherlands
Posts: 207
Send a message via AIM to skupers
Very nice remix. Am I correct in thinking that you're rendering the fractal three times, one time for every coördinate?
skupers is offline   Reply With Quote
Old 28th May 2003, 16:57   #32
nixa
Senior Member
 
Join Date: Jul 2002
Posts: 149
Skupers: Yes thats what i did.
You can add this to bottom for some nice colors:
a=sqr(sqr(z1)*z1);
red=(sin((fx*m+fx2*(1-m))*0.001)*0.5+0.5)*a;
green=(sin((fy*m+fy2*(1-m))*0.001)*0.5+0.5)*a;
blue=(sin((fz*m+fz2*(1-m))*0.001)*0.5+0.5)*a;
nixa is offline   Reply With Quote
Old 3rd November 2004, 19:24   #33
ikbendirk
Junior Member
 
Join Date: Nov 2004
Posts: 3
mandelbrot

I am a quite new to the AVS, and even newer to this forum...
I hope there isn't a newby-flaming-policy around here, because if so, i'm screwed.
The fact is, I have a request: I have tried to search threads for fractals, and one in specific; the mandelbrot set.

The only thing I read is 'Julia's are easy, mandelbrot's are harder but can be done'. Well supposing it CAN be done, I've searched for proof of this, but didn't find anything.

I tried to make one myself, and the download below is as far as I got. I simply converted the SuperScope's point sequence into a grid, and used basic fractal coding that can be found anywhere on the net... It is very slow and doesn't interact with the music yet. Are there any examples of better mandelbrot sets? <to download rename the .txt to .avs>

Last edited by ikbendirk; 3rd November 2004 at 19:42.
ikbendirk is offline   Reply With Quote
Old 3rd November 2004, 19:45   #34
ikbendirk
Junior Member
 
Join Date: Nov 2004
Posts: 3
mandelbrot

I am a quite new to the AVS, and even newer to this forum...
I hope there isn't a newby-flaming-policy around here, because if so, i'm screwed.
The fact is, I have a request: I have tried to search threads for fractals, and one in specific; the mandelbrot set.

The only thing I read is 'Julia's are easy, mandelbrot's are harder but can be done'. Well supposing it CAN be done, I've searched for proof of this, but didn't find anything.

I tried to make one myself, and the download below is as far as I got. I simply converted the SuperScope's point sequence into a grid, and used basic fractal coding that can be found anywhere on the net... It is very slow and doesn't interact with the music yet. Are there any examples of better mandelbrot sets? <to download rename the .txt to .avs>
Attached Files
File Type: txt fractal.txt (580 Bytes, 198 views)
ikbendirk is offline   Reply With Quote
Old 4th November 2004, 16:06   #35
PAK-9
Major Dude
 
PAK-9's Avatar
 
Join Date: Oct 2002
Location: The United Kingdom of Great Britain and Northern Ireland
Posts: 1,374
There are some mandelbrot presets out there, but the main problem is they're either very slow or very low detail... frankly AVS just isnt up to it.

http://PAK-9.deviantart.com

...innit
PAK-9 is offline   Reply With Quote
Old 4th November 2004, 16:41   #36
sidd
Major Dude
 
sidd's Avatar
 
Join Date: May 2003
Location: Australia
Posts: 1,353
wow. totally prehistoric thread..



[edit] OOH LOOK! there's me!! I can't spell fractal! w00tz0rz!
sidd is offline   Reply With Quote
Old 4th November 2004, 17:21   #37
sidd
Major Dude
 
sidd's Avatar
 
Join Date: May 2003
Location: Australia
Posts: 1,353
after a bit more digging:

http://forums.winamp.com/showthread....hreadid=123053

guess which one is me
sidd is offline   Reply With Quote
Old 4th November 2004, 21:55   #38
PAK-9
Major Dude
 
PAK-9's Avatar
 
Join Date: Oct 2002
Location: The United Kingdom of Great Britain and Northern Ireland
Posts: 1,374
That was back when your avatar wasn't a monocolour square and you harked from Ozshtrayleeuh.

http://PAK-9.deviantart.com

...innit
PAK-9 is offline   Reply With Quote
Old 5th November 2004, 15:24   #39
ikbendirk
Junior Member
 
Join Date: Nov 2004
Posts: 3
I redid this and that, it actually is a pretty fancy visualisation now... at least the speed is accaptable
comments anyone...?
Attached Files
File Type: zip fractal.zip (712 Bytes, 162 views)
ikbendirk is offline   Reply With Quote
Old 5th November 2004, 16:33   #40
PAK-9
Major Dude
 
PAK-9's Avatar
 
Join Date: Oct 2002
Location: The United Kingdom of Great Britain and Northern Ireland
Posts: 1,374
nice, could do with a bit more music response to be a visualisation.

http://PAK-9.deviantart.com

...innit
PAK-9 is offline   Reply With Quote
Reply
Go Back   Winamp & Shoutcast Forums > Visualizations > AVS > AVS Troubleshooting

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Forum Jump