Cube layer¶
All cubes live in CUBE universe.
There are two built-in cubes:
1cube is a unit cube with a single point*_12cube is a directed interval cube with points0_2and1_2
It is also possible to have CUBE variables and make products of cubes:
I * Jis a product of cubesIandJ(t, s)is a point inI * Jift : Iands : J- if
ts : I * J, thenfirst ts : Iandsecond ts : J
You can usually use (t, s) both as a pattern, and a construction of a pair of points:
-- Swap point components of a point in a cube I × I
#define swap
( I : CUBE)
: ( I × I) → I × I
:= \ ( t , s) → (s , t)