### Another possible way to accelerate MB set deep zooming

• 170 Replies
• 5060 Views

0 Members and 1 Guest are viewing this topic.

#### claude

• Fractal Freak
• Posts: 714

#### Re: Another possible way to accelerate MB set deep zooming

« Reply #135 on: July 11, 2018, 04:33:32 PM »
BTW! how to use the kfb in kf?

My unreleased local version of 2.13 has an "open map" menu item, untl I get back from holidays and get around to releasing it (before the end of the month) there is an awkward workaround (make 2 copies with filenames to simulate a zoom out sequence, and use the examine zoom sequence option).

#### knighty

• Fractal Feline
• Posts: 169

#### Re: Another possible way to accelerate MB set deep zooming

« Reply #136 on: July 11, 2018, 05:30:58 PM »
Thanks!

results in error (also with floatexp):
Code: [Select]
prec 323...reference 99%reference 100%__(-6.25841e-039,2.02471e-038)i: 0 j: 0 val: (-6.25841e-039,2.02471e-038)i: 0 j: 1 val: (-1.96551e+037,2.13573e+038)i: 0 j: 2 val: (-4.58167e+077,4.85771e+076)i: 0 j: 3 val: (-4.7727e+116,-5.40481e+116)i: 0 j: 4 val: (-3.63042e+153,-9.02712e+155)i: 0 j: 5 val: (5.05927e+194,-7.85039e+194)i: 0 j: 6 val: (6.91284e+233,-3.90427e+233)i: 0 j: 7 val: (5.17964e+272,-4.77752e+271)i: 0 j: 8 val: (nan,nan)-----------------------i: 1 j: 0 val: (0,0)i: 1 j: 1 val: (0,0)i: 1 j: 2 val: (0,0)i: 1 j: 3 val: (0,0)i: 1 j: 4 val: (0,0)i: 1 j: 5 val: (0,0)i: 1 j: 6 val: (0,0)i: 1 j: 7 val: (0,0)i: 1 j: 8 val: (nan,nan)-----------------------i: 2 j: 0 val: (1.96067e+037,5.61983e+037)i: 2 j: 1 val: (-2.2024e+077,1.29956e+077)i: 2 j: 2 val: (-5.48138e+116,-2.44767e+116)i: 2 j: 3 val: (-4.19078e+155,-9.10237e+155)i: 2 j: 4 val: (1.87276e+194,-1.28232e+195)i: 2 j: 5 val: (7.77988e+233,-1.06878e+234)i: 2 j: 6 val: (8.77197e+272,-5.01584e+272)i: 2 j: 7 val: (nan,nan)i: 2 j: 8 val: (nan,nan)-----------------------i: 3 j: 0 val: (0,0)i: 3 j: 1 val: (0,0)i: 3 j: 2 val: (0,0)i: 3 j: 3 val: (0,0)i: 3 j: 4 val: (0,0)i: 3 j: 5 val: (0,0)i: 3 j: 6 val: (0,0)i: 3 j: 7 val: (nan,nan)i: 3 j: 8 val: (nan,nan)-----------------------i: 4 j: 0 val: (-2.0335e+076,2.90788e+076)i: 4 j: 1 val: (-1.6659e+116,1.24564e+114)i: 4 j: 2 val: (-3.15833e+155,-2.72496e+155)i: 4 j: 3 val: (-2.00457e+194,-6.9078e+194)i: 4 j: 4 val: (1.83801e+233,-8.98552e+233)i: 4 j: 5 val: (4.91485e+272,-6.82772e+272)i: 4 j: 6 val: (nan,nan)i: 4 j: 7 val: (nan,nan)i: 4 j: 8 val: (nan,nan)-----------------------i: 5 j: 0 val: (0,0)i: 5 j: 1 val: (0,0)i: 5 j: 2 val: (0,0)i: 5 j: 3 val: (0,0)i: 5 j: 4 val: (0,0)i: 5 j: 5 val: (0,0)i: 5 j: 6 val: (nan,nan)i: 5 j: 7 val: (nan,nan)i: 5 j: 8 val: (nan,nan)-----------------------i: 6 j: 0 val: (-1.39761e+115,6.49331e+114)i: 6 j: 1 val: (-7.40746e+154,-2.16553e+154)i: 6 j: 2 val: (-1.30096e+194,-1.51392e+194)i: 6 j: 3 val: (-7.59412e+232,-3.30762e+233)i: 6 j: 4 val: (7.59552e+271,-3.81625e+272)i: 6 j: 5 val: (nan,nan)i: 6 j: 6 val: (nan,nan)i: 6 j: 7 val: (nan,nan)i: 6 j: 8 val: (nan,nan)-----------------------i: 7 j: 0 val: (0,0)i: 7 j: 1 val: (0,0)i: 7 j: 2 val: (0,0)i: 7 j: 3 val: (0,0)i: 7 j: 4 val: (0,0)i: 7 j: 5 val: (nan,nan)i: 7 j: 6 val: (nan,nan)i: 7 j: 7 val: (nan,nan)i: 7 j: 8 val: (nan,nan)-----------------------i: 8 j: 0 val: (-5.29966e+153,7.63241e+152)i: 8 j: 1 val: (-2.51361e+193,-1.16334e+193)i: 8 j: 2 val: (-4.29235e+232,-5.60971e+232)i: 8 j: 3 val: (-2.47219e+271,-1.05116e+272)i: 8 j: 4 val: (nan,nan)i: 8 j: 5 val: (nan,nan)i: 8 j: 6 val: (nan,nan)i: 8 j: 7 val: (nan,nan)i: 8 j: 8 val: (nan,nan)-----------------------i: 9 j: 0 val: (0,0)i: 9 j: 1 val: (0,0)i: 9 j: 2 val: (0,0)i: 9 j: 3 val: (0,0)i: 9 j: 4 val: (nan,nan)i: 9 j: 5 val: (nan,nan)i: 9 j: 6 val: (nan,nan)i: 9 j: 7 val: (nan,nan)i: 9 j: 8 val: (nan,nan)-----------------------i: 10 j: 0 val: (-1.53728e+192,-9.23556e+189)i: 10 j: 1 val: (-6.91756e+231,-3.6916e+231)i: 10 j: 2 val: (-1.10019e+271,-1.42216e+271)i: 10 j: 3 val: (nan,nan)i: 10 j: 4 val: (nan,nan)i: 10 j: 5 val: (nan,nan)i: 10 j: 6 val: (nan,nan)i: 10 j: 7 val: (nan,nan)i: 10 j: 8 val: (nan,nan)-----------------------i: 11 j: 0 val: (0,0)i: 11 j: 1 val: (0,0)i: 11 j: 2 val: (0,0)i: 11 j: 3 val: (nan,nan)i: 11 j: 4 val: (nan,nan)i: 11 j: 5 val: (nan,nan)i: 11 j: 6 val: (nan,nan)i: 11 j: 7 val: (nan,nan)i: 11 j: 8 val: (nan,nan)-----------------------i: 12 j: 0 val: (-3.61951e+230,-2.27447e+229)i: 12 j: 1 val: (-1.47154e+270,-7.75297e+269)i: 12 j: 2 val: (nan,nan)i: 12 j: 3 val: (nan,nan)i: 12 j: 4 val: (nan,nan)i: 12 j: 5 val: (nan,nan)i: 12 j: 6 val: (nan,nan)i: 12 j: 7 val: (nan,nan)i: 12 j: 8 val: (nan,nan)-----------------------i: 13 j: 0 val: (0,0)i: 13 j: 1 val: (0,0)i: 13 j: 2 val: (nan,nan)i: 13 j: 3 val: (nan,nan)i: 13 j: 4 val: (nan,nan)i: 13 j: 5 val: (nan,nan)i: 13 j: 6 val: (nan,nan)i: 13 j: 7 val: (nan,nan)i: 13 j: 8 val: (nan,nan)-----------------------i: 14 j: 0 val: (-6.58325e+268,-3.78638e+267)i: 14 j: 1 val: (-inf,-inf)i: 14 j: 2 val: (nan,nan)i: 14 j: 3 val: (nan,nan)i: 14 j: 4 val: (nan,nan)i: 14 j: 5 val: (nan,nan)i: 14 j: 6 val: (nan,nan)i: 14 j: 7 val: (nan,nan)i: 14 j: 8 val: (nan,nan)-----------------------i: 15 j: 0 val: (0,0)i: 15 j: 1 val: (nan,nan)i: 15 j: 2 val: (nan,nan)i: 15 j: 3 val: (nan,nan)i: 15 j: 4 val: (nan,nan)i: 15 j: 5 val: (nan,nan)i: 15 j: 6 val: (nan,nan)i: 15 j: 7 val: (nan,nan)i: 15 j: 8 val: (nan,nan)-----------------------i: 16 j: 0 val: (-6.60808e+306,-8.92928e+304)i: 16 j: 1 val: (nan,nan)i: 16 j: 2 val: (nan,nan)i: 16 j: 3 val: (nan,nan)i: 16 j: 4 val: (nan,nan)i: 16 j: 5 val: (nan,nan)i: 16 j: 6 val: (nan,nan)i: 16 j: 7 val: (nan,nan)i: 16 j: 8 val: (nan,nan)-----------------------R == nanreal 0m8.290suser 0m0.000ssys 0m0.015s
But, wait! That log comes from using double not floatexp.
floatexp works fine for me. I'm having trouble with long float though. It is extremely slow, much slower than floatexp. :-/

