Property | Type | Description | |
---|---|---|---|
Denominator | long | ||
Numerator | long |
Method | Description | |
---|---|---|
FromDouble ( double x ) : |
Use a sequence of continued fractions to find a good rational approximation to the double precition provided number http://jonisalonen.com/2012/converting-decimal-numbers-to-ratios/ |
|
FromIntegers ( long num, long den ) : |
||
Rational ( long num, long den ) : System | ||
Reciprocal ( ) : |
||
ToDouble ( ) : double | ||
ToString ( ) : string | ||
operator ( ) : |
Method | Description | |
---|---|---|
gcd ( long a, long b ) : long |
public static FromDouble ( double x ) : |
||
x | double | |
return |
public static FromIntegers ( long num, long den ) : |
||
num | long | |
den | long | |
return |
public Rational ( long num, long den ) : System | ||
num | long | |
den | long | |
return | System |