Rule for MapSection
<MapKeyword>[:]\n
(<Map> \n)*
[<End>]
Rule for MapKeyword
(MAPS[_SECTION] | MAP_SECTION | Maps)
Rule for Map
<Expression> ((⎵\t)(⎵\t)* <Expression>)^{n-1}
Note that there must be exactly
n
expression separated by horizontal whitespace, where n
is the number of columns.
Rule for Expression
[+|-]<Term>((+|-)<Term>)*
Note that within a term there is no whitespace.
Rule for Term
(<Integer> | <Integer><Name> | <Name>)
Note that each name must match one of the names defined in the
NameSection
.
Note that in a term, each name may occur at most once.
Rule for Integer
(1-9)[(0-9)]*
Rule for Name
(a-z|A-Z)(a-z|A-Z|0-9|_|^)*
Examples
Names:
X Y Z
Maps:
Y X Z
X-Y Z Y
+2X-3Z-Y 1 -Z
May be used in
Legend
[X]: X
is optional.(X|Y|Z):
One of X, Y
or Z
is present.(A-E):
Any ASCII symbol between symbol A
and E
.X*:
X may occur any number of times (including zero).