The Mathematica Journal
Departments
Download This Issue
Home
Feature Articles
Graphics Gallery
Tricks of the Trade
In and Out
Columns
The Mathematica Programmer
New Products
New Publications
Classifieds
Calendar
News Bulletins
Editor's Pick
Mailbox
Letters
Write Us
About the Journal
Staff and Contributors
Submissions
Subscriptions
Advertising
Back Issues

The Aqueduct

A stationary aqueduct "guides" the river. The aqueduct is formed by placing  "bricks" on both sides of the river. The bricks are built by extending the function which forms the river by one polygon width on each side of the river and then replacing the polygons with bricks having the same footprint as the original polygon.

The height (hb) and width (wb) of the bricks are set as follows.

[Graphics:../Images/index_gr_47.gif]
[Graphics:../Images/index_gr_48.gif]

Most of the polygons in the animation are owned by the aqueduct. To reduce memory loading and execution time, we will reduce the number of polygons in the straight portions of the aqueduct by increasing the length of the bricks. A second benefit, that of variable resolution, will be discussed later.

The function plist creates a partial list of the plot points in the [Graphics:../Images/index_gr_49.gif] direction. In this function, p1 and p2 are the endpoints of the partial segments and np is the number of polygons in the segment.

[Graphics:../Images/index_gr_50.gif]

A partial list is created for each portion of rpath and all the lists are joined together.

[Graphics:../Images/index_gr_51.gif]
[Graphics:../Images/index_gr_52.gif]

[Graphics:../Images/index_gr_53.gif]

In this plot, the portions with the steeper slope represent a lower resolution. For comparison, a straight line would give a constant resolution.

A row of polygons is created at each point in biasp on the inner and outer diameters of the river by ListSurfacePlot3D (from Graphics`Graphics3D`).

[Graphics:../Images/index_gr_54.gif]
[Graphics:../Images/index_gr_55.gif]
[Graphics:../Images/index_gr_56.gif]

Here is a close up of the helical portion of the plot.

[Graphics:../Images/index_gr_57.gif]

[Graphics:../Images/index_gr_58.gif]

Steps are more effective at providing the impression of a change in height so we will replace each polygon with a brick. This task is performed by a replacement rule which I have called mason.

[Graphics:../Images/index_gr_59.gif]
[Graphics:../Images/index_gr_60.gif]

[Graphics:../Images/index_gr_61.gif]

The function editcolor inserts a color directive into a Graphics3D object. The colors for the graphics objects come from the standard package Graphics`Colors`.

[Graphics:../Images/index_gr_62.gif]
[Graphics:../Images/index_gr_63.gif]

The function aqueduct combines the rows of bricks and provides a color of Firebrick.

[Graphics:../Images/index_gr_64.gif]

Here is a plot of the graphics elements we have defined to this point.

[Graphics:../Images/index_gr_65.gif]

[Graphics:../Images/index_gr_66.gif]

This plot shows the second benefit of having a variable resolution in the aqueduct. With the long bricks in the straight sections (which have a gentle slope), the steps provide a visual cue of a change of altitude. If the aqueduct had the same resolution as the river, these steps would not be visible. It is important to the illusion for these cues to be present in this area because while the aqueduct is moving down in the [Graphics:../Images/index_gr_67.gif] reference frame, it is moving up (from the bottom of the waterfall to the top of the helix, for example) in the image plane. The steps encourage our minds to maintain the illusion further along the path.


Converted by Mathematica      September 24, 1999

[Prev Page][Next Page]