Package group-mult-add: Group multiplication by repeated addition

Information

namegroup-mult-add
version1.8
descriptionGroup multiplication by repeated addition
authorJoe Leslie-Hurd <joe@gilith.com>
licenseMIT
requiresbool
group-mult-def
group-mult-thm
group-thm
group-witness
list
natural
natural-bits
showAlgebra.Group
Data.Bool
Data.List
Number.Natural

Files

Defined Constant

Theorems

z x. multAdd z x [] = z

x n. x * n = multAdd 0 x (Bits.fromNatural n)

z x l. multAdd z x l = z + x * Bits.toNatural l

z x h t.
    multAdd z x (h :: t) = multAdd (if h then z + x else z) (x + x) t

External Type Operators

External Constants

Assumptions

Bits.toNatural [] = 0

() = λp. p ((select) p)

t. (x. t) t

() = λp. p = λx.

x. x * 0 = 0

x. 0 + x = x

x. x + 0 = x

n. Bits.toNatural (Bits.fromNatural n) = n

x. x * 1 = x

x. x + ~x = 0

() = λp q. p q p

t. (t ) (t )

t1 t2. (if then t1 else t2) = t2

t1 t2. (if then t1 else t2) = t1

x y. x = y y = x

m n. m + n = n + m

x. x * 2 = x + x

() = λp q. (λf. f p q) = λf. f

() = λp. q. (x. p x q) q

() = λp q. r. (p r) (q r) r

x y z. x = y y = z x = z

x y z. x + y + z = x + (y + z)

x m n. x * (m * n) = x * m * n

p. (x. y. p x y) y. x. p x (y x)

x m n. x * (m + n) = x * m + x * n

p. p [] (h t. p t p (h :: t)) l. p l

h t. Bits.toNatural (h :: t) = 2 * Bits.toNatural t + if h then 1 else 0

b f. fn. fn [] = b h t. fn (h :: t) = f h t (fn t)