@lakuna/umath
    Preparing search index...

    Class BigNumber

    A number with no maximum precise size.

    Index

    Constructors

    • Create a number.

      Parameters

      • dividend: string | number | bigint | boolean = 0

        The dividend of the number.

      • divisor: string | number | bigint | boolean = 1

        The divisor of the number.

      Returns BigNumber

    Properties

    dividend: bigint

    The dividend of this fraction.

    divisor: bigint

    The divisor of this fraction.

    Methods

    • Add a number to this number.

      Parameters

      • n: string | number | bigint | boolean | BigNumber

        The other number.

      Returns this

      This number.

    • Divide this number by a number.

      Parameters

      • n: string | number | bigint | boolean | BigNumber

        The other number.

      Returns this

      This number.

    • Multiply this number by a number.

      Parameters

      • n: string | number | bigint | boolean | BigNumber

        The other number.

      Returns this

      This number.

    • Subtract a number from this number.

      Parameters

      • n: string | number | bigint | boolean | BigNumber

        The other number.

      Returns this

      This number.

    • Convert this number to a regular number. Might result in loss of precision.

      Returns number

      This number as a number.

    • Convert this number to a string.

      Returns string

      A string representation of this number.