It seems the "dirty spots" are caused by the interior DE code...

• 3f
• Posts: 1352

#### Re: Another possible way to accelerate MB set deep zooming

« Reply #137 on: July 11, 2018, 07:27:59 PM »
Humm... Finding the atom domain is simpler:
rmin = inf
z = 0
input c
for(i=0; i < maxiter; i++)
z = z² + c
if (|z| < rmin)
rmin = |z|
nucleus_center = find_nucleus(z, period = i+1) //optional: this supposes you have a method to find the nucleus
add_atom_domain(za = z, period = i+1, nucleus_center)
endif
endfor

This gives the list of atom domains at c. BTW! how to use the kfb in kf?
That doesn't work when center is not escaping, as in my example. Use kfb is described in KF docs (toward end).

Added: If center is not escaping, picking random points until I find an escaping one, then take the largest atom domain of that seems to work always. Sounds like a stupid method though...
« Last Edit: July 11, 2018, 09:17:03 PM by gerrit »

• 3f
• Posts: 1352

#### Re: Another possible way to accelerate MB set deep zooming

« Reply #138 on: July 11, 2018, 08:37:49 PM »
Thanks!
But, wait! That log comes from using double not floatexp.
floatexp works fine for me. I'm having trouble with long float though. It is extremely slow, much slower than floatexp. :-/

