chore(library/init/data/nat): remove pow.lean

This commit is contained in:
Leonardo de Moura 2018-02-20 09:53:50 -08:00
parent 3f04d041f6
commit bddc84664c
4 changed files with 16 additions and 28 deletions

View file

@ -195,4 +195,16 @@ protected lemma bit1_ne_zero (n : ) : bit1 n ≠ 0 :=
show succ (n + n) ≠ 0, from
λ h, nat.no_confusion h
/- Exponentiation -/
def pow (b : ) :
| 0 := 1
| (succ n) := pow n * b
infix `^` := pow
lemma pow_succ (b n : ) : b^(succ n) = b^n * b := rfl
@[simp] lemma pow_zero (b : ) : b^0 = 1 := rfl
end nat

View file

@ -4,5 +4,5 @@ Released under Apache 2.0 license as described in the file LICENSE.
Authors: Leonardo de Moura
-/
prelude
import init.data.nat.basic init.data.nat.div init.data.nat.pow init.data.nat.lemmas
import init.data.nat.basic init.data.nat.div init.data.nat.lemmas
init.data.nat.bitwise

View file

@ -4,7 +4,7 @@ Released under Apache 2.0 license as described in the file LICENSE.
Authors: Leonardo de Moura, Jeremy Avigad
-/
prelude
import init.data.nat.basic init.data.nat.div init.data.nat.pow init.meta init.algebra.functions
import init.data.nat.basic init.data.nat.div init.meta init.algebra.functions
universes u
namespace nat
@ -1350,4 +1350,6 @@ begin
simp [h₁] },
rw [eq.symm (mod_eq_sub_mod p_b_ge)] }
end
end nat

View file

@ -1,26 +0,0 @@
/-
Copyright (c) 2017 Galois Inc. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Author: Simon Hudon
exponentiation on natural numbers
This is a work-in-progress
-/
prelude
import init.data.nat.basic init.meta
namespace nat
def pow (b : ) :
| 0 := 1
| (succ n) := pow n * b
infix `^` := pow
lemma pow_succ (b n : ) : b^(succ n) = b^n * b := rfl
@[simp] lemma pow_zero (b : ) : b^0 = 1 := rfl
end nat