Logo by jodyvl - Contribute your own Logo!
News: Support us via Flattr FLATTR Link
 
*
Welcome, Guest. Please login or register. September 24, 2017, 04:10:31 PM


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 [2] 3   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: Multiwave coloring for Mandelbrot  (Read 4780 times)
Description: UF coloring
0 Members and 1 Guest are viewing this topic.
fractalchemist
Forums Freshman
**
Posts: 19



fractalchemist fractalchemist fractalchemist
WWW
« Reply #15 on: November 21, 2012, 03:13:03 PM »

Hello Paul,
 A link to your UCL has been sent to the UF mailing list today.
I am sure that many would like to see some examples of this colouring with specific settings.
If it is not too much to ask? angel
I don't know if you are on the list, or maybe you could post them here...
thanks in advance, Evie
Logged

makc
Strange Attractor
***
Posts: 272



« Reply #16 on: April 01, 2013, 10:10:56 PM »

woah I have finally found the thread. and woah that's a lot going on in that ucl file. why the heck does it have to be that complex, I mean the output does look just like simple short-period luma wave x long-period hue wave (well, actually not "wave" but star-like 2D path in color wheel)
« Last Edit: April 01, 2013, 10:37:30 PM by Sockratease, Reason: Naughty Language Editing = Nothing else touched! » Logged
Pauldelbrot
Fractal Senior
******
Posts: 2590



pderbyshire2
« Reply #17 on: April 02, 2013, 12:43:19 AM »

woah I have finally found the thread. and woah that's a lot going on in that ucl file. why the heck does it have to be that complex, I mean the output does look just like simple short-period luma wave x long-period hue wave (well, actually not "wave" but star-like 2D path in color wheel)

It's not so much "complex" as "repetitive". It does the same thing for each of several possible modifying waves, and that thing includes computing tricubic splines joining cycles of points in \mathbb{R}^3, which itself is fairly involved. There's also a bunch of options that toggle alternative code paths.

Needless to say, the original is a lot tidier than the port to UF's .ucl-entry language, with multiple functions including a general spline calculating function. smiley
Logged

Kalles Fraktaler
Fractal Senior
******
Posts: 1444



kallesfraktaler
WWW
« Reply #18 on: April 30, 2014, 12:08:20 PM »

Unfortunately I'm having a hard time to understand how this works.
Isn't there any easier way to explain this?

From what I found out so far, just applying waves with different periodicity does not make the same fantastic color, because the more waves the more grayish the image becomes. Even if the waves are sine with prime numbers as periodicity.

It seems Pauldelbrot applying different waves periods on different iteration intervals?
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
Pauldelbrot
Fractal Senior
******
Posts: 2590



pderbyshire2
« Reply #19 on: April 30, 2014, 01:29:09 PM »

Unfortunately I'm having a hard time to understand how this works.
Isn't there any easier way to explain this?

From what I found out so far, just applying waves with different periodicity does not make the same fantastic color, because the more waves the more grayish the image becomes. Even if the waves are sine with prime numbers as periodicity.

It seems Pauldelbrot applying different waves periods on different iteration intervals?

Are you trying to add many waves in a gradient of only a few hundred to a thousand points, then spanned across a few iterations or logmapped or something?

That's not how mine works. Mine looks up the iteration number in each of several periodic gradients of, typically, vastly differing lengths, such as 7, 17, 492, 1720, and 40180. Then it combines the colors it looks up, using a form of "addition" where hues add up cyclically (with red as the "zero") and saturation and luminance add in such a way that when the value is strictly between 0 and 1, the sum is as well; adding lots of values close to 1 produces a value closer to 1, but not quite reaching it, like the speed of light in relativity. On the other hand this happens at zero, too; adding numbers under 0.5 (the "zero" for saturation and luminance) to a larger number drags it down, but with diminishing returns so it won't quite go all the way to zero.

That's the ucl version. Nanoscope's is a bit more sophisticated. Hues are added and interpolated on a wheel with red, yellow, green, blue equally spaced, to better fit human color perception (in particular, red and yellow are treated as equidistant to yellow and green, green and blue, blue and red, rather than half as distant as blue and red; and interpolating from red to green passes through grey, not yellow). Saturation and luminance are minus infinity to infinity and added normally, with zero luminance a middle grey's brightness and zero saturation halfway from grey to full saturation. Conversion of these to more conventional values uses the atan function and an affine transform. Again, pure white, pure black, pure grey, and 100% saturation are not-quite-attainable but approachable.

