ex/NatSum.thy
author clasohm
Wed, 02 Nov 1994 11:50:09 +0100
changeset 156 fd1be45b64bf
parent 68 acad709cad5d
permissions -rw-r--r--
added IOA to isabelle/HOL

(*  Title: 	HOL/ex/natsum.thy
    ID:         $Id$
    Author: 	Tobias Nipkow
    Copyright   1994 TU Muenchen

A summation operator. sum(f,n+1) is the sum of all f(i), i=0...n.
*)

NatSum = Arith +
consts sum     :: "[nat=>nat, nat] => nat"
rules  sum_0      "sum(f,0) = 0"
       sum_Suc    "sum(f,Suc(n)) = f(n) + sum(f,n)"
end