| http://people.csail.mit.edu/jaffer/Marbling/Mathematics |
The Mathematics of Marbling |
The essential feature I am trying to produce is that when a tine moves
through regions of different color paints, it stretches the boundaries
between the paints to bend around it. If a blue paint region is
surrounded by a red paint region, in the deformation induced by the
movement of the tine through it, the blue region is still surrounded
by the red region.
A mapping taking each point in the plane to its destination after the tine has moved through the area will be represented by a vector-valued function F from a plane (ℝ×ℝ) to a plane. Further, F will be a homeomorphism, a continuous bijection.
The functional composition of homeomorphisms is also a homeomorphism. So if we have a homeomorphism for a single stroke, we can compose the functions representing each movement together to create a more complicated homeomorphism where F1 will be the first stroke and Fn will be the last stroke of the sequence:
| F = Fn ∘ Fn−1 ∘ … ∘ F1 |
Paint boundary curves which are continuous in the plane are mapped to continuous curves by homeomorphisms, no matter how much they fold and stretch. In order for homeomorphisms to remain reversible, we set a maximum displacement z for the deformation each tine introduces.
| ∂Hy
∂y |
= 0 |
Hy(x) is even; the displacements to either side of x=0 will be equal and in the same direction. So we will consider Hy(x) for x≥0 only. Because the flow is laminar, displacements induced by z travel along the x axis should be proportional to z. Let w=Hy(a). Then Hy(2a) will be reduced from w by the same proportion as w was reduced from z.
| Hy(2a) | = | w2 z | ; thus | Hy(2a) Hy(0) | = | w2 z2 | = | Hy(a)2 Hy(0)2 |
A key property of this marbling transform is that the displacement parallel to the line is dependent only on the perpendicular distance from the line. Because of this, the inverse transform is simply the forward transform with its displacement negated. We will use this property later on.
It is remarkable that an exact, closed-form expression is derived for
the asymptotic equilibrium of a fluid-dynamics problem using little
more than boundary conditions and symmetry.
Most of the marbling images are linked to PostScript files (with a".ps"suffix). PostScript is a programming language; but these files use a very limited subset. There are links to language reference manuals and tutorials at the bottom of http://en.wikipedia.org/wiki/PostScript#The_language.You can run PostScript programs and view the images they generate using GSview, available from http://pages.cs.wisc.edu/~ghost/gsview.
The boundaries between virtual paint rings will be traversed using the Minsky circle algorithm; although walking the circles using coordinates generated by sin and cos would work as well. The angular step size is made inversely proportional to the ring radius, making the distance between successive points uniform.
[These images are linked to the
PostScript files which generated them.]
| Fv(x, y) = | ( | x, y + z·u|x−xL| | ) |
The transform for straight, horizontal strokes is to displace each point horizontally by an amount exponentially decreasing with vertical distance from the tine's y-coordinate yL:
| Fh(x, y) = | ( | z · u |y−yL| + x, y | ) |
After verifying that a combing and its reverse (eg. North and South)
cancel each other, the next combing sequence to try is a
commutator.
Where operators do not commute, composing operators and their inverses
in an asymmetrical sequence often reveals essential properties of
their mathematical interactions.
The image to the right is the result of straight combings (7 tines) in the North, East, South, then West directions.
[These images are linked to the PostScript files which generated them.]
The image to the left was combed North, East, South, then East.
Although the depth of combing was the same as the previous picture,
its character is somewhat different.
| d = | (P−B) · N | |
| FL(P) = P + z · ud · M |
Circular tine tracks are also compatible with laminar incompressible
flow. In this case points are displaced along arcs around a center
point
C.
Because the displacements tend to zero far from the center, outside of the tine track the exponentially decreasing magnitude of the displacements again applies. Inside of the tine track, however, asymptotic considerations don't apply. This finite area could, for instance, rotate as a rigid disk. Using the same formula on the inside as the outside lets circular tine tracks with very large radii behave similarly to straight tine tracks.
| d = | ||P−C||−r | |
| l = z · ud | a = | l
||P−C|| |
| FC(P) = C + (P−C) · | ( | cos a −sin a | sin a cos a | ) |
The figure to the left shows the paths of the virtual tines moving
through the field of view. Those clockwise circular motions result in
the marbling shown to the right.
Arcs of increasing radius whose centers track away from the field of
view create a fan like that at the top of this article.
| l(h,z,u,r) = z·uh−r |
| l(h,z,u,r) = z·uh−r = (z·u−r)uh = l(h,z·u−r,u,0) |
| h = ||P−C|| | l = (z·u−r) · uh | a = | l
h |
| FV(P) = C + (P−C) · | ( | cos a −sin a | sin a cos a | ) |
The next chapter deals with tine tracks with
other than straight or circular trajectories.
|
I am a guest and not a member of the MIT Computer Science and Artificial Intelligence Laboratory.
My actions and comments do not reflect in any way on MIT. | ||
| Topological Computer Graphics | ||
| agj @ alum.mit.edu | Go Figure! | |