FractView manual

FractView manual

Usage

You can move, scale, rotate and shear the fractal by very intuitive gestures. Every pixel below a finger on the screen is dragged together with the finger by transforming the image. With one finger, the image is simply moved. With two fingers, the image is scaled and rotated (keeping the current aspect ratio) and with three fingers the image is sheared, which is very useful to look at Burning-Ship-alike fractals.

All fractals are stored during one run of the application. Therefore you can return to a previously generated fractal via the back button.

Here you can save the current bitmap as PNG. After selecting this menu point you see a dialog in which you can enter a filename. The file itself will be saved in the default pictures folder in a directory called FractView. An entry is added to the gallery. If there is already a file with the same name, a suffix “(n)” is added to the filename, with “n” being the smallest possible integer. A warning is shown if you try to save an image while its calculation is still running. | |

## ScaleHere you can edit the affine transformation. The right column contains the center of the image. The other four values are the rotation/scale/shear-matrix. The first column here is the vector pointing in x-direction, while the second is the vector pointing in y-direction. Straighten Pushing this button keeps the current center of the image but changes the other parameters so that the aspect ratio is set to 1:1 and the rotation is aligned along the axes. Reset Sets the scale to 4, and centers the image at (0,0). | |

## FunctionHere you can enter a formula to generate the orbits of the fractal. The current coordinate is “c”. The last value of the orbit z(n) can be accessed as “z”, the n-ith value as “zi”, i being the corresponding index. The amount of required initial z-values is automatically adjusted when confirming the input of z(n+1). Unknown words are interpreted as parameters and also automatically added. Parameters always must evaluate to a number (“sqrt 5” is accepted as input for a parameter while “2q” is not). The syntax is intuitive and straightforward. For instance, In case of syntax errors you will either get a warning or an error message. For a list of supported functions see below. ## Hints- Always think whether initial z-values are useful or not: The formula “z(n+1) = c sinh z, z(0) = 0” is always 0, while “z(n+1) = newton (z^3 + c), z(0) = 0” causes a division by 0.
- Good values for z(0) are in general values for which the derivation of the formula entered for z(n+1) is 0. For instance, if you want to look at z(n+1) = c sinh z (and you should), you should pick z(0) = i since the first derivation c cosh z is 0 for z = i.
- When using the nova or newton macro, make sure to enter a function that is derivable.
| |

Bailout and Lake Here you can pick bounds for which the current orbit is considered to be divergent (|zn| > Bailout) or convergent (|zn-1 - zn| < Epsilon). In Bailout-Settings, you can pick the colorization method for divergent orbits, while in Lake-Settings you can pick the setting for all other orbits. See below for a description of all colorization methods. Furthermore you can pick a transfer function after the method returns a value. If the value changes much when modifying small parameters (like the length when scaling), you might consider using Log as transfer. You can furthermore enter a range that should be used for scaling the result of the tranfer function. If you uncheck “Custom Range” the maximum and minimum of the image is used (it might change depending on resolution). | |

## Bailout and Lake PaletteHere you can pick a color palette. Color palettes are implemented via L*a*b color space and use cubic spline interpolation. The color picker itself uses the HSV-color model. You can select (made visible by showing its hex-representation) and modify a color by tapping on it and adjusting the levels above. “<<” moves the selected color to the left, “>>” to the right. With “+” a new color is inserted and selected, while “-” removes the current color. The colors are always distributed along the range of 0 and 1. In order to use a different distribution, use Custom Range in the Transfer-menu. | |

## ResizeSet the image size. The first text field holds the width, the second the height. | |

## IterationsSet the maximum number of iterations. For deeper zooms you might be interested in picking a higher number of iterations. A lower number will increase speed but give lower details. |

This section should give you an overview of my personal goals. Of course, good ideas are always welcome. These points are in roughly the order in which I would like to work on them

- Caching of values so that the image need not be rendered fully when adjusting some parametes [Done v 1.2b]
- Bookmarks [Done v 1.2b]
- More colorization methods (suggestions are welcome)
- Adding transfer parameter to color palette (+ ‘cycle from’ + offset) [Done v 1.2b]
- Two dimensional color palettes
- Automatically picking z(0) if z(n+1) is derivable using the Newton-Raphson-Method

- Editing parameters by dragging
- Orbit traps
- Showing orbit
- Predefined fractals

- Support for julia sets

- Split view to view julia set next to mandelbrot

- User-defined colorizations
- Sharing of bookmarks
- Implementing pendulum, IFSs, Buddhabrot etc...

Things I would not implement:

- Color cycling
- Automatic adjustment of iterations

