示例#1
0
 public static BigFraction ToBigFraction(this BigInteger number) => BigFraction.New(number, 1);
示例#2
0
        public static BigFraction Reduce(this BigFraction fraction)
        {
            var gcd = Algebra.Gcd(fraction.Numerator, fraction.Denominator);

            return(new BigFraction(fraction.Numerator / gcd, fraction.Denominator / gcd));
        }
示例#3
0
 // BigFractions....
 public static BigFraction Invert(this BigFraction fraction) => BigFraction.New(fraction.Denominator, fraction.Numerator);