anchor.diff:    (unless (or (zerop n)
                 (dnull l))
       (cons (dcar l) (dtake (1- n) (dcdr l)))))
  +
  +(defun beginsp (p d)
  +  (if (null p)
  +      t
  +      (if (equal (car p) (dcar d))
  +          (beginsp (cdr p) (dcdr d))
  +          nil)))
  +                 
  +(defun dfind (p d n &optional (o 0))
  +  (if (zerop n)
  +      nil
  +      (if (beginsp p d)
  +          o
  +          (dfind p (dcdr d) (1- n) (1+ o)))))
  +
  +(defun seq-length (n)
  +  (* n (1- (expt 2 n))))
  +
  +(defun dfind-all (p d n &optional (o 0) (c nil))
  +  (if (zerop n)
  +      c
  +      (dfind-all p (dcdr d) (1- n) (1+ o) 
  +                 (if (beginsp p d)
  +                     (cons o c)
  +                     c))))
  +
  +(defun sbeginsp (p g)
  +  (if (equal #* p)
  +      t
  +      (if (equal (bitbv (elt p 0)) (funcall g))
  +          (sbeginsp (subseq p 1) g)
  +          nil)))
  +
  +(defun sfind (p n &optional (offset 0))
  +  (let ((gen (bit-gen n offset)))
  +    (if (sbeginsp p gen)
  +        offset
  +        (sfind p n (1+ offset)))))
  +
  +(defun sfind-all (p n &optional (rem (seq-length n)) (offset 0) (coll nil))
  +  (if (zerop rem)
  +      coll
  +      (let ((gen (bit-gen n)))
  +        (funcall gen offset)
  +        (if (sbeginsp p gen)
  +            (sfind-all p n (1- rem) (1+ offset) (cons offset coll))
  +            (sfind-all p n (1- rem) (1+ offset) coll)))))
  
positive.code:                  (if (> (length v) c)
                       (subseq v 0 c)
                       v))))
      #'rec)))
  
  (defun num-gen (n &optional (init #*10))
    "return a function representing prbs-N. The returned function takes a single argument which is the number of the next n-bit integer values to generate from the sequence (default 1 value)."
  
negative.code: 
  (in-package :prbs)
  
  (declaim (optimize (debug 0) (safety 0) (speed 3)))
  
  (defun prbs-n (bv taps)
    "=> bit-vector
  
  