Tag Info

New answers tagged

7

I revisited this problem - this time in pure Mathematica. The trick to any kind of performance is the Compile[] function, which in itself can be a bit moody - so you need to set global options to warn you when it refuses compilation and work around that. The performance I'm seeing is on the order of magnitude slower than that I get from C++, and two orders ...


12

UPDATE I thought it would be neat to try and animate the thing, so I let the $a$ parameter run between $-\pi$ and $\pi$. I generated 600 images and put them together using ffmpeg. Check it out on youtube. It might not be in the spirit of Mathematica Stack Exchange, but allow me an objection - stuff that is slow in Mathematica should be kept out of it. To ...


21

As @RahulNarain says, forming the image point by point saves significant memory because the number of image pixels is typically much smaller than the hundreds of millions of iterations that compose it. Therefore, iterate the attractor equations, and for each point generated, find its location within the image matrix. Colour coding of the number of hits in ...


2

It depends. A single 32-bit Mathematica process certainly cannot access more than 4GB RAM (since the OS also reserves some memory in the virtual memory space, you actually can use even less). However if you have a 64-bit operating system, or a 32-bit operating system using PAE, then all processes together can use more than 4GB of memory (provided you've got ...


1

When you "call" DoSomething, Mathematica does not assign local variables (as Module does)), but directly substitutes the passed values into the expression (similar to how With works). You can see that with the following code: foo[x_]:=Module[{y=2}, Hold[x,y]] foo[1] (* ==> Hold[1, y$81] *) As you can see, since Hold prevents evaluation, the local ...



Top 50 recent answers are included