spire

math

package math

Linear Supertypes
AnyRef, Any
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. math
  2. AnyRef
  3. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Type Members

  1. case class Above[A] extends Interval[A] with Product with Serializable

  2. final class Algebraic extends ScalaNumber with ScalaNumericConversions with Serializable

    Algebraic provides an exact number type for algebraic numbers.

  3. class AlgebraicAlgebra extends AlgebraicIsField with AlgebraicIsNRoot with AlgebraicIsReal with Serializable

    Annotations
    @SerialVersionUID( 1L )
  4. trait AlgebraicInstances extends AnyRef

  5. case class All[A] extends Interval[A] with Product with Serializable

  6. case class Below[A] extends Interval[A] with Product with Serializable

  7. abstract class BinaryMerge extends AnyRef

    Abstract class that can be used to implement custom binary merges with e.

  8. trait BitString[A] extends Bool[A]

  9. case class Bounded[A] extends Interval[A] with Product with Serializable

  10. final case class Complex[T](real: T, imag: T) extends ScalaNumber with ScalaNumericConversions with Serializable with Product

    Annotations
    @SerialVersionUID( 0L )
  11. trait ComplexInstances extends ComplexInstances1

  12. trait ComplexInstances0 extends AnyRef

  13. trait ComplexInstances1 extends ComplexInstances0

  14. trait ConvertableFrom[A] extends Any

  15. trait ConvertableTo[A] extends Any

  16. case class Empty[A] extends Interval[A] with Product with Serializable

  17. final class FloatComplex extends AnyVal

    Value class which encodes two floating point values in a Long.

  18. final class FpFilter[A] extends AnyRef

    A Floating-point Filter [1] provides a Numeric type that wraps another Numeric type, but defers its computation, instead providing a floating point (Double) approximation.

  19. final class FpFilterApprox[A] extends AnyVal

  20. final class FpFilterExact[A] extends AnyVal

  21. trait Fractional[A] extends Field[A] with NRoot[A] with Integral[A]

  22. trait HighBranchingMedianOf5 extends AnyRef

  23. trait Integral[A] extends EuclideanRing[A] with ConvertableFrom[A] with ConvertableTo[A] with IsReal[A]

  24. class IntegralOps[A] extends AnyRef

  25. sealed abstract class Interval[A] extends Serializable

    Interval represents a set of values, usually numbers.

  26. final case class Jet[T](real: T, infinitesimal: Array[T]) extends ScalaNumber with ScalaNumericConversions with Serializable with Product

    Annotations
    @SerialVersionUID( 0L )
  27. case class JetDim(dimension: Int) extends Product with Serializable

    Used to implicitly define the dimensionality of the Jet space.

  28. trait JetInstances extends AnyRef

  29. trait Merge extends Any

    Interface for a merging strategy object.

  30. trait MutatingMedianOf5 extends AnyRef

  31. sealed abstract class Natural extends ScalaNumber with ScalaNumericConversions with Serializable

    Annotations
    @SerialVersionUID( 0L )
  32. class NaturalAlgebra extends NaturalIsRig with NaturalOrder with Serializable

    Annotations
    @SerialVersionUID( 0L )
  33. trait NaturalInstances extends AnyRef

  34. sealed trait Number extends ScalaNumber with ScalaNumericConversions with Serializable

  35. class NumberAlgebra extends NumberIsField with NumberIsNRoot with NumberIsTrig with NumberIsReal with Serializable

    Annotations
    @SerialVersionUID( 0L )
  36. trait NumberInstances extends AnyRef

  37. trait NumberTag[A] extends AnyRef

    A NumberTag provides information about important implementations details of numbers.

  38. trait Numeric[A] extends Ring[A] with AdditiveAbGroup[A] with MultiplicativeAbGroup[A] with NRoot[A] with ConvertableFrom[A] with ConvertableTo[A] with IsReal[A]

    TODO 3.

  39. case class Point[A] extends Interval[A] with Product with Serializable

  40. trait Polynomial[C] extends AnyRef

  41. trait PolynomialEq[C] extends Eq[Polynomial[C]]

  42. trait PolynomialInstances extends PolynomialInstances3

  43. trait PolynomialInstances0 extends AnyRef

  44. trait PolynomialInstances1 extends PolynomialInstances0

  45. trait PolynomialInstances2 extends PolynomialInstances1

  46. trait PolynomialInstances3 extends PolynomialInstances2

  47. trait PolynomialOverField[C] extends PolynomialOverRing[C] with EuclideanRing[Polynomial[C]] with VectorSpace[Polynomial[C], C]

  48. trait PolynomialOverRig[C] extends PolynomialOverSemiring[C] with Rig[Polynomial[C]]

  49. trait PolynomialOverRing[C] extends PolynomialOverRng[C] with Ring[Polynomial[C]]

  50. trait PolynomialOverRng[C] extends PolynomialOverSemiring[C] with RingAlgebra[Polynomial[C], C]

  51. trait PolynomialOverSemiring[C] extends Semiring[Polynomial[C]]

  52. final case class Quaternion[A](r: A, i: A, j: A, k: A) extends ScalaNumber with ScalaNumericConversions with Serializable with Product

  53. trait QuaternionInstances extends QuaternionInstances1

  54. trait QuaternionInstances1 extends AnyRef

  55. sealed abstract class Rational extends ScalaNumber with ScalaNumericConversions with Ordered[Rational]

  56. class RationalAlgebra extends RationalIsField with RationalIsReal with Serializable

    Annotations
    @SerialVersionUID( 1L )
  57. trait RationalInstances extends AnyRef

  58. sealed trait Real extends ScalaNumber with ScalaNumericConversions

  59. class RealAlgebra extends RealIsFractional

    Annotations
    @SerialVersionUID( 0L )
  60. trait RealInstances extends AnyRef

  61. trait RealIsFractional extends Fractional[Real] with Order[Real] with Signed[Real] with Trig[Real]

  62. sealed abstract class SafeLong extends ScalaNumber with ScalaNumericConversions with Ordered[SafeLong]

    Provides a type to do safe long arithmetic.

  63. trait SafeLongInstances extends AnyRef

  64. trait Select extends Any

  65. trait SelectLike extends Select

    Given a function for finding approximate medians, this will create an exact median finder.

  66. trait Sort extends Any

    Interface for a sorting strategy object.

  67. final class Trilean extends AnyVal

    Implementation of three-valued logic.

  68. class TrileanAlgebra extends Heyting[Trilean]

  69. final class UByte extends AnyVal with ScalaNumericAnyConversions

  70. trait UByteInstances extends AnyRef

  71. final class UInt extends AnyVal

  72. trait UIntInstances extends AnyRef

  73. final class ULong extends AnyVal

  74. trait ULongInstances extends AnyRef

  75. final class UShort extends AnyVal

  76. trait UShortInstances extends AnyRef

