Object

hammerlab.math

utils

Related Doc: package math

Permalink

object utils extends all

Linear Supertypes
all, Steps, Min, Interpolate, Div, HasBinomial, Serializable, Serializable, AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. utils
  2. all
  3. Steps
  4. Min
  5. Interpolate
  6. Div
  7. HasBinomial
  8. Serializable
  9. Serializable
  10. AnyRef
  11. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Type Members

  1. type RoundNumbers[I] = org.hammerlab.math.RoundNumbers[I]

    Permalink
    Definition Classes
    all

Value Members

  1. final def !=(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  4. val RoundNumbers: org.hammerlab.math.RoundNumbers.type

    Permalink
    Definition Classes
    all
  5. val Steps: org.hammerlab.math.Steps.type

    Permalink
    Definition Classes
    all
  6. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  7. object binomial

    Permalink
    Definition Classes
    HasBinomial
  8. def ceil[N](numerator: N, denominator: N)(implicit arg0: Integral[N]): N

    Permalink

    Deprecated alternate name

    Deprecated alternate name

    Definition Classes
    Div
  9. def clone(): AnyRef

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  10. def div[N](numerator: N, denominator: N)(implicit arg0: Integral[N]): N

    Permalink

    Simple helper for rounding-up integer-division

    Simple helper for rounding-up integer-division

    Definition Classes
    Div
  11. final def eq(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  12. def equals(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  13. def finalize(): Unit

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  14. def geometricSteps(maxDepth: Int, N: Int = 100): SortedSet[Int]

    Permalink

    Divide [0, maxDepth] into N geometrically-evenly-spaced steps (of size ≈maxDepth^(1/N)).

    Divide [0, maxDepth] into N geometrically-evenly-spaced steps (of size ≈maxDepth^(1/N)).

    Until the k-th step is bigger than k, the whole number k is used in its stead.

    Definition Classes
    Steps
  15. final def getClass(): Class[_]

    Permalink
    Definition Classes
    AnyRef → Any
  16. def hashCode(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  17. def interpolate[N](start: N, end: N, delta: Double)(implicit arg0: Numeric[N]): Double

    Permalink
    Definition Classes
    Interpolate
  18. def interpolate[N](start: N, end: N, delta: Rational)(implicit arg0: Integral[N]): Rational

    Permalink
    Definition Classes
    Interpolate
  19. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  20. def min(a: Long, b: Int): Int

    Permalink
    Definition Classes
    Min
  21. def min(a: Int, b: Long): Int

    Permalink
    Definition Classes
    Min
  22. final def ne(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  23. final def notify(): Unit

    Permalink
    Definition Classes
    AnyRef
  24. final def notifyAll(): Unit

    Permalink
    Definition Classes
    AnyRef
  25. def roundNumbers(maxDepth: Int): SortedSet[Int]

    Permalink

    Produce a set of "round numbers" between 0 and a provided N, inclusive.

    Produce a set of "round numbers" between 0 and a provided N, inclusive.

    Coverage is relatively dense but the total number of sampled/returned integers is still O(log(N)) in the input N; specifically, 35 integers are returned in each factor-of-10 window (detailed below).

    The absolute difference between consecutive integers is non-decreasing over the entire range and, (after the [0,10] interval), no two consecutive integers returned are more than 10% different from one another.

    0, 1, 2, 3, 4, 5, 6, 7, 8, 9, base case: include all of [0, 10]. 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, step by one from 10% to 20% of the next power of 10 (100 here). 20, 22, 24, 26, 28, 30, 32, 34, 36, 38, 40, 42, 44, 46, 48, step by two from 20% to 50% of the next power of 10. 50, 55, 60, 65, 70, 75, 80, 85, 90, 95, step by five from 50% to 100% of the next power of 10.

    …then repeat the [10, 95] portion, multiplied by powers of 10:

    100, 110, 120, 130, 140, 150, 160, 170, 180, 190, this is 10x the "steps by one" section above. 200, 220, 240, 260, 280, 300, 320, 340, 360, 380, likewise, 10x the "steps by two" from above.

    …etc.

    Definition Classes
    Steps
  26. final def synchronized[T0](arg0: ⇒ T0): T0

    Permalink
    Definition Classes
    AnyRef
  27. def toString(): String

    Permalink
    Definition Classes
    AnyRef → Any
  28. final def wait(): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  29. final def wait(arg0: Long, arg1: Int): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  30. final def wait(arg0: Long): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from all

Inherited from Steps

Inherited from Min

Inherited from Interpolate

Inherited from Div

Inherited from HasBinomial

Inherited from Serializable

Inherited from Serializable

Inherited from AnyRef

Inherited from Any

Ungrouped