Logo by Fiery - Contribute your own Logo!

END OF AN ERA, FRACTALFORUMS.COM IS CONTINUED ON FRACTALFORUMS.ORG

it was a great time but no longer maintainable by c.Kleinhuis contact him for any data retrieval,
thanks and see you perhaps in 10 years again

this forum will stay online for reference
News: Visit the official fractalforums.com Youtube Channel
 
*
Welcome, Guest. Please login or register. April 23, 2024, 10:47:20 AM


Login with username, password and session length


The All New FractalForums is now in Public Beta Testing! Visit FractalForums.org and check it out!


Pages: 1 ... 9 10 [11] 12 13 ... 17   Go Down
  Print  
Share this topic on DiggShare this topic on FacebookShare this topic on GoogleShare this topic on RedditShare this topic on StumbleUponShare this topic on Twitter
Author Topic: SuperFractalThing: Arbitrary precision mandelbrot set rendering in Java.  (Read 102533 times)
0 Members and 1 Guest are viewing this topic.
Kalles Fraktaler
Fractal Senior
******
Posts: 1458



kallesfraktaler
WWW
« Reply #150 on: August 28, 2013, 10:24:42 AM »

Some members here have expressed their hopes that it would be possible to use only single precision float datatypes when rendering Mandelbrot fractals with this pertubation theory, in order to implement it in GPU, and I did investigations that showed that it was not possible.

However, I did some tests by changing the mantissa member of my floatexp class to be of float instead of double, and the locations I tried so far renders fine with that.
So, the problem using single precision float may not be the precision of the mantissa, which seems to be sufficient.
The problem may instead be that the pertubation calculations have intermediate steps that exceeds the exponent range of the float datatype, (10^-38 - 10^+38)

I hope those who wants to implement this in GPU can use this information and make an extremely fast unlimited Mandelbrot explorer! cheesy
Logged

Want to create DEEP Mandelbrot fractals 100 times faster than the commercial programs, for FREE? One hour or one minute? Three months or one day? Try Kalles Fraktaler http://www.chillheimer.de/kallesfraktaler
http://www.facebook.com/kallesfraktaler
Roquen
Iterator
*
Posts: 180


« Reply #151 on: August 28, 2013, 11:51:13 AM »

Have I every mentioned that squaring first drastically increases the bound on error? smiley  Seriously...pull out a power of two scale factor.  Out of curiosity I'd assume that someone has tried comparing straight doubles vs. unevaluated sequences (double-double & quad-doubles are examples) for visual impact.  If they increase then the techniques behind can be used to create a computation sequence with performance somewhere in the middle of using straight doubles and a generic method.
Logged

