Added some functions to caclulate SUM table
Small ring, Big Ring, Oval, and Next_j implemented.  Now to string them together with the grammar to generate the trajectories.