public Point3[] CircleCoordinates(float y)
 {
     Point3[] pts = new Point3[30];
     Matrix3 m = new Matrix3 ();
     for (int i = 0; i < pts.Length; i++) {
         pts [i] = m.Cylindrical (r, i * 360 / (pts.Length - 1), y);
     }
     return pts;
 }
 public Point3 Cylindrical(float r, float theta, float y)
 {
     Point3 pt = new Point3 ();
     float sn = (float)Math.Sin (theta * Math.PI / 180);
     float cn = (float)Math.Cos (theta * Math.PI / 180);
     pt.X = r * cn;
     pt.Y = y;
     pt.Z = -r * sn;
     pt.W = 1;
     return pt;
 }