- Focus changes when rotating with an open dialog.
- In EditText it is not possible to edit the mantissa
- On some devices the checked bookmark is not highlighted, or it is highlighted in white.

Appendix

Formulas are case-insensitive, i.e., “sin z” is equivalent to “SIN Z” or “siN Z”.

A complex number can be entered in multiple ways (e.g., 1+2i is perfectly fine), but the easiest way is real part, comma, imaginary part. The number “1 + 2i” can be entered as “1,2”. If one of these components is negative, add a “-”. “-1,2” is “-1 + 2i”, and “1,-2” is “1 - 2i”. Make sure to not accidentially add a space between the “-” and the number as it changes its meaning: “- 1,2” interprets the “-” as sign for the whole number: “-(1+2i)”. “1,- 2” issues a warning “Missing imaginary part” and returns “1 - 2”.

In order to apply an unary function, you can but need not wrap the argument in parentheses. “tan sqr z” is perfectly fine and means “tan(z2)”.

Functions with multiple arities use a syntax that is a bit LISP-alike: f(a,b,c) is denoted as f a ; b ; c, where a must not be some binary function (binary binds less).

The following list shows all implemented special parameters, binary and derivable, unary and derivable, unary and not derivable functions, and all macros (functions that are expanded to full expressions).

Description | Syntax | Comment |

z(n) | z | |

Real part of z | zr | Not derivable |

Imaginary part of z | zi | Not derivable |

Previous values of z z(n-1) z(n-2) ... | z1 z2 ... | Not derivable |

Coordinates of current pixel | c | |

Real part of c | x | |

Imaginary part of c | y | |

Current index | n | |

Addition | a1 + a2 add a1; a2 | |

Subtraction | a1 - a2 sub a1; a2 | a - b - c = (a - b) - c a - b + c = (a - b) + c |

Multiplication | a1 * a2 a1 a2 mul a1; a2 | a1 / 2a2 = a1 / (2a2) a1 / 2*a2 = a1 * a2 / 2 sin a cos a = sin(a * cos(a)) sin a*cos a = (sin a) * (cos a) |

Division | a1 / a2 div a1; a2 | a / b / c = (a / b) / c a / b * c = (a / b) * c |

Power | a1 ^ a2 pow a1; a2 | a ^ b ^ c = a ^ (b ^ c) |

Negation | - a neg a | -1,2 = (-1 + 2i) - 1,2 = -(1 + 2i) a1 -- a2 = a1 - (-a2) sin - a = sin (-a) a1 -a2 = subtraction --a is a syntax error |

Reciprocal: a-1 | rec a | |

Sum Reciprocal: a + a-1 | srec a | |

Difference Reciprocal: a - a-1 | drec a | |

Square: a2 | sqr a | |

Square root | sqrt a | |

Exponential: ea | exp a | |

Logarithm | log a | |

Sine | sin a | |

Cosine | cos a | |

Tangent | tan a | |

Arcus tangent | atan a | |

Hyperbolic sine | sinh a | |

Hyperbolic cosine | cosh a | |

Hyperbolic tangent | tanh a | |

Area hyperbolic tangent | atanh a | |

Complex Conjugate | conj a | re a - i im a |

Absolute value | abs a | |a| |

Argument | arg a | atan2(im a, re a) |

Real part | re a | |

Imaginary part | im a | |

Floor: Next lower complex integer | floor a | floor re a + i floor im a |

Component-wise absolute value | cabs a | |re a| + i |im a| |

Polar-cordinates | polar a | abs a + i arg a |

Pi | pi | π = 3.141529... |

I | i | i2 = -1 |

E | e | e = 2.7182818... |

Derivative by z | a’ diff a | a b’ = (a*b)’ a ^ b’ = a ^ (b’) |

Newton method | newton a | z - a / a’ |

Nova (generalized Newton method) | nova a;R;p | z - R * a / a’ + p |

Horner-Scheme | horner a1;a2;...an | (...((z + a1) z + a2) z ... + an |

Polynom | poly a1;a2;...;an | (z-a1) (z-a2) ... (z-an) |

Mandelbrot | mandel a | a2 + c |

- LengthSmooth*: Logarithm of the number of interations + a smoothening factor (determined by linear interpolation of the logarithm of the last bailout values).
- Length*: Number of iterations.
- SumExp: Logarithm of the sum of exp(-|zi|-1/2(|zi-1 - zi|))
- SumDelta+: Logarithm of the sum of log |zi - zi-1|
- LastArc+: Angel of last point in the orbit. Angels are normalized to range from 0 to 360.
- Zero: 0

* These colorization methods usually do not give interesting results for coloring convergent orbits.

+ These colorization methods usually do not give interesting results for coloring escaping orbits.