Metamath Proof Explorer


Theorem dig2nn0ld

Description: The leading digits of a positive integer in a binary system are 0. (Contributed by AV, 25-May-2020)

Ref Expression
Assertion dig2nn0ld ( ( 𝑁 ∈ ℕ ∧ 𝐾 ∈ ( ℤ ‘ ( #b𝑁 ) ) ) → ( 𝐾 ( digit ‘ 2 ) 𝑁 ) = 0 )

Proof

Step Hyp Ref Expression
1 2z 2 ∈ ℤ
2 uzid ( 2 ∈ ℤ → 2 ∈ ( ℤ ‘ 2 ) )
3 1 2 mp1i ( ( 𝑁 ∈ ℕ ∧ 𝐾 ∈ ( ℤ ‘ ( #b𝑁 ) ) ) → 2 ∈ ( ℤ ‘ 2 ) )
4 simpl ( ( 𝑁 ∈ ℕ ∧ 𝐾 ∈ ( ℤ ‘ ( #b𝑁 ) ) ) → 𝑁 ∈ ℕ )
5 blennn ( 𝑁 ∈ ℕ → ( #b𝑁 ) = ( ( ⌊ ‘ ( 2 logb 𝑁 ) ) + 1 ) )
6 5 fveq2d ( 𝑁 ∈ ℕ → ( ℤ ‘ ( #b𝑁 ) ) = ( ℤ ‘ ( ( ⌊ ‘ ( 2 logb 𝑁 ) ) + 1 ) ) )
7 6 eleq2d ( 𝑁 ∈ ℕ → ( 𝐾 ∈ ( ℤ ‘ ( #b𝑁 ) ) ↔ 𝐾 ∈ ( ℤ ‘ ( ( ⌊ ‘ ( 2 logb 𝑁 ) ) + 1 ) ) ) )
8 7 biimpa ( ( 𝑁 ∈ ℕ ∧ 𝐾 ∈ ( ℤ ‘ ( #b𝑁 ) ) ) → 𝐾 ∈ ( ℤ ‘ ( ( ⌊ ‘ ( 2 logb 𝑁 ) ) + 1 ) ) )
9 dignnld ( ( 2 ∈ ( ℤ ‘ 2 ) ∧ 𝑁 ∈ ℕ ∧ 𝐾 ∈ ( ℤ ‘ ( ( ⌊ ‘ ( 2 logb 𝑁 ) ) + 1 ) ) ) → ( 𝐾 ( digit ‘ 2 ) 𝑁 ) = 0 )
10 3 4 8 9 syl3anc ( ( 𝑁 ∈ ℕ ∧ 𝐾 ∈ ( ℤ ‘ ( #b𝑁 ) ) ) → ( 𝐾 ( digit ‘ 2 ) 𝑁 ) = 0 )