Domain coloring

Short description: Technique for visualizing complex functions

A domain coloring graph of the function ⁠(z2 − 1)(z − 2 − i)2/z2 \+ 2 + 2i⁠. Darker spots mark moduli near zero, brighter spots are farther away from the origin. The color encodes the argument. The function has zeros for ±1, (2 + i) and poles at ±−2−2i.

In complex analysis, domain coloring or a color wheel graph is a technique for visualizing complex functions by assigning a color to each point of the complex plane. By assigning points on the complex plane to different colors and brightness, domain coloring allows for a function from the complex plane to itself, whose graph would normally require four spatial dimensions, to be easily represented and understood. This provides insight to the fluidity of complex functions and shows natural geometric extensions of real functions.

## Contents

* 1 Motivation
* 2 History
* 3 Method
* 3.1 Simple color function
* 3.2 Discontinuous color changing
* 3.2.1 Magnitude growth
* 3.2.2 Highlighting properties
* 4 Limitations
* 5 References
* 6 External links

## Motivation

A graph of a real function can be drawn in two dimensions because there are two represented variables, x and y. However, complex numbers are represented by two variables and therefore two dimensions; this means that representing a complex function (more precisely, a complex-valued function of one complex variable f:ℂ->ℂ) requires the visualization of four dimensions. One way to achieve that is with a Riemann surface, but another method is by domain coloring.

## History

The term "domain coloring" was coined by Frank Farris, possibly around 1998.[1][2] There were many earlier uses of color to visualize complex functions, typically mapping argument (phase) to hue.[3] Larry Crone used the method in the late 1980s.[4] Dan Kucerovsky used it in 1990.[5] The technique of using continuous color to map points from domain to codomain or image plane was used in 1999 by George Abdo and Paul Godfrey[6] and colored grids were used in graphics by Doug Arnold that he dates to 1997.[7]

## Method

HL plot of z, as per the simple color function example described in the text (left), and the graph of the complex function z3 − 1 (right) using the same color function, showing the three zeros as well as the negative real numbers as pink rays starting at the zeros.

Representing a four dimensional complex mapping with only two variables is undesirable, as methods like projections can result in a loss of information. However, it is possible to add variables that keep the four-dimensional process without requiring a visualization of four dimensions. In this case, the two added variables are visual inputs such as color and brightness because they are naturally two variables easily processed and distinguished by the human eye. This assignment is called a "color function". There are many different color functions used. A common practice is to represent the complex argument, arg⁡z, (also known as "phase" or "angle") with a hue following the color wheel, and the magnitude by other means, such as brightness or saturation.

### Simple color function

