Cantor tuple function, BigInt, and integer overflow

2012-12-20 Thread Joseph Rushton Wakeling
Hello all, I've been playing around trying to implement the Cantor tuple function (see attached code), which is essentially a way to map a sequence x1, x2, ..., xN of non-negative integers to a single unique number. See: https://en.wikipedia.org/wiki/Pairing_function#Cantor_pairing_function

Re: Cantor tuple function, BigInt, and integer overflow

2012-12-20 Thread H. S. Teoh
On Thu, Dec 20, 2012 at 07:46:39PM +0100, Joseph Rushton Wakeling wrote: Hello all, I've been playing around trying to implement the Cantor tuple function (see attached code), which is essentially a way to map a sequence x1, x2, ..., xN of non-negative integers to a single unique number.