ClojureDocs

Nav

Namespaces

scalb

clojure.math

Available since 1.11
  • (scalb d scaleFactor)
Returns d * 2^scaleFactor, scaling by a factor of 2. If the exponent
is between Double/MIN_EXPONENT and Double/MAX_EXPONENT, the answer is exact.
If d is ##NaN => ##NaN
If d is ##Inf or ##-Inf => ##Inf or ##-Inf respectively
If d is zero => zero of same sign as d
See: https://docs.oracle.com/javase/8/docs/api/java/lang/Math.html#nextDown-double-