IFS fractals as they are normally called can be of any number of dimensions, but are commonly computed and drawn in 2D. The fractal is made up of the union of several copies of itself, each copy being transformed by a function (hence "function system"). The canonical example is the Sierpinski gasket. The functions are normally contractive which means they bring points closer together and make shapes smaller. Hence the shape of an IFS fractal is made up of several possibly-overlapping smaller copies of itself, each of which is also made up of copies of itself, ad infinitum. This is the source of its self-similar fractal nature.
The collection of functions together with composition form a monoid. If there are only two such functions, the monoid can be visualized as a binary tree, where, at each node of the tree, one may compose with the one or the other function (i.e take the left or the right branch). In general, if there are k functions, then one may visualize the monoid as a full k-ary tree, also known as a Cayley tree.
Sometimes each function is required to be a linear, or more generally an affine transformation and hence represented by a matrix. However, IFSs may also be built from non-linear functions, including projective transformations and Möbius transformations. The Fractal flame is an example of an IFS with nonlinear functions.
The most common algorithm to compute IFS fractals is called the chaos game. It consists of picking a random point in the plane, then iteratively applying one of the functions chosen at random from the function system and drawing the point. An alternative algorithm is to generate each possible sequence of functions up to a given maximum length, and then to plot the results of applying each of these sequences of functions to an initial point or shape.
Each of these algorithms provides a global construction which generates points distributed across the whole fractal. If a small area of the fractal is being drawn, many of these points will fall outside of the screen boundaries. This makes zooming into an IFS construction normally impractical.
Although the theory of IFS requires each function to be contractive, in practice software that implements IFS only require that the whole system be contractive on average.
Here is an example of a fern-like image (Barnsley's fern) computed using an iterated function system.
The first point drawn is at the origin (x0 = 0, y0 = 0) and then the new points are iteratively computed by randomly applying one of the following four coordinate transformations:
This coordinate transformation is chosen 1% of the time and maps any point to a point in the line segment shown in green in the figure.
This coordinate transformation is chosen 7% of the time and maps any point inside the black rectangle to a point inside the red rectangle in the figure.
This coordinate transformation is chosen 7% of the time and maps any point inside the black rectangle to a point inside the dark blue rectangle in the figure.
This coordinate transformation is chosen 85% of the time and maps any point inside the black rectangle to a point inside the light blue rectangle in the figure.
The first coordinate transformation draws the stem. The second draws the bottom frond on the left. The third draws the bottom frond on the right. The fourth generates successive copies of the stem and bottom fronds to make the complete fern. The recursive nature of the IFS guarantees that the whole is a larger replica of each frond. Note: The fern is within the range -2.1818 <= x <= 2.6556 and 0 <= y <= 9.95851.
The diagram shows the construction on an IFS from two affine functions. The functions are represented by their effect on the bi-unit square (the function transforms the outlined square into the shaded square). The combination of the two functions forms the Hutchinson operator. Three iterations of the operator are shown, and then the final image is of the fixed point, the final fractal.