Comparisons of powers and logarithms #
For a base b ∈ (0, 1), a positive real x and natural numbers m and n with 0 < n, the
comparison of x ^ n with b ^ m is a comparison of Real.logb b x with the ratio m / n. The
inequalities reverse because Real.logb b is antitone for such a base. In the same way, the
integer floor ⌊logb b x⌋ is the largest integer n with x ≤ b ^ n.
For a base greater than one, the natural floor of the logarithm locates a real number at least one between two consecutive powers. These intervals support dyadic decompositions and convergence estimates.
Main results #
Real.pow_le_pow_iff_div_le_logb_of_base_lt_one:x ^ n ≤ b ^ m ↔ m / n ≤ logb b x.Real.pow_le_pow_iff_logb_le_div_of_base_lt_one:b ^ m ≤ x ^ n ↔ logb b x ≤ m / n.Real.le_floor_logb_iff_zpow_le_of_base_lt_one:n ≤ ⌊logb b x⌋ ↔ x ≤ b ^ nforn : ℤ.Real.pow_natFloor_logb_le_self:b ^ ⌊logb b x⌋₊ ≤ xfor1 < band1 ≤ x.Real.lt_pow_natFloor_logb_add_one:x < b ^ (⌊logb b x⌋₊ + 1)for1 < band0 < x.