Pyrotex Posted March 6, 2006 Report Posted March 6, 2006 It appears to be available.When you download and run it, there is a menu pull-down called "Julia". What is this?Julia was the name of Mandelbrot's daughter.If you remember, the M algorithm was:In the region around 0, 0i in the complex plane, pick any point C. C = a, bi. Where a and b are real numbers.Now square C then add C -- to get D.Now square D then add D -- to get E.Now square E then add E -- to get F... etc. The J (for Julia) algorithm is:In the region around 0, 0i in the complex plane, pick any point C. C = a, bi. Where a and b are real numbers.Now square C then add C -- to get D.Now square D then add C -- to get E.Now square E then add C -- to get F... etc. Selecting the Julia Space gives you this second algorithm. And they are beautiful too! They are connected in the following manner.If you start with MS and there is a BLACK pixel in the center (a member of the MS) and then display the corresponding JS, then all BLACK members of the JS will connect together. In other words, there will be just ONE set of connected points in the JS. However, if you start with MS and there is a colored pixel in the center (NOT a member of the MS) and then display the corresponding JS, then the BLACK members of the JS will form an infinite set of unconnected regions. The MS is therefore a "MAP" of JS. Every point IN the MS will produce a connected JS; every point NOT IN the MS will produce a infinitely unconnected JS. Quote
TheBigDog Posted March 7, 2006 Report Posted March 7, 2006 OK Pyro, I've got the formula in front of me, but I am lost about how I begin the calculations. C = a, bi where a and b are any real numbers. I can create the looping formula looking for a value >2. But what gives me the starting value for each point on the space? And what is i? I am just a poor boy and my story's seldom toldI have squandered my existanceFor a pocket full of fractals such as Mandelbrot Bill Quote
Racoon Posted March 7, 2006 Author Report Posted March 7, 2006 I am not as bad as Qfwfq! :hyper: :confused: Quote
Racoon Posted March 7, 2006 Author Report Posted March 7, 2006 I love Pyro's posts and Attachment(s). :hyper: Check it out.. You can see the Continous in the Patterns created by geometric fractals! :confused: Quote
InfiniteNow Posted March 7, 2006 Report Posted March 7, 2006 :confused: (thumbnails from post #20 removed) Really dude... your screen and mine do not offer the same options!! Quote
Racoon Posted March 7, 2006 Author Report Posted March 7, 2006 We will try again.This is a zip file. You will have to unzip it to use it.It should produce a folder named "MandelFiles" (I think).Extract the folder to your hard drive.Inside should be the executable Manbrot2.exe.Double click on that. And it is written in Java, not Perl. :hyper: My avatar was made with this program!!!Every time you click anywhere in the program's display, it will redisplay with 2X magnification, with your click point at the center of the new display. Check out Pyrotex's Thumbnail Attachment!! Post #16 :confused: :hyper: Its Wicked Sick! :circle: :shade: Thats exactly-more than I could of hoped for! Pyro is Da' Man! Quote
Pyrotex Posted March 7, 2006 Report Posted March 7, 2006 I am just a poor boy and my story's seldom toldI have squandered my existanceFor a pocket full of fractals such as MandelbrotThe Boxer. I love to whistle along with that song. :confused:OK Pyro, I've got the formula in front of me, but I am lost about how I begin the calculations. C = a, bi where a and b are any real numbers. I can create the looping formula looking for a value >2. But what gives me the starting value for each point on the space? And what is i?"i" is the square root of minus one. Having said that, ignore it. You will be dealing with ordinary "x,y" coordinates on your display plane.Assume you have two variables a and b. Where C(0) = a, bi a and b are the "x,y" points on a small section of the plane around the origin.Absolute values for a and b need not ever exceed 2, though I use 2.5 So, you have to have two nested loops that look something like:For a= Alow to Ahigh by Ainc; increment by AincFor b= Blow to Bhigh by Binc; increment by Binc; perform all the iterations of C [below] until either; number of iterations > IterMax [you're IN the MS, color=Black] or; asq + bsq > 4. [Avoid taking the square root]Next b;Next a; Now I can answer your question. Where you start is with selecting the low and high values of a -- and the low and high values of b. The increments you will use are determined by the number of pixel columns and pixel rows you will have in your final graphic. Say you choose 640 columns by 520 rows. (I did) And say you start with Alow=-2.5, Ahigh=+2.5, Blow=-2.5, Bhigh=+2.5.Then Ainc will be 5/640, Binc will be 5/520. This will display the entire MS. Now let's look at the iteration code INSIDE the double loop above.Then C(1) = C(0)^2 + C(0)C(1) = a', b'i, where we have to calculate the new a' and b'asq = a*a;bsq = b*b; a' = asq - bsq + a;b' = 2*a*b + b;CntIter = CntIter+1;newCsquare = asq+bsq; Your iterations of C(n) stop under either of two conditions:newCsquare > 4, in which case you plot the point with color CntIter,or CntIter > IterMax, in which case you plot the point with color Black.Then you fall into the bottom of the double nested loop, calculate the coordinates of the next pixel in the next column (or the first pixel in the next row) and repeat. The tricky part in all this is the geometry of your display. Your question reflects that this is indeed the part you tripped on. No shame in that. I had to draw a dozen hand-drawn, pencil-on-paper diagrams showing the relations of my final pixel space, the rectangular subset of the starting MS values (-2.5<a<2.5;-2.5<b<2.5), the coordinates of the center of my rectangle, and the a-increment and b-increment, before I wrote successful code. This should get you started. If you get stuck, I'm here. Quote
Tormod Posted March 8, 2006 Report Posted March 8, 2006 Really dude... your screen and mine do not offer the same options!! [ATTACH]474[/ATTACH] This is correct - only moderators and members with more than 1,000 posts can delete posts. Check out the How To on the user levels in the How To forum. Quote
InfiniteNow Posted March 8, 2006 Report Posted March 8, 2006 This is correct - only moderators and members with more than 1,000 posts can delete posts. Check out the How To on the user levels in the How To forum.Thanks T. I knew that. I was more responding the the <doh> implications of Q's post to me... no worries... :naughty: Quote
TheBigDog Posted March 8, 2006 Report Posted March 8, 2006 This should get you started. If you get stuck, I'm here.I am going to need a little more hand holding on this Pyro. I am all set with the nested loops and the dimensions of the field. I am working out how to do the colors. I am also including controls for rotating, panning and zooming. I am OK with the conditions for ending the recursive calculation, and what to do with the results. My problem is knowing how to do the recursive calculations... Now let's look at the iteration code INSIDE the double loop above.Then C(1) = C(0)^2 + C(0)C(1) = a', b'i, where we have to calculate the new a' and b'asq = a*a;bsq = b*b; a' = asq - bsq + a;b' = 2*a*b + b;CntIter = CntIter+1;newCsquare = asq+bsq;This part has me stumped.:naughty: :umno: Help me Pyrotex! Help! Bill Quote
Pyrotex Posted March 8, 2006 Report Posted March 8, 2006 I...Help me Pyrotex! Help!"Here He comes, to save the day!"Means that Pyrotex, is on the way!:naughty: Sure! Glad to help!The basics of complex arithmetic: We do CA on the Complex Plane, where the X-axis is "real"and the Y-axis is "imaginary". All values up and down the Y-axis are considered to be multiplied by the square root of minus one, or "i". "Numbers" in the CP correspond to points, with a real component and an imaginary component. For example, (3,4i) or (-17,-i). Sometimes (often) complex numbers are represented as 3+4i or -17-i. Assume two complex numbers A and C: (a,b,c,d are all real)A = a + biC = c + di --------------Complex Arithmetic:ADDITIONE = A + C = a + bi + c + di = (a+c) + (b+d)i MULTIPLICATIONF = A * C = (a + bi)*(c + di) = a*c + a*di + bi*c + bi*di = a*c + (a*d + b*c)i + b*d*(-1) = a*c - b*d + (a*d + b*c)i SQUARINGG = A squared = (a + bi)*(a + bi) = a*a - b*b + (a*b + a*b)i = a*a - b*b + (2*a*b)i So, in the code you have trouble with, this is how the math works. We are squaring a complex value and then adding the complex value. A^2 + A would equal[a*a - b*b + (2*a*b)i] + [a + bi] but it is easier to keep the squares in their own variable as you need them again for the iteration test. Although the algorithm I gave you works just fine, technically you should ADD first THEN square. Starting with initial value zero: 0 + 0i. It works out the same except for calculating the distance of the new point from the origin. If you do it properly (Add, Square) then the distance from the new point A [a+bi] to the origin is:distance = sqroot[ a*a + b*b ] But it REALLY speeds up the algorithm if you avoid taking the squareroot!!!So, instead of testing if distance <2Rather, test if distance^2 <4Distance^2 is just a*a + b*b, or in the code, asq + bsq. Does this help??? Quote
TheBigDog Posted March 8, 2006 Report Posted March 8, 2006 Does this help???Yes, thank you. :hyper: I am going to spend some time digesting this. I think my brain is getting a blister. Off to the math battle! :smart: = (:umno:^2 + :rant:^2) - (:naughty:^2 - (Sqrt(:hammer:)) / Pi / (Log(:lol: + :umno: + :hihi:) / :doh: = :smart: + :smile: Bill Quote
Pyrotex Posted March 10, 2006 Report Posted March 10, 2006 I love Pyro's posts and Attachment(s)...So, Rac,did you download the Mandelbrot Explorer and actually check it out?Does anyone need instructions for using the MX?And I am curious as to how BigDog is doing. Has he gotten his MX to work, yet?Has anyone ELSE actually played with MX? [...the sound of crickets in the distance...]:) Quote
TheBigDog Posted March 10, 2006 Report Posted March 10, 2006 ;) Oh where Oh whereHas my Pyrotex goneOh where Oh where can he beeeee?:) I am not as helpless as Polly Purebred, but I am struggling with this complex math! I get what you told me in the last letter. Now I am struggling with how the iterations actually happen. When I take c(0) and find c(1), I know what the values for a and b are for c(0). But what are the values for a and b for c(1). This stuff is about where I quit school and joined the carnival (figurativly). The more I understand the more I am lost on this. :) I only need to build this thing one damn time and it will be out of my system! :eek: Thanks for the help on this Pyro! Bill Quote
Racoon Posted March 10, 2006 Author Report Posted March 10, 2006 So, Rac,did you download the Mandelbrot Explorer and actually check it out?Does anyone need instructions for using the MX?And I am curious as to how BigDog is doing. Has he gotten his MX to work, yet?Has anyone ELSE actually played with MX? [...the sound of crickets in the distance...];) Yes I did Pyro!Like I said.. You Da' man.. Thing goes on infinitely now..,It's So Rad :) :eek: :) Having Computer troubles right now..This AI will be bouncing around terminals.. Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.