Value Members

  1. object Algebraic extends AlgebraicInstances with Serializable

  2. object BinaryMerge extends Merge

    Merge that uses binary search to reduce the number of comparisons

  3. object BitString extends Serializable

  4. object Complex extends ComplexInstances with Serializable

  5. object ConvertableFrom

  6. object ConvertableTo

  7. object FastComplex

    FastComplex is an ugly, beautiful hack.

  8. object FloatComplex

  9. object FpFilter

  10. object FpFilterApprox

  11. object FpFilterExact

  12. object Fractional extends Serializable

  13. final def IEEEremainder(x: Double, d: Double): Double

  14. object InsertionSort extends Sort

    Simple implementation of insertion sort.

  15. object Integral extends Serializable

  16. object Interval extends Serializable

  17. object Jet extends JetInstances with Serializable

    A simple implementation of N-dimensional dual numbers, for automatically computing exact derivatives of functions.

  18. object LinearMerge extends Merge

    Simple linear merge

  19. object LinearSelect extends SelectLike with HighBranchingMedianOf5

  20. object MergeSort extends Sort

    In-place merge sort implementation.

  21. object Natural extends NaturalInstances with Serializable

  22. object Number extends NumberInstances with Serializable

    Convenient apply and implicits for Numbers

  23. object NumberTag

  24. object Numeric extends Serializable

  25. object Polynomial extends PolynomialInstances

    Polynomial A univariate polynomial class and EuclideanRing extension trait for arithmetic operations.

  26. object Quaternion extends QuaternionInstances with Serializable

  27. object QuickSelect extends SelectLike with HighBranchingMedianOf5

  28. object QuickSort

    In-place quicksort implementation.

  29. object Rational extends RationalInstances with Serializable

  30. object Real extends RealInstances with Serializable

  31. object SafeLong extends SafeLongInstances with Serializable

  32. object Searching

  33. object Selection

  34. object Sorting

    Object providing in-place sorting capability for arrays.

  35. object Trilean

  36. object UByte extends UByteInstances

  37. object UInt extends UIntInstances

  38. object ULong extends ULongInstances

  39. object UShort extends UShortInstances

  40. final def abs[A](a: A)(implicit ev: Signed[A]): A

  41. final def abs(n: Double): Double

  42. final def abs(n: Float): Float

  43. final def abs(n: Long): Long

  44. final def abs(n: Int): Int

  45. final def abs(n: Short): Short

  46. final def abs(n: Byte): Byte

    abs

  47. final def acos[A](a: A)(implicit ev: Trig[A]): A

  48. final def asin[A](a: A)(implicit ev: Trig[A]): A

  49. final def atan[A](a: A)(implicit ev: Trig[A]): A

  50. final def atan2[A](y: A, x: A)(implicit ev: Trig[A]): A

  51. final def cbrt(x: Double): Double

  52. final def ceil[A](a: A)(implicit ev: IsReal[A]): A

  53. final def ceil(n: BigDecimal): BigDecimal

  54. final def ceil(n: Double): Double

  55. final def ceil(n: Float): Float

    ceil

  56. def choose(n: Long, k: Long): BigInt

    choose (binomial coefficient)

  57. final def copySign(m: Float, s: Float): Float

  58. final def copySign(m: Double, s: Double): Double

  59. final def cos[A](a: A)(implicit ev: Trig[A]): A

  60. final def cosh(x: Double): Double

  61. final def cosh[A](x: A)(implicit ev: Trig[A]): A

  62. final def e[A](implicit ev: Trig[A]): A

  63. final def e: Double

    e

  64. final def exp[A](a: A)(implicit t: Trig[A]): A

  65. final def exp(k: BigDecimal): BigDecimal

  66. final def exp(k: Int, precision: Int): BigDecimal

  67. final def exp(n: Double): Double

    exp

  68. final def expm1(x: Double): Double

  69. def fact(n: Long): BigInt

    factorial

  70. def fib(n: Long): BigInt

    fibonacci

  71. final def floor[A](a: A)(implicit ev: IsReal[A]): A

  72. final def floor(n: BigDecimal): BigDecimal

  73. final def floor(n: Double): Double

  74. final def floor(n: Float): Float

    floor

  75. final def gcd[A](x: A, y: A, z: A, rest: A*)(implicit arg0: Eq[A], ev: GCDRing[A]): A

  76. final def gcd[A](xs: Seq[A])(implicit arg0: Eq[A], ev: GCDRing[A]): A

  77. final def gcd[A](x: A, y: A)(implicit arg0: Eq[A], ev: GCDRing[A]): A

  78. final def gcd(a: BigInt, b: BigInt): BigInt

  79. final def gcd(_x: Long, _y: Long): Long

    gcd

  80. final def getExponent(x: Float): Int

  81. final def getExponent(x: Double): Int

  82. final def hypot[A](x: A, y: A)(implicit f: Field[A], n: NRoot[A], s: Signed[A]): A

  83. package interval

  84. final def lcm[A](x: A, y: A)(implicit arg0: Eq[A], ev: GCDRing[A]): A

  85. final def lcm(a: BigInt, b: BigInt): BigInt

  86. final def lcm(x: Long, y: Long): Long

    lcm

  87. final def log[A](a: A, base: Int)(implicit f: Field[A], t: Trig[A]): A

  88. final def log[A](a: A)(implicit t: Trig[A]): A

  89. def log(n: BigDecimal, base: Int): BigDecimal

  90. final def log(n: BigDecimal): BigDecimal

  91. final def log(n: Double, base: Int): Double

  92. final def log(n: Double): Double

    log

  93. final def log10(x: Double): Double

  94. final def log1p(x: Double): Double

  95. final def max[A](x: A, y: A)(implicit ev: Order[A]): A

  96. final def max(x: Double, y: Double): Double

  97. final def max(x: Float, y: Float): Float

  98. final def max(x: Long, y: Long): Long

  99. final def max(x: Int, y: Int): Int

  100. final def max(x: Short, y: Short): Short

  101. final def max(x: Byte, y: Byte): Byte

    max

  102. final def min[A](x: A, y: A)(implicit ev: Order[A]): A

  103. final def min(x: Double, y: Double): Double

  104. final def min(x: Float, y: Float): Float

  105. final def min(x: Long, y: Long): Long

  106. final def min(x: Int, y: Int): Int

  107. final def min(x: Short, y: Short): Short

  108. final def min(x: Byte, y: Byte): Byte

    min

  109. final def nextAfter(x: Float, y: Float): Float

  110. final def nextAfter(x: Double, y: Double): Double

  111. final def nextUp(x: Float): Float

  112. final def nextUp(x: Double): Double

  113. def nroot(a: BigDecimal, k: Int, ctxt: MathContext): BigDecimal

    An implementation of the shifting n-th root algorithm for BigDecimal.

    An implementation of the shifting n-th root algorithm for BigDecimal. For the BigDecimal a, this is guaranteed to be accurate up to the precision specified in ctxt.

    See http://en.wikipedia.org/wiki/Shifting_nth_root_algorithm

    a

    A (positive if k % 2 == 0) BigDecimal.

    k

    A positive Int greater than 1.

    ctxt

    The MathContext to bound the precision of the result.

    returns A BigDecimal approximation to the k-th root of a.

  114. final def pi[A](implicit ev: Trig[A]): A

  115. final def pi: Double

    pi

  116. package poly

  117. final def pow(base: Double, exponent: Double): Double

  118. final def pow(base: Long, exponent: Long): Long

    Exponentiation function, e.

    Exponentiation function, e.g. x^y

    If base^ex doesn't fit in a Long, the result will overflow (unlike Math.pow which will return +/- Infinity).

  119. final def pow(base: BigInt, ex: BigInt): BigInt

  120. final def pow(base: BigDecimal, exponent: BigDecimal): BigDecimal

    pow

  121. package prime

    Basic tools for prime factorization.

  122. final def random(): Double

  123. final def rint(x: Double): Double

  124. final def round[A](a: A)(implicit ev: IsReal[A]): A

  125. final def round(a: BigDecimal): BigDecimal

  126. final def round(a: Double): Double

  127. final def round(a: Float): Float

    round

  128. final def scalb(d: Float, s: Int): Float

  129. final def scalb(d: Double, s: Int): Double

  130. final def signum[A](a: A)(implicit ev: Signed[A]): Int

  131. final def signum(x: Float): Float

  132. final def signum(x: Double): Double

    signum

  133. final def sin[A](a: A)(implicit ev: Trig[A]): A

  134. final def sinh[A](x: A)(implicit ev: Trig[A]): A

  135. final def sqrt[A](a: A)(implicit ev: NRoot[A]): A

  136. final def sqrt(x: Double): Double

    sqrt

  137. final def tan[A](a: A)(implicit ev: Trig[A]): A

  138. final def tanh[A](x: A)(implicit ev: Trig[A]): A

  139. final def toDegrees(a: Double): Double

  140. final def toRadians(a: Double): Double

  141. final def ulp(x: Float): Double

  142. final def ulp(x: Double): Double

Inherited from AnyRef

Inherited from Any

Ungrouped