示例#1
0
        /// <summary>
        /// Returns the mid-radius, in the induced geometry.
        /// </summary>
        public static double MidRadius(int p, int q, int r)
        {
            double pir = PiOverNSafe(r);

            double inRadius  = InRadius(p, q, r);
            double midRadius = DonHatch.sinh(inRadius) / Math.Sin(pir);

            switch (GetGeometry(p, q, r))
            {
            case Geometry.Hyperbolic:
                return(DonHatch.asinh(midRadius));

            case Geometry.Spherical:
                return(Math.Asin(midRadius));
            }

            throw new System.NotImplementedException();
        }