gator
gator copied to clipboard
Parameterizing Schemes by Frame Dimension
Currently we require that each scheme includes a reference frame of a given dimension, such as:
with frame(3) r:
scheme cart3 : geometry {
object point is float[3];
...
}
However, this is annoying from the programmer's perspective and from the library developers perspective. The programmer has to remember which version to use with which frame, and the library developer has to write several definitions of each geometry for each definition, all of which are nearly identical.
It would be preferable to instead support schemes inferring their dimension based on the given reference frame. For example, we might have the following:
with frame(n) r:
scheme cart : geometry {
object point is float[n];
...
}
This feature requires some thought (how do we support addition in such a definition), but would be a great thing to have!