[]
        
(Showing Draft Content)

C1.Framework.Mathematics.Fraction

Fraction Struct

Represents nn expression that indicates the quotient of two quantities.

Namespace: C1.Framework.Mathematics
Assembly: C1.Win.Input.8.dll
Syntax
public struct Fraction

Constructors

Name Description
Fraction(double, double)

Initializes a new instance of Fraction structure with the specified numerator and denominator.

Properties

Name Description
Denominator

Gets or sets the denominator of the fraction.

Numerator

Gets or sets the numertor of the fraction.

Methods

Name Description
Reverse(Fraction)

Reverse the fraction.

Simplify()

Simplify the fraction.

Operators

Name Description
operator +(Fraction, Fraction)

Defines the binary "+" operator.

operator /(Fraction, Fraction)

Defines the binary "/" operator.

operator /(Fraction, double)

Defines the binary "/" operator.

operator /(double, Fraction)

Defines the binary "/" operator.

implicit operator double(Fraction)

Converts the fraction to double.

implicit operator Fraction(double)

Converts the double to fraction.

operator !(Fraction)

Defines the "!" operator. Note: "!" is used as simplify in here.

operator *(Fraction, Fraction)

Defines the binary "*" operator.

operator *(Fraction, double)

Defines the binary "*" operator.

operator *(double, Fraction)

Defines the binary "*" operator.

operator -(Fraction, Fraction)

Defines the binary "-" operator.

operator -(Fraction)

Defines the unary "-" operator.