Environment

it.grypho.scala.leonardo.core.Environment
See theEnvironment companion class
object Environment

Companion holding the global precision constant.

Attributes

Companion
class
Graph
Supertypes
class Object
trait Matchable
class Any
Self type

Members list

Value members

Concrete fields

val DefaultPrecision: Int

Canonical default decimal precision for display rounding; single source of truth across all packages that convert numbers to strings.

Canonical default decimal precision for display rounding; single source of truth across all packages that convert numbers to strings.

Attributes

Canonical default working precision, in decimal digits, for the exact-arithmetic tier.

Canonical default working precision, in decimal digits, for the exact-arithmetic tier.

A different quantity from DefaultPrecision, and deliberately a separate field rather than an overload of it: precision decides how a result is shown, working precision decides how tightly an irrational is approximated before exact arithmetic continues. Showing five decimals of a value computed to thirty is the normal case, and conflating the two would make raising the display precision silently change results.

Attributes