Changeset 4024 for branches/f4grobner
- Timestamp:
- 2016-05-31T14:44:29-07:00 (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/f4grobner/monom.lisp
r4023 r4024 611 611 (:documentation "Convert a symbolic polynomial SELF to infix form, using variables VARS. The default 612 612 value of VARS is the corresponding slot value of SELF.") 613 (:method :before ((self monom) &optional vars) 614 "Check the length of variables VARS against the length of exponents." 615 (with-slots (exponents) 616 self 617 (assert (= (length vars) (length exponents)) 618 (vars exponents) 619 "Variables ~A and exponents ~A must have the same length." vars exponents))) 613 620 (:method ((self monom) &optional vars) 614 621 "Convert a monomial SELF to infix form, using variable VARS to build the representation." … … 620 627 (t (list `(expt ,var ,power))))) 621 628 vars (coerce exponents 'list)))) 622 (cond ((endp (cdr m)) (car m)) 629 (print m) 630 (cond ((endp m) 1) 631 ((endp (cdr m)) (car m)) 623 632 (t 624 633 (cons '* m)))))) … … 629 638 self 630 639 (let ((m (call-next-method))) 640 (print m) 631 641 (cond ;;((= coeff 1) m) 632 642 ;;((eql (car m) '*) (list* '* coeff (cdr m)))
Note:
See TracChangeset
for help on using the changeset viewer.