close Warning: Can't synchronize with repository "(default)" (The repository directory has changed, you should resynchronize the repository with: trac-admin $ENV repository resync '(default)'). Look in the Trac log for more information.

Changeset 936 for branches/f4grobner


Ignore:
Timestamp:
2015-06-09T19:14:02-07:00 (10 years ago)
Author:
Marek Rychlik
Message:

* empty log message *

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/f4grobner/termlist.lisp

    r935 r936  
    195195;; Multiplication of polynomials
    196196;; Non-destructive version
    197 (defun termlist-mul (ring p q)
    198   (declare (ring ring))
     197(defun termlist-mul (ring-and-order p q
     198                     &aux
     199                       (ring (ro-ring ring-and-order))
     200                       (order (ro-order ring-and-order)))
     201  (declare (ring-and-order ring-and-order))
    199202  (cond ((or (endp p) (endp q)) nil)    ;p or q is 0 (represented by NIL)
    200203        ;; If p=p0+p1 and q=q0+q1 then pq=p0q0+p0q1+p1q
     
    205208        (t
    206209         (let ((head (term-mul-lst ring (termlist-lt p) (termlist-lt q)))
    207                (tail (termlist-add ring (term-times-termlist ring (car p) (cdr q))
    208                                    (termlist-mul ring (cdr p) q))))
     210               (tail (termlist-add ring-and-order
     211                                   (term-times-termlist ring (car p) (cdr q))
     212                                   (termlist-mul ring-and-order (cdr p) q))))
    209213           (cond ((null head) tail)
    210214                 ((null tail) head)
Note: See TracChangeset for help on using the changeset viewer.