| author | paulson |
| Fri, 11 Sep 1998 16:25:40 +0200 | |
| changeset 5479 | 5a5dfb0f0d7d |
| parent 4809 | 595f905cc348 |
| child 6481 | dbf2d9b3d6c8 |
| permissions | -rw-r--r-- |
(* Title: ex/Fib ID: $Id$ Author: Lawrence C Paulson, Cambridge University Computer Laboratory Copyright 1997 University of Cambridge The Fibonacci function. Demonstrates the use of recdef. *) Fib = WF_Rel + Divides + Primes + consts fib :: "nat => nat" recdef fib "less_than" "fib 0 = 0" "fib 1 = 1" "fib (Suc(Suc x)) = (fib x + fib (Suc x))" end