| Mathbox for Alexander van der Vekens |
< Previous
Next >
Nearby theorems |
||
| Mirrors > Home > MPE Home > Th. List > Mathboxes > digval | Structured version Visualization version GIF version | ||
| Description: The 𝐾 th digit of a nonnegative real number 𝑅 in the positional system with base 𝐵. (Contributed by AV, 23-May-2020.) |
| Ref | Expression |
|---|---|
| digval | ⊢ ((𝐵 ∈ ℕ ∧ 𝐾 ∈ ℤ ∧ 𝑅 ∈ (0[,)+∞)) → (𝐾(digit‘𝐵)𝑅) = ((⌊‘((𝐵↑ -𝐾) · 𝑅)) mod 𝐵)) |
| Step | Hyp | Ref | Expression |
|---|---|---|---|
| 1 | digfval 50153 | . . 3 ⊢ (𝐵 ∈ ℕ → (digit‘𝐵) = (𝑘 ∈ ℤ, 𝑟 ∈ (0[,)+∞) ↦ ((⌊‘((𝐵↑ -𝑘) · 𝑟)) mod 𝐵))) | |
| 2 | 1 | 3ad2ant1 1152 | . 2 ⊢ ((𝐵 ∈ ℕ ∧ 𝐾 ∈ ℤ ∧ 𝑅 ∈ (0[,)+∞)) → (digit‘𝐵) = (𝑘 ∈ ℤ, 𝑟 ∈ (0[,)+∞) ↦ ((⌊‘((𝐵↑ -𝑘) · 𝑟)) mod 𝐵))) |
| 3 | negeq 11598 | . . . . . . . 8 ⊢ (𝑘 = 𝐾 → -𝑘 = -𝐾) | |
| 4 | 3 | oveq2d 7477 | . . . . . . 7 ⊢ (𝑘 = 𝐾 → (𝐵↑ -𝑘) = (𝐵↑ -𝐾)) |
| 5 | 4 | adantr 486 | . . . . . 6 ⊢ ((𝑘 = 𝐾 ∧ 𝑟 = 𝑅) → (𝐵↑ -𝑘) = (𝐵↑ -𝐾)) |
| 6 | simpr 490 | . . . . . 6 ⊢ ((𝑘 = 𝐾 ∧ 𝑟 = 𝑅) → 𝑟 = 𝑅) | |
| 7 | 5, 6 | oveq12d 7479 | . . . . 5 ⊢ ((𝑘 = 𝐾 ∧ 𝑟 = 𝑅) → ((𝐵↑ -𝑘) · 𝑟) = ((𝐵↑ -𝐾) · 𝑅)) |
| 8 | 7 | fveq2d 6930 | . . . 4 ⊢ ((𝑘 = 𝐾 ∧ 𝑟 = 𝑅) → (⌊‘((𝐵↑ -𝑘) · 𝑟)) = (⌊‘((𝐵↑ -𝐾) · 𝑅))) |
| 9 | 8 | oveq1d 7476 | . . 3 ⊢ ((𝑘 = 𝐾 ∧ 𝑟 = 𝑅) → ((⌊‘((𝐵↑ -𝑘) · 𝑟)) mod 𝐵) = ((⌊‘((𝐵↑ -𝐾) · 𝑅)) mod 𝐵)) |
| 10 | 9 | adantl 487 | . 2 ⊢ (((𝐵 ∈ ℕ ∧ 𝐾 ∈ ℤ ∧ 𝑅 ∈ (0[,)+∞)) ∧ (𝑘 = 𝐾 ∧ 𝑟 = 𝑅)) → ((⌊‘((𝐵↑ -𝑘) · 𝑟)) mod 𝐵) = ((⌊‘((𝐵↑ -𝐾) · 𝑅)) mod 𝐵)) |
| 11 | simp2 1156 | . 2 ⊢ ((𝐵 ∈ ℕ ∧ 𝐾 ∈ ℤ ∧ 𝑅 ∈ (0[,)+∞)) → 𝐾 ∈ ℤ) | |
| 12 | simp3 1157 | . 2 ⊢ ((𝐵 ∈ ℕ ∧ 𝐾 ∈ ℤ ∧ 𝑅 ∈ (0[,)+∞)) → 𝑅 ∈ (0[,)+∞)) | |
| 13 | ovexd 7496 | . 2 ⊢ ((𝐵 ∈ ℕ ∧ 𝐾 ∈ ℤ ∧ 𝑅 ∈ (0[,)+∞)) → ((⌊‘((𝐵↑ -𝐾) · 𝑅)) mod 𝐵) ∈ V) | |
| 14 | 2, 10, 11, 12, 13 | ovmpod 7614 | 1 ⊢ ((𝐵 ∈ ℕ ∧ 𝐾 ∈ ℤ ∧ 𝑅 ∈ (0[,)+∞)) → (𝐾(digit‘𝐵)𝑅) = ((⌊‘((𝐵↑ -𝐾) · 𝑅)) mod 𝐵)) |
| Colors of variables: wff setvar class |
| This proof depends on syntax axioms: → wi 4 ∧ wa 401 ∧ w3a 1104 = wceq 1572 ∈ wcel 2151 Vcvv 3456 ‘cfv 6573 (class class class)co 7461 ∈ cmpo 7463 0cc0 11249 · cmul 11254 +∞cpnf 11389 -cneg 11591 ℕcn 12385 ℤcz 12743 [,)cico 13528 ⌊cfl 13980 mod cmo 14059 ↑cexp 14254 digitcdig 50151 |
| This proof depends on axioms: ax-mp 5 ax-1 6 ax-2 7 ax-3 8 ax-gen 1830 ax-4 1844 ax-5 1947 ax-6 2004 ax-7 2045 ax-8 2153 ax-9 2161 ax-10 2184 ax-11 2201 ax-12 2220 ax-ext 2741 ax-rep 5241 ax-sep 5258 ax-nul 5269 ax-pow 5337 ax-pr 5401 ax-un 7793 ax-cnex 11305 ax-resscn 11306 |
| This proof depends on definitions: df-bi 210 df-an 402 df-or 862 df-3or 1105 df-3an 1106 df-tru 1575 df-fal 1585 df-ex 1815 df-nf 1819 df-sb 2105 df-mo 2571 df-eu 2601 df-clab 2748 df-cleq 2761 df-clel 2845 df-nfc 2919 df-ne 2966 df-ral 3087 df-rex 3097 df-reu 3372 df-rab 3419 df-v 3458 df-sbc 3745 df-csb 3854 df-ss 3903 df-dif 4052 df-in 4096 df-un 4156 df-nul 4284 df-if 4488 df-pw 4564 df-sn 4591 df-pr 4593 df-op 4844 df-uni 4876 df-iun 4961 df-br 5112 df-opab 5177 df-mpt 5196 df-id 5556 df-xp 5667 df-rel 5668 df-cnv 5669 df-co 5670 df-dm 5671 df-rn 5672 df-res 5673 df-ima 5674 df-iota 6527 df-fun 6575 df-fn 6576 df-f 6577 df-f1 6578 df-fo 6579 df-f1o 6580 df-fv 6581 df-ov 7464 df-oprab 7465 df-mpo 7466 df-1st 8045 df-2nd 8046 df-neg 11593 df-z 12744 df-dig 50152 |
| This theorem is used by: digvalnn0 50155 nn0digval 50156 dignn0fr 50157 dig0 50162 dig2nn0 50167 |
| Copyright terms: Public domain | W3C validator |