It seems the "dirty spots" are caused by the interior DE code...
Thanks, it's a problem parsing command line arguments: if I put a carriage return after --force_type 'floatexp' in my shell script it is ignored.
So was using 'double' all along...

Indeed 'long double' is much slower than 'floatexp'??

#### knighty

• Fractal Feline
• Posts: 169

#### Re: Another possible way to accelerate MB set deep zooming

« Reply #139 on: July 12, 2018, 02:02:46 PM »
Indeed 'long double' is much slower than 'floatexp'??
It must be the compiler which doesn't seem to emit good 387 fpu code when mixing doubles and long doubles. In the old nmb, double floats are much faster. Maybe compiling the long double part separately will solve the issue.

#### knighty

• Fractal Feline
• Posts: 169

#### Re: Another possible way to accelerate MB set deep zooming

« Reply #140 on: July 12, 2018, 02:13:58 PM »
That doesn't work when center is not escaping, as in my example. Use kfb is described in KF docs (toward end).

Added: If center is not escaping, picking random points until I find an escaping one, then take the largest atom domain of that seems to work always. Sounds like a stupid method though...
I don't understand why it wouldn't work when the center doesn't escape. In the case you gave, the "good" period is 155. The higher periods are all multiples of 155 because they correspond to the discs. In SSA context, the escape radius of the cardioid is much bigger than those of the discs.
I hope, this will be solved in nanomb02 soon enought.

Here is a new version of nanomb where I tried to solve the 'dirty spots' issue. They are definitely caused by the interior DE code: When the root finding loop ends, some points may be erroneously classified as inside.

#### claude

• Fractal Freak
• Posts: 714

#### Re: Another possible way to accelerate MB set deep zooming

« Reply #141 on: July 12, 2018, 05:31:24 PM »
Here is a new version of nanomb where I tried to solve the 'dirty spots' issue. They are definitely caused by the interior DE code: When the root finding loop ends, some points may be erroneously classified as inside.

Three issues may be at work.
1. the interior checking code absolutely requires the reference to be at the nucleus of the island (not any of its child discs, and certainly not some random point)
2. I didn't add a proper epsilon calculation, and just used 0.  May work for (long) double due to underflow to 0, but floatexp underflow may be buggy?
3. there is also the chance the algorithm may be fundamentally flawed, I have no mathematical proof it works.

• 3f
• Posts: 1352

#### Re: Another possible way to accelerate MB set deep zooming

« Reply #142 on: July 12, 2018, 07:20:37 PM »
I don't understand why it wouldn't work when the center doesn't escape. In the case you gave, the "good" period is 155. The higher periods are all multiples of 155 because they correspond to the discs. In SSA context, the escape radius of the cardioid is much bigger than those of the discs.

In the example the |z| minima are at 930 620 310 155 93 31 9 7 6 5 4 3 2 1, so how can you figure out that 155 is the mini-nucleus and the others are either bulbs or repetitions? Find first number going down that is divisor of all the higher numbers?

I thought problem was that atom of period p shows up as dip at iter=p but also dips at 2p, 3p, etc. If escaping those harmonics are larger (working its way out) but for stable orbit the harmonics get smaller, so you need some code to analyse that?

#### claude

• Fractal Freak
• Posts: 714

#### Re: Another possible way to accelerate MB set deep zooming

« Reply #143 on: July 12, 2018, 10:44:21 PM »
I would do it with the shape estimate, that tells you if your nucleus is in a cardioid or a disc, see https://mathr.co.uk/mandelbrot/book-draft/#shape-estimate

