def
definition
def or abbrev
scaleUncertainty
show as:
view Lean formalization →
formal statement (Lean)
44private def scaleUncertainty (c : ℝ) (hc : 0 ≤ c) (u : Uncertainty) : Uncertainty :=
proof body
Definition body.
45 match u with
46 | .sigma σ hσ =>
47 .sigma (σ * c) (mul_nonneg hσ hc)
48 | .interval lo hi hlohi =>
49 .interval (lo * c) (hi * c) (mul_le_mul_of_nonneg_right hlohi hc)
50 | .discrete support =>
51 .discrete (support.map (fun vw => (vw.1 * c, vw.2)))
52