Theorem b0orb1 | index | src |

theorem b0orb1 (n: nat): $ n = b0 (n // 2) \/ n = b1 (n // 2) $;
StepHypRefExpression
1 con3
(2 || n -> n = b0 (n // 2)) -> ~n = b0 (n // 2) -> ~2 || n
2 b0mul21
2 * (n // 2) = b0 (n // 2)
3 muldiv3
2 || n -> 2 * (n // 2) = n
4 2, 3 syl5eqr
2 || n -> b0 (n // 2) = n
5 4 eqcomd
2 || n -> n = b0 (n // 2)
6 1, 5 ax_mp
~n = b0 (n // 2) -> ~2 || n
7 odddvd
odd n <-> ~2 || n
8 divmod
2 * (n // 2) + n % 2 = n
9 b1mul21
2 * (n // 2) + 1 = b1 (n // 2)
10 addeq2
n % 2 = 1 -> 2 * (n // 2) + n % 2 = 2 * (n // 2) + 1
11 10 conv odd
odd n -> 2 * (n // 2) + n % 2 = 2 * (n // 2) + 1
12 9, 11 syl6eq
odd n -> 2 * (n // 2) + n % 2 = b1 (n // 2)
13 8, 12 syl5eqr
odd n -> n = b1 (n // 2)
14 7, 13 sylbir
~2 || n -> n = b1 (n // 2)
15 6, 14 rsyl
~n = b0 (n // 2) -> n = b1 (n // 2)
16 15 conv or
n = b0 (n // 2) \/ n = b1 (n // 2)

Axiom use

axs_prop_calc (ax_1, ax_2, ax_3, ax_mp, itru), axs_pred_calc (ax_gen, ax_4, ax_5, ax_6, ax_7, ax_10, ax_11, ax_12), axs_set (elab, ax_8), axs_the (theid, the0), axs_peano (peano1, peano2, peano5, addeq, muleq, add0, addS, mul0, mulS)