• 3f
• Posts: 1352

#### Re: Another possible way to accelerate MB set deep zooming

« Reply #144 on: July 12, 2018, 10:53:21 PM »
I would do it with the shape estimate, that tells you if your nucleus is in a cardioid or a disc, see https://mathr.co.uk/mandelbrot/book-draft/#shape-estimate
Nice, but that would require you to first find the centers of all the periods you detect.
You know any way to do it just from the minima of the single orbit? Perhaps not possible...

• 3f
• Posts: 1352

#### Re: Another possible way to accelerate MB set deep zooming

« Reply #145 on: July 13, 2018, 05:50:21 AM »
Here is a new version of nanomb where I tried to solve the 'dirty spots' issue. They are definitely caused by the interior DE code: When the root finding loop ends, some points may be erroneously classified as inside.
Seems to be fixed, see my image thread.
I wish I could understand your code. I know a bit of C and C++ but this code is over my head.

#### knighty

• Fractal Feline
• Posts: 169

#### Re: Another possible way to accelerate MB set deep zooming

« Reply #146 on: July 14, 2018, 09:23:41 PM »
Seems to be fixed, see my image thread.
I wish I could understand your code. I know a bit of C and C++ but this code is over my head.
It is always the case with the code written by other people . Mine is only more obfuscated. sorry.
It is a temporary fix: There are some dots when using float exp. I hope claude will do a better fix.

Nice, but that would require you to first find the centers of all the periods you detect.
You know any way to do it just from the minima of the single orbit? Perhaps not possible...

Why impossible? The interior DE does that. see interior coordinates for exmple and replace z0 by 0 in the equation to solve. when you have an SA or SSA it is simpler somehow: If there is a nearby nucleus, its relative position (wrt SA or SSA center) is just the root(s). That's what is done in smb and nanomb02.
Thanks a lot claude for the document. I'll try to integrate the shape estimate in nanomb.

For nanoMB02, I couldn't find a cure for the "glitches". Meanwhile I got some good results more "by chance"
than anything else. I think I'll give up trying for some time...

• 3f
• Posts: 1352

#### Re: Another possible way to accelerate MB set deep zooming

« Reply #147 on: July 14, 2018, 09:44:44 PM »
I would do it with the shape estimate, that tells you if your nucleus is in a cardioid or a disc, see https://mathr.co.uk/mandelbrot/book-draft/#shape-estimate
That works very well. Made some script that goes through the periods from the atom domains of an image and renders the cardioids it finds.
Periods 25772, 1516, 360, 60, 12, 3: fun!

#### knighty

• Fractal Feline
• Posts: 169

#### Re: Another possible way to accelerate MB set deep zooming

« Reply #148 on: July 15, 2018, 08:34:44 PM »
Coool!

• 3f
• Posts: 1352

#### Re: Another possible way to accelerate MB set deep zooming

« Reply #149 on: July 16, 2018, 07:19:07 AM »
For nanoMB02, I couldn't find a cure for the "glitches". Meanwhile I got some good results more "by chance"
than anything else. I think I'll give up trying for some time...
Too bad. Not sure how you do it, but I thought like this?

1) Get atom domain periods from center of image.
2) Find centers of the found periods and keep the ones that are nucleus of cardioid, say p1=1,p2,p3,p4.
3) Do SSA(p4) iterations. Consider pixel c. If not escaped, done, else if has escaped at iter n*p4 switch to p3.
4a) Start all over from scratch with c using p3. (Probably not.)
4b)  Continue where we were, but n*p4 is not a multiple of p3. What to do? Find smallest i such that n*p4+i is multiple k of p3, so we can start SSA(p2) at iter k. To find z(n*p4+i) do normal PT for i iterations (probably using reference p4-nucleus).
5) Continue until you hit p1=1, which means finishing off using normal PT.

Anything I get wrong?

### Similar Topics

###### Speeding up deep zooming using neural networks / deep learning?

Started by greentexas on Fractal Mathematics And New Theories

27 Replies
1229 Views
December 13, 2017, 10:43:46 PM
by Byte11
###### a way to accelerate Mandelbrot (etc) deep zoom world record attempts

Started by claude on Fractal Mathematics And New Theories

4 Replies
285 Views
February 19, 2018, 04:46:10 PM
by claude
###### How to avoid zooming too deep?

Started by noahfence on Mandelbulber

2 Replies
169 Views
June 10, 2018, 02:47:48 AM
by mclarekin
###### Mandelbrot set deep zooming in the web browser

Started by claude on Other

0 Replies
299 Views
October 29, 2017, 11:00:15 PM
by claude
###### Deep n brassy

Started by timemit on Fractal Image Gallery

0 Replies
185 Views
November 09, 2017, 07:11:35 PM
by timemit