- Preparing search index...
- The search index is not available
vexflow
Constructors
constructor
- new Fraction(numerator?, denominator?): Fraction
-
Parameters
-
Optional
numerator: number
-
Optional
denominator: number
Properties
denominator
denominator: number = 1
numerator
numerator: number = 1
Accessors
Static
CATEGORY
- get CATEGORY(): string
-
Returns string
Methods
add
- add(param1?, param2?): Fraction
-
Parameters
-
param1: number | Fraction = 0
-
param2: number = 1
divide
- divide(param1?, param2?): Fraction
-
Parameters
-
param1: number | Fraction = 1
-
param2: number = 1
equals
- equals(compare): boolean
-
Returns boolean
greaterThan
- greaterThan(compare): boolean
-
Returns boolean
greaterThanEquals
- greaterThanEquals(compare): boolean
-
Returns boolean
lessThan
- lessThan(compare): boolean
-
Returns boolean
lessThanEquals
- lessThanEquals(compare): boolean
-
Returns boolean
multiply
- multiply(param1?, param2?): Fraction
-
Parameters
-
param1: number | Fraction = 1
-
param2: number = 1
quotient
- quotient(): number
-
Returns number
remainder
- remainder(): number
-
Returns number
set
- set(numerator?, denominator?): Fraction
-
Parameters
-
numerator: number = 1
-
denominator: number = 1
subtract
- subtract(param1?, param2?): Fraction
-
Parameters
-
param1: number | Fraction = 0
-
param2: number = 1
toMixedString
- toMixedString(): string
-
Returns string
toSimplifiedString
- toSimplifiedString(): string
-
Returns string
toString
- toString(): string
-
Returns string
value
- value(): number
-
Returns number
Static
GCD
- GCD(a, b): number
-
Returns number
Static
LCM
- LCM(a, b): number
-
Returns number
Static
LCMM
- LCMM(args): number
-
Returns number
Fraction represents a rational number.