proposition: Lemma log2_unique' : forall a b c, 0<=b -> 0<=c<2^b -> a == 2^b + c -> log2 a == b.
proof: Proof. intros a b c Hb (Hc,H) EQ. apply log2_unique. - trivial. - rewrite EQ. split. + rewrite <- add_0_r at 1. now apply add_le_mono_l. + rewrite pow_succ_r by order. rewrite two_succ at 2. nzsimpl. now apply add_lt_mono_l. Qed.
imports: NZAxioms NZMulOrder NZPow