Add CoordinateSystem() and one test.

A few more tests are needed for CoordinateSystem() to test the if (x <
y) conditions.