text‹This theory only contains a single theorem, which is a lemma
Lagrange's proof that every natural number is the sum of 4 squares.
sole purpose is to demonstrate ordered rewriting for commutative
.
enterprising reader might consider proving all of Lagrange's
.›
definition sq :: "'a::times => 'a"where"sq x == x*x"
text‹The following lemma essentially shows that every natural
is the sum of four squares, provided all prime numbers are.
, this is an abstract theorem about commutative rings. It has,
priori, nothing to do with nat.›