The thing that is probably most important here, though, is that the waves a) can be orders of magnitude different in lengths, from a few iterations to many tens of thousands or more, and b) are combined using this HSL addition method. There's a few additional niceties ... for example, the waves are mostly linearly mapped but can also be combined with one "regular" gradient that is non-circular and logmapped; and the ucl version gives a few other options for combining some of the components, such as modulating the saturation according to hue proximity (so, where one wave is red, the output "avoids" red and desaturates towards grey when it would approach a saturated red, for instance; so some hues can be muted in one region, and others in another region -- a rainbow cycle with a period of 400 iterations plus a rainbow hue-suppressing cycle with a period of 10,000 will cause a part-rainbow gradient with some colors muted to color features like seahorses, but with which part of the rainbow is muted shifting with depth, which could be achieved also with a rainbow plus a hue-added rainbow, but if the hue-suppressing cycle just alternates strong greens and strong reds, then the rainbow will shift from a red-pale yellow-greyish-pale blue-violet to a greyish-pale yellow-green-blue-pale violet and back).
Logged

Kalles Fraktaler
Fractal Senior
******
Posts: 1444



kallesfraktaler
WWW
« Reply #20 on: April 30, 2014, 11:26:39 PM »

So in a way you are creating an index between 0 and 1 based on waves of different periodicity, and assign different colors to that index, which could be a palette of gradient colors?
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
Pauldelbrot
Fractal Senior
******
Posts: 2590



pderbyshire2
« Reply #21 on: May 01, 2014, 12:20:43 AM »

So in a way you are creating an index between 0 and 1 based on waves of different periodicity, and assign different colors to that index, which could be a palette of gradient colors?

No, that would be much more limited. The waves are added within a color space, rather than just pulling and pushing linearly on a lookup into a single gradient.
Logged

Kalles Fraktaler
Fractal Senior
******
Posts: 1444



kallesfraktaler
WWW
« Reply #22 on: May 01, 2014, 01:32:50 AM »

No, that would be much more limited. The waves are added within a color space, rather than just pulling and pushing linearly on a lookup into a single gradient.
Yes but I mean, if the waves produce the value 0.5663 it will be the same color regardless if the actual iteration was 15 or 15000? The trick is to produce different colors from the value between 0 and 1?
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
Pauldelbrot
Fractal Senior
******
Posts: 2590



pderbyshire2
« Reply #23 on: May 01, 2014, 01:39:45 AM »

Yes but I mean, if the waves produce the value 0.5663 it will be the same color regardless if the actual iteration was 15 or 15000? The trick is to produce different colors from the value between 0 and 1?

The waves don't produce a scalar like 0.5663. They produce an HSL triplet representing a color.
Logged

Kalles Fraktaler
Fractal Senior
******
Posts: 1444



kallesfraktaler
WWW
« Reply #24 on: May 01, 2014, 08:57:11 PM »

The waves don't produce a scalar like 0.5663. They produce an HSL triplet representing a color.
Sorry for all my stupid questions... embarrass
If I applies 4 periods of sine waves on H, S and L separately, one period per H and S, and two, one short and one long, for L, I think I got kind of an OK result...
« Last Edit: May 01, 2014, 08:58:44 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
Pauldelbrot
Fractal Senior
******
Posts: 2590



pderbyshire2
« Reply #25 on: May 02, 2014, 04:02:58 AM »

Sorry for all my stupid questions... embarrass
If I applies 4 periods of sine waves on H, S and L separately, one period per H and S, and two, one short and one long, for L, I think I got kind of an OK result...

Mine are waves of colors, not just of H or S or L. Think of several whole periodic gradients, some much longer (50,000 iters, say) than others (5, say), and the color from each one for the iter value being looked up, then those colors combined. smiley
Logged

kjknohw
Explorer
****
Posts: 45


« Reply #26 on: May 04, 2014, 12:34:53 AM »

Multiwave has to take into account perceptive non-linearities in mind. How many colors you can squeeze in between two colors is not necessarily related to how "different" you think of them. There isn't much "room" between certain colors like blue and gray and red and purple despite sounding unrelated or having very different RGB values. Most multiwave attempts look poor because one wave has a low amplitude in perception space at certain times (like a blue-grey-blue wave), creating poor contrast.

I have the most success when brightness variations are is the higher frequency wave(s) because brightness distances are large and relativly constant and don't interfere with other waves too much.

An image with rainbow coloring (all images below are a linear palette). It is in desperate need of a multiwave method because you can't see eithier the subtle hairs between the curves or what's going on at the center of the cauliflower. The rainbow palette has been distance-adjusted:


Simply adding a light-dark variation at 512 times the frequency and scaling the palette yields a nice result, now the hairs are subtle but visible and the center of the cauliflower is clearer. A frequency of 512 is the highest the program will do.


The multi-wave (which has 4 waves: the rainbow, one saturation, and two luminosities at frequencies 1, 8, 64, and 512) is a richer image but isn't "better" at resolving details:


Do you ever need three? I found a picture where you kind of do (these pictures down-sampled 2x2:1).
The two wave one doesn't show off the intermediate structures well:


The multi-wave one does better. The center structures are less clear but still (mostly) resolvable:


Palette files: (Kalles Fraktaler format, for which colors are listed b1,g2,r1,b2,g2,r2,...)
Simple rainbow:
http://www.developmentserver.com/kevin/2014_mandelPower/multiwave/rainbow_simple.kfp
Two waves:
http://www.developmentserver.com/kevin/2014_mandelPower/multiwave/two_waves.kfp
Four waves (this one is fun to explore in as well since it has nice variety):
http://www.developmentserver.com/kevin/2014_mandelPower/multiwave/four_waves.kfp

Locations (Kalles Fractaler format, but you can copy the Re, Im, and Zoom to your own program)
Two waves needed:
http://www.developmentserver.com/kevin/2014_mandelPower/multiwave/two%20waves%20needed.kfr
More than two waves needed:
http://www.developmentserver.com/kevin/2014_mandelPower/multiwave/three%20waves%20needed.kfr
« Last Edit: May 04, 2014, 12:41:50 AM by kjknohw » Logged
quaz0r
Fractal Molossus
**
Posts: 652



« Reply #27 on: September 17, 2014, 06:43:17 PM »

pauldelbrot your coloring algorithm is really neat.  your renders look great and the idea behind the coloring method sounds interesting.  recently ive been toying around with writing a mandelbrot viewer as a way to learn about fractals and as a fun way to get back into programming.  though ive been left scratching my head thinking how one can approach writing a nice coloring algorithm.  then i found this and thought to myself, jackpot!  ive been looking through the forum posts about your coloring method, and i was wondering if there is a general discussion that really explains it, maybe a pseudocode style description or something?  maybe its obvious if you are a math professor, which i am not, or a fractal genius, which i am not  grin  i'll look at the ultrafractal script and see if i can extrapolate from it though i dont use ultrafractal nor am i familiar with its scripting.
Logged
Pauldelbrot
Fractal Senior
******
Posts: 2590



pderbyshire2
« Reply #28 on: September 17, 2014, 07:03:28 PM »

Thanks. The ucl is perhaps less than perfect as a learning guide -- there's a lot of repetition with slight variations, mostly to implement Bezier curves. I also have Clojure code for a very similar multiwave which is used by Nanoscope. I could post that if anyone is interested.
Logged

quaz0r
Fractal Molossus
**
Posts: 652



« Reply #29 on: September 17, 2014, 07:27:30 PM »

yes please  cheesy
Logged
Pages: 1 [2] 3   Go Down
  Print  
 
Jump to:  

Related Topics
Subject Started by Replies Views Last post
Coloring algorithm to allow for multi-colored Mandelbrot edge? Mandelbrot & Julia Set twinbee 3 4990 Last post March 26, 2008, 02:20:05 AM
by twinbee
Coloring points inside the Mandelbrot set Mandelbrot & Julia Set « 1 2 » kronikel 17 3797 Last post March 30, 2017, 10:29:20 PM
by therror
Mandelbrot Smooth coloring Zoom!!! Movies Showcase (Rate My Movie) SeryZone 4 949 Last post April 26, 2014, 10:43:33 PM
by SeryZone
Basic Mandelbrot question: out-coloring modes General Discussion tobiles 2 855 Last post October 30, 2014, 07:44:31 PM
by SeryZone

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.196 seconds with 29 queries. (Pretty URLs adds 0.017s, 2q)