WhoCites Definitions mb list 2 Sections MarkB generic Doc
IF YOU CAN SEE THIS go to /sfa/Nuprl/Shared/Xindentation_hack_doc.html
Who Cites count pairs?
count_pairsDef count(x < y in L | P(x;y))
Def == sum(if (i<j)P(L[i];L[j]) 1 else 0 fi | i < ||L||; j < ||L||)
Thm* T:Type, L:T List, P:(TT). count(x < y in L | P(x,y))  
selectDef l[i] == hd(nth_tl(i;l))
Thm* A:Type, l:A List, n:. 0n  n<||l||  l[n A
nth_tlDef nth_tl(n;as) == if n0 as else nth_tl(n-1;tl(as)) fi  (recursive)
Thm* A:Type, as:A List, i:. nth_tl(i;as A List
le_intDef ij == j<i
Thm* i,j:. (ij 
lt_intDef i<j == if i<j true ; false fi
Thm* i,j:. (i<j 
bandDef pq == if p q else false fi
Thm* p,q:. (pq 
lengthDef ||as|| == Case of as; nil  0 ; a.as'  ||as'||+1  (recursive)
Thm* A:Type, l:A List. ||l||  
Thm* ||nil||  
double_sumDef sum(f(x;y) | x < ny < m) == sum(sum(f(x;y) | y < m) | x < n)
Thm* n,m:f:(nm). sum(f(x,y) | x < ny < m 
hdDef hd(l) == Case of l; nil  "?" ; h.t  h
Thm* A:Type, l:A List. ||l|| hd(l A
sumDef sum(f(x) | x < k) == primrec(k;0;x,nn+f(x))
Thm* n:f:(n). sum(f(x) | x < n 
tlDef tl(l) == Case of l; nil  nil ; h.t  t
Thm* A:Type, l:A List. tl(l A List
primrecDef primrec(n;b;c) == if n=0 b else c(n-1,primrec(n-1;b;c)) fi  (recursive)
Thm* T:Type, n:b:Tc:(nTT). primrec(n;b;c T
bnotDef b == if b false else true fi
Thm* b:b  
eq_intDef i=j == if i=j true ; false fi
Thm* i,j:. (i=j 

Syntax:count(x < y in L | P(x;y)) has structure: count_pairs(Lx,y.P(x;y))

About:
listnillist_indboolbfalse
btrueifthenelseintnatural_numberaddsubtractint_eq
lessless_thantokenlambdaapplyfunction
recursive_def_noticeuniversememberimpliesall!abstraction
IF YOU CAN SEE THIS go to /sfa/Nuprl/Shared/Xindentation_hack_doc.html

WhoCites Definitions mb list 2 Sections MarkB generic Doc