anchor.diff:  ;;; Possibly sparse matrix interface
   
   (defgeneric height-of (matrix &key densep)
  -  (:documentation "Return the number of rows of MATRIX."))
  +  (:documentation "Return the number of rows of MATRIX. If DENSEP
  +return the number of non-empty rows."))
   
   (defgeneric width-of (matrix &key densep)
  -  (:documentation "Return the number of columns of MATRIX."))
  +  (:documentation "Return the number of columns of MATRIX. If DENSEP
  +return the number of non-empty columns."))
   
   (defgeneric size-of (matrix)
     (:documentation "Return the number known cells in MATRIX. This is an
  -upper limit for dense indices produced by MAP-MATRIX."))
  -
  -(defgeneric map-row-densely (matrix row)
  +upper limit for the dense indices produced by MAP-MATRIX."))
  +
  +(defgeneric dense-row-index (matrix row)
     (:documentation "Number those rows that are not empty from 0. Return
  -NIL for empty rows."))
  -
  -(defgeneric map-column-densely (matrix column)
  +NIL for empty rows.")
  +  (:method ((matrix t) row)
  +    row))
  +
  +(defgeneric dense-column-index (matrix column)
     (:documentation "Number those columns that are not empty from 0.
  -Return NIL for empty columns."))
  +Return NIL for empty columns.")
  +  (:method ((matrix t) column)
  +    column))
   
   (defgeneric map-matrix (function matrix)
  -  (:documentation "Call FUNCTION for each non-missing cell of MATRIX.
  -FUNCTION is of four parameters: ROW, COLUMN, VALUE and DENSE-INDEX."))
  +  (:documentation "Call FUNCTION for each non-empty cell of MATRIX.
  +FUNCTION is of four parameters: ROW, COLUMN, VALUE and DENSE-INDEX
  +where DENSE-INDEX is akin to a row major index except it doesn't skips
  +over empty cells. DENSE-INDEX is always less than the SIZE-OF the
  +MATRIX."))
   
   (defmacro do-matrix (((row column value dense-index) matrix)
                        &body body)
  
positive.code:   (let ((svd (subseq svd 0 max-n)))
      (lambda (row column)
        (let ((base-value (funcall base-approximator row column))
              (row (map-row-densely matrix row))
              (column (map-column-densely matrix column)))
          (svd-value svd row column :base-value base-value :clip clip)))))
  
  
negative.code:                (map-matrix
                  (lambda (row column value i)
                    (declare (ignore value))
                    (let ((row (dense-row-index matrix row))
                          (column (dense-column-index matrix column)))
                      (setf (aref approximation i)
                            (funcall clip
                                     (+ (aref approximation i)
  