deBruijn sequence NESL code

2000-03-31 Thread Wayne Young
I appreciate any insight anyone has to offer on this code. I obviously don't care about losing NESL's parallel computing power. I am more interested in a relatively efficient and readable function (or functions) as the C code I currently have is garbage to read and I don't have the time to spare

Re: deBruijn sequences

2000-03-31 Thread Wayne Young
From: Jan de Wit <[EMAIL PROTECTED]> >Pray tell, what *are* base-2 deBruijn sequences? I know what deBruijn >terms are, and have some code for them, but as for sequences... >I think you are going to get a lot of replies like this one ;-) The following three are examples of binary de Bruijn seque

deBruijn sequences

2000-03-29 Thread Wayne Young
Was wondering if there was a simple Haskell function/library for producing "simple" base-2 deBruijn sequences. I have a clean seven line function in NESL, but have no chance in Hades of being able to compile/use NESL with my resources. Haskell-wise, I'm using Hugs98. Thanks, Wayne

Re: Ackermann's function

1999-01-16 Thread Wayne Young
From: Theo Norvell <[EMAIL PROTECTED]> >See http://www.engr.mun.ca/~theo/Publications/indExamp.lgs >for three versions. The simplest is just > >> p 0 n = n+1 >> p (m+1) 0 = p m 1 >> p (m+1) (n+1) = p m (p (m+1) n) Thanks! =) Of course it was so simple that I couldn't figure it out.

Ackermann's function

1999-01-16 Thread Wayne Young
Greets, Sorry to intrude (new to both the list and to Haskell). I'm still getting the syntax correct (playing with simple functions, etc) and was wondering how I would define Ackermann's function in Haskell. I'm curious to see how Haskell (using Hugs) will outperform C and Pascal for th