Reassigning Regional Parameter Values

<< Click to Display Table of Contents >>

Navigation:  Problem Descriptor Reference > The Sections of a Descriptor > Boundaries > Regions >

Reassigning Regional Parameter Values

Previous pageReturn to chapter overviewNext page

Names previously defined in the DEFINITIONS section can be assigned a new value within a REGION by adding one or more assignments of the form

name = new_expression

 

immediately following the reserved word REGION.  

When definitions are reassigned new values in this manner, the new value applies only to the region in which the reassignment occurs.

 

Example:

DEFINITIONS

K = 1        { the default value }

REGION 1        { assumes default, since no override is given }

START(0,0) LINE TO (10,0) TO (10,10) TO (0,10) TO CLOSE

REGION 2

K = 2        { both sub-boxes are assigned K=2 }

START(1,1) LINE TO (2,1) TO (2,2) TO (1,2) TO CLOSE

START(5,5) LINE TO (6,5) TO (6,6) TO (5,6) TO CLOSE

REGION 3        { again assumes the default }

START(3,3) LINE TO (4,3) TO (4,4) TO (3,4) TO CLOSE

 

See also MATERIALS section.