All code submitted by me is in the public domain. (http://unlicense.org/)
hapf
Fractal Lover
**
Posts: 219


« Reply #152 on: August 28, 2013, 12:11:53 PM »

So, the problem using single precision float may not be the precision of the mantissa, which seems to be sufficient.
The problem may instead be that the pertubation calculations have intermediate steps that exceeds the exponent range of the float datatype, (10^-38 - 10^+38)
I'm using long double which has a huge exponent range (-4932 - +4932). It does not stop the blobs/distortions from popping up. The mantissa is the problem here. For less demanding regions float might be fine with larger exponent range, but it will fail when zoomed deeper in long before long double will fail.
I see only two solutions to this problem.
- Use arbitrary precision also with formula (1)(no series approximation), with just enough bits to avoid the distortions. That robs the method of its superior hardware float speeds, but is still quite some faster than using full arbitrary precision with bits as required for the normal approach.
- Reliably detect the distortions and assign better suited references in these regions. How to do that automatically, reliably and fast is an open question to me. If any of you have the solution I'm all ears to hear about your approach.
Consider that series approximation approximates (1) and reliably keeping it under control not to deviate too much from (1) will not solve the problems with (1) itself coming from rounding errors summing up gradually to more or less visible corruptions of the image. The higher resolution your image the more different places can pop up that are corrupted and need to be addressed.
« Last Edit: August 29, 2013, 09:42:37 AM by hapf, Reason: fix error » Logged
Kalles Fraktaler
Fractal Senior
******
Posts: 1458



kallesfraktaler
WWW
« Reply #153 on: August 28, 2013, 11:26:07 PM »

I'm using long double which has a huge exponent range (-4932 - +4932). It does not stop the blobs/distortions from popping up.
I was not referring to the blobs, my previous test using float was not able to create images at all.
But with long double you would be able to zoom to e4932 without having to create any custom datatypes.
I wonder how performance is on the long double datatype compared to double in a 64-bit CPU, does anybody know? Also, is the float datatype really faster on a 64-bit CPU, I would imagine it would be faster on 32-bit but not on 64...?

- Use arbitrary precision also with formula (2), with just enough bits to avoid the distortions.
I don't think this will help, the series approximation just gives you iterations that can be skipped on formula (1), and it is still formula (1) that is used to calculate the pixels. If you would use arbitrary precision on formula (1) it might solve all blobs, you would only gain a little performance with series approximation on simple locations but loose performance on complex ones.
- Reliably detect the distortions and assign better suited references in these regions. How to do that automatically, reliably and fast is an open question to me. If any of you have the solution I'm all ears to hear about your approach. ... The higher resolution your image the more different places can pop up that are corrupted and need to be addressed.
Indeed there can be many blobs on the same image and more to appear when the resolution is increased, and I haven't found any reliable way to detect them all (Pauldebrot might?). I rely on the ability to eventually add references manually...
This one is particularly nasty:
http://www.fractalforums.com/images-showcase-(rate-my-fractal)/flake/
« Last Edit: August 28, 2013, 11:29:54 PM by Kalles Fraktaler » Logged

Want to create DEEP Mandelbrot fractals 100 times faster than the commercial programs, for FREE? One hour or one minute? Three months or one day? Try Kalles Fraktaler http://www.chillheimer.de/kallesfraktaler
http://www.facebook.com/kallesfraktaler
hapf
Fractal Lover
**
Posts: 219


« Reply #154 on: August 29, 2013, 09:41:00 AM »

I meant arbitrary precision on formula 1, not 2. On 2 it's useless, of course.  grin

Logged
Roquen
Iterator
*
Posts: 180


« Reply #155 on: August 29, 2013, 10:01:04 AM »

Has anyone attempting seeing how equipotential lines are in the problem areas or the proximity of periodic points or how the gradient field looks, etc?
Logged

All code submitted by me is in the public domain. (http://unlicense.org/)
hapf
Fractal Lover
**
Posts: 219


« Reply #156 on: August 29, 2013, 10:04:50 AM »

Is it looking correct on your image? Did you tweak that a lot? I get your image pretty much directly when rendering with the central minibrot. Does not look very problematic to me (at smaller sizes). Just kind of boring/blobby look when not enough colours are pumped into it.
Logged
hapf
Fractal Lover
**
Posts: 219


« Reply #157 on: August 29, 2013, 10:12:59 AM »

Has anyone attempting seeing how equipotential lines are in the problem areas or the proximity of periodic points or how the gradient field looks, etc?
What problem areas? Areas where distortions happen? These areas are due to the reference point so they come and go with different reference points. What often happens is that the distance measure clips there too leaving blobs or dithered areas behind where there should be proper structure. So the gradients and equipotential lines get distorted.
Logged
Roquen
Iterator
*
Posts: 180


« Reply #158 on: August 29, 2013, 10:43:43 AM »

I was thinking long the lines of choosing reference points.
Logged

All code submitted by me is in the public domain. (http://unlicense.org/)
hapf
Fractal Lover
**
Posts: 219


« Reply #159 on: August 29, 2013, 11:27:22 AM »

I was thinking long the lines of choosing reference points.
The solution must come from a better understanding why one reference point produces more rounding errors with a specific point than another. 2 main factors to look into:
- distance of reference point (generally the farer away from the region/picture/point the worse)
- dominant period of point and reference point and how well the 'jumping around patterns' are in harmony (to be defined clearly what in harmony means regarding to rounding errors)
« Last Edit: August 29, 2013, 11:33:32 AM by hapf » Logged
Kalles Fraktaler
Fractal Senior
******
Posts: 1458



kallesfraktaler
WWW
« Reply #160 on: August 29, 2013, 02:51:20 PM »

Is it looking correct on your image? Did you tweak that a lot? I get your image pretty much directly when rendering with the central minibrot. Does not look very problematic to me (at smaller sizes). Just kind of boring/blobby look when not enough colours are pumped into it.
There are a lot of small spirals in this flake image, and many references are needed to render them all...
Logged

Want to create DEEP Mandelbrot fractals 100 times faster than the commercial programs, for FREE? One hour or one minute? Three months or one day? Try Kalles Fraktaler http://www.chillheimer.de/kallesfraktaler
http://www.facebook.com/kallesfraktaler
Kalles Fraktaler
Fractal Senior
******
Posts: 1458



kallesfraktaler
WWW
« Reply #161 on: August 29, 2013, 03:13:17 PM »

The solution must come from a better understanding why one reference point produces more rounding errors with a specific point than another. 2 main factors to look into:
- distance of reference point (generally the farer away from the region/picture/point the worse)
- dominant period of point and reference point and how well the 'jumping around patterns' are in harmony (to be defined clearly what in harmony means regarding to rounding errors)
From what I understand from Pauldebrot's explanation, and animation, of his solution is that he tried to narrow down areas where the iterations increase until it ends in a plateau with equal iterations - and that is where the blob is. But my experience is that the blobs also can occur in the middle of areas with decreasing iterations, or areas where the iterations increase and then a narrow surrounding of decreased iterations just around the blob. Or many other situations.
I think his approach is correct though, that the all blobs appear as a plateau on increasing iterations, but since our images are based on pixels, pixels may not be enough resolution to identify increasing iterations surrounding plateaus.
It's like a landscape with hills and valleys, and some of the hill-tops are chopped off - these are what we are to find. They usually have a round shape, but since they can be in the edge of an image, they can have any shape.
Logged

Want to create DEEP Mandelbrot fractals 100 times faster than the commercial programs, for FREE? One hour or one minute? Three months or one day? Try Kalles Fraktaler http://www.chillheimer.de/kallesfraktaler
http://www.facebook.com/kallesfraktaler
hapf
Fractal Lover
**
Posts: 219


« Reply #162 on: September 17, 2013, 06:09:36 PM »

AIUI, Superfractalthing also has some method for determining when a second reference point is needed; I don't know about Kallesfractaler, though, or the methods either use. I've described mine in the hope that it may be helpful to either of their authors, and in the hope that someone might have a useful suggestion for speeding my own up.
I don't know about speed up potential but once you have a region located that contains a blob or is inside a blob and you look for the pixel with the highest iteration count to serve as a second reference you can instead of checking pixels simply compute the location of the period center of a minibrot in that region. A reasonable guess for a suitable period is the highest iteration count you have seen so far in that region minus one or two starting the computation from the pixel that had that count. If periods get very large though computation time gets quite long. Arbitrary precision is required. One can try to speed up the calculations by using PT again, but the benefits are unfortunately quite limited since rounding errors spoil the result quickly (e.g. endless loops and other anomalies).
Logged
Kalles Fraktaler
Fractal Senior
******
Posts: 1458



kallesfraktaler
WWW
« Reply #163 on: September 17, 2013, 10:21:13 PM »

Beside that, how are things going with your long double SFT program?
I'm very interested in the long double datatype, and Microsoft's compiler does not support it.
I tried "Bloodshed Dev-C++" which supports the 12 byte long double datatype. However the Dev-C++ program had slower performance than my custom datatype.

It would be interesting if anyone could confirm my findings. Is the long double datatype very slow compared to double (some 20 times slower)? Or is Microsoft's compiler super optimized and superior to other compilers? Or did I do something else fundamentally wrong?
Logged

Want to create DEEP Mandelbrot fractals 100 times faster than the commercial programs, for FREE? One hour or one minute? Three months or one day? Try Kalles Fraktaler http://www.chillheimer.de/kallesfraktaler
http://www.facebook.com/kallesfraktaler
hapf
Fractal Lover
**
Posts: 219


« Reply #164 on: September 18, 2013, 10:31:23 AM »

Beside that, how are things going with your long double SFT program?
I'm very interested in the long double datatype, and Microsoft's compiler does not support it.
I tried "Bloodshed Dev-C++" which supports the 12 byte long double datatype. However the Dev-C++ program had slower performance than my custom datatype.
It would be interesting if anyone could confirm my findings. Is the long double datatype very slow compared to double (some 20 times slower)? Or is Microsoft's compiler super optimized and superior to other compilers? Or did I do something else fundamentally wrong?
Long double on Linux is 16 bytes (8 significand, 15 bits exponent, 1 bit sign, rest unused). It is not much slower than double.
64 bit significand is not enough to avoid blobs/corruption, unfortunately. So I'm currently working on the blob fixing part of the program. Automatic reference point generation is done and works well. Quite cool to let the program zoom in automatically to a minibrot in the neighbourhood of a pixel jumping from E-20 to E-40 or E-100 to E-400.
Logged
Pages: 1 ... 9 10 [11] 12 13 ... 17   Go Down
  Print  
 
Jump to:  

Related Topics
Subject Started by Replies Views Last post
Java applet for exploring the Mandelbrot set Announcements & News Paton 5 7089 Last post March 26, 2007, 06:03:34 PM
by Paton
What range/precision for fractional escape counts for Mandelbrot/Julia sets? Programming Duncan C 7 11123 Last post May 01, 2007, 08:23:13 PM
by Duncan C
Java Mandelbrot segment Help & Support fractalwizz 10 2029 Last post December 29, 2008, 08:01:24 PM
by cKleinhuis
[Java] Double-double library for 128-bit precision. Programming Zom-B 10 17320 Last post December 20, 2010, 04:03:48 AM
by David Makin
*Continued* SuperFractalThing: Arbitrary precision mandelbrot set rendering in Java. Announcements & News « 1 2 ... 23 24 » hapf 347 50611 Last post September 28, 2017, 10:20:19 PM
by claude

Powered by MySQL Powered by PHP Powered by SMF 1.1.21 | SMF © 2015, Simple Machines

Valid XHTML 1.0! Valid CSS! Dilber MC Theme by HarzeM
Page created in 0.186 seconds with 25 queries. (Pretty URLs adds 0.02s, 2q)