The following example colors the origin in black, 1 in green, −1 in magenta, and a point at infinity in white: {H=arg⁡z+2π/3,S=100%,L=ℓ(|z|). Where H is hue, S is saturation, and L is lightness. There are a number of choices for the function ℓ:[0,∞)->[0,1). ℓ should be strictly monotonic and continuous. Another desirable property is ℓ(1/r)=1−ℓ(r) such that the inverse of a function is exactly as light as the original function is dark (and the other way around). Possible choices include

* ℓ1(r)=2πarctan⁡(r) and
* ℓ2(r)=rara+1 (with some parameter a>0). With a=2, this corresponds to the stereographic projection onto the Riemann sphere.

A widespread choice which does not have this property is the function ℓ3(r)=1−a|r| (with some parameter 0<a<1) which for a=1/2 and 0≤r≤1 is very close to ℓ1.

This approach uses the HSL (hue, saturation, lightness) color model. Saturation is always set at the maximum of 100%. Vivid colors of the rainbow are rotating in a continuous way on the complex unit circle, so the sixth roots of unity (starting with 1) are: green, cyan, blue, magenta, red, and yellow.

Since the HSL color space is not perceptually uniform, one can see streaks of perceived brightness at yellow, cyan, and magenta (even though their absolute values are the same as red, green, and blue) and a halo around L = ⁠1/2⁠. More modern color spaces, e.g, the Lab color space or CIECAM02, correct this, making the images more accurate and less saturated.

### Discontinuous color changing

Many color graphs have discontinuities, where instead of evenly changing brightness and color, it suddenly changes, even when the function itself is still smooth. This is done for a variety of reasons such as showing more detail or highlighting certain aspects of a function, like level sets.

#### Magnitude growth

A discontinuous color function. In the graph, each discontinuity occurs when |z|=2n for integers n.

Unlike the argument, which has finite range, the magnitude of a complex number can range from 0 to ∞. Therefore, in functions that have large ranges of magnitude, changes in magnitude can sometimes be hard to differentiate when a very large change is also pictured in the graph. This can be remedied with a discontinuous color function which shows a repeating brightness pattern for the magnitude based on a given equation. This allows smaller changes to be easily seen as well as larger changes that "discontinuously jump" to a higher magnitude. In the graph on the right, these discontinuities occur in circles around the center, and show a dimming of the graph that can then start becoming brighter again. A similar color function has been used for the graph on top of the article.

Equations that determine the discontinuities may be linear, such as for every integer magnitude, exponential equations such as every magnitude 2n where n is an integer, or any other equation.

#### Highlighting properties

Discontinuities may be placed where outputs have a certain property to highlight which parts of the graph have that property. For instance, a graph may, instead of showing the color cyan, jump from green to blue. This causes a discontinuity that is easy to spot, and can highlight lines such as where the argument is zero.[8] Discontinuities may also affect large portions of a graph, such as a graph where the color wheel divides the graph into quadrants. In this way, it is easy to show where each quadrant ends up with relations to others.[9]

## Limitations

People who experience color blindness may have trouble interpreting such graphs when they are made with standard color maps.[10][11] This issue can be partially fixed by creating alternate versions using color maps that fit within the color space discernible to those with color blindness.[12] For example, for use by those with total deuteranopia, a color map based on blue/grey/yellow may be more readable than the conventional map based on blue/green/red.[12]

## References

1. ↑ Frank A. Farris, Visualizing complex-valued functions in the plane
2. ↑ Hans Lundmark (2004). "Visualizing complex analytic functions using domain coloring". Archived from the original on 2006-05-02. https://web.archive.org/web/20060502154939/http://www.mai.liu.se/~halun/complex/domain_coloring-unicode.html. Retrieved 2006-05-25. Lundmark refers to Farris' coining the term "domain coloring" in this 2004 article.
3. ↑ David A. Rabenhorst (1990). "A Color Gallery of Complex Functions". Pixel: The Magazine of Scientific Visualization (Pixel Communications) 1 (4): 42 et seq. https://books.google.com/books?id=DRUSAQAAMAAJ&q="phase"+"hue"+complex-functions.
4. ↑ Elias Wegert (2012). Visual Complex Functions: An Introduction with Phase Portraits. Springer Basel. p. 29. ISBN 9783034801799. https://www.springer.com/us/book/9783034801799. Retrieved 6 January 2016.
5. ↑ Kucerovsky, Dan (October 1990). "An algorithm for the visual representation of a two-dimensional vector field". Conference Record of the 1990 IEEE Industry Applications Society Annual Meeting. pp. 903–909. doi:10.1109/IAS.1990.152292. ISBN 0-87942-553-9.
6. ↑ George Abdo & Paul Godfrey (1999). "Plotting functions of a complex variable: Table of Conformal Mappings Using Continuous Coloring". http://my.fit.edu/~gabdo/. Retrieved 2008-05-17.
7. ↑ Douglas N. Arnold (2008). "Graphics for complex analysis". http://www.ima.umn.edu/~arnold/complex.html. Retrieved 2008-05-17.
8. ↑ May 2004. http://users.mai.liu.se/hanlu09/complex/domain_coloring.html Retrieved 13 December 2018.
9. ↑ Poelke, K.; Polthier, K. (September 2012). "Domain Coloring of Complex Functions: An Implementation-Oriented Introduction". IEEE Computer Graphics and Applications 32 (5): 90–97. doi:10.1109/MCG.2012.100. PMID 24806991.
10. ↑ "CET Perceptually Uniform Colour Maps". https://peterkovesi.com/projects/colourmaps/.
11. ↑ Farris, Frank A. (2 June 2015). Creating Symmetry: The Artful Mathematics of Wallpaper Patterns. Princeton University Press. pp. 36–37. ISBN 978-0-691-16173-0. https://books.google.com/books?id=blGUBgAAQBAJ&q="domain+coloring"+color+blindness&pg=PA36.
12. ↑ 12.0 12.1 Kovesi, Peter (2017). "Colour Maps for the Colour Blind, presented at IAMG 2017". https://peterkovesi.com/papers/ColourMapsForColourBlindIAMG2017.pdf.

## External links

* Samuel Li's function plotter
* High-quality, browser-based interactive complex function plotter by Ricky Reusseur
* Color Graphs of Complex Functions
* Visualizing complex-valued functions in the plane.
* Gallery of Complex Functions
* Complex Mapper by Alessandro Rosa
* John Davis software, S-Lang script for domain coloring
* Open source C and Python domain coloring software
* Enhanced 3D Domain coloring
* Domain Coloring Method on GPU
* Java domain coloring software (In development)
* MATLAB routines [1]
* Python script for GIMP by Michael J. Gruber
* Matplotlib and MayaVi implementation of domain coloring by E. Petrisor [2]
* MATLAB routines with user interface and various color schemes
* MATLAB routines for 3D-visualization of complex functions
* Color wheel method
* Real-Time Zooming Math Engine
* Fractal Zoomer : Software that utilizes domain coloring
* cplot, a domain-coloring package for Python

0.00

(0 votes)

Original source: https://en.wikipedia.org/wiki/Domain coloring. Read more

|

Retrieved from "https://handwiki.org/wiki/index.php?title=Domain_coloring&oldid=4298865"