8890
|
1 |
theory Semigroups = Main:;
|
|
2 |
|
|
3 |
constdefs
|
|
4 |
is_assoc :: "('a \\<Rightarrow> 'a \\<Rightarrow> 'a) \\<Rightarrow> bool"
|
8903
|
5 |
"is_assoc f \\<equiv> \\<forall>x y z. f (f x y) z = f x (f y z)";
|
8890
|
6 |
|
|
7 |
consts
|
|
8 |
plus :: "'a \\<Rightarrow> 'a \\<Rightarrow> 'a" (infixl "\<Oplus>" 65);
|
|
9 |
axclass
|
|
10 |
plus_semigroup < "term"
|
|
11 |
assoc: "is_assoc (op \<Oplus>)";
|
|
12 |
|
|
13 |
consts
|
|
14 |
times :: "'a \\<Rightarrow> 'a \\<Rightarrow> 'a" (infixl "\<Otimes>" 65);
|
|
15 |
axclass
|
|
16 |
times_semigroup < "term"
|
|
17 |
assoc: "is_assoc (op \<Otimes>)";
|
|
18 |
|
|
19 |
end; |