- Timestamp:
- 2015-06-05T11:26:24-07:00 (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/f4grobner/division.lisp
r59 r64 137 137 (j (1+ i) (1- (length g)))))) 138 138 139 140 (defun poly-normalize (ring p &aux (c (poly-lc p))) 141 "Divide a polynomial by its leading coefficient. It assumes 142 that the division is possible, which may not always be the 143 case in rings which are not fields. The exact division operator 144 is assumed to be provided by the RING structure of the 145 COEFFICIENT-RING package." 146 (mapc #'(lambda (term) 147 (setf (term-coeff term) (funcall (ring-div ring) (term-coeff term) c))) 148 (poly-termlist p)) 149 p) 150 151 (defun poly-normalize-list (ring plist) 152 "Divide every polynomial in a list PLIST by its leading coefficient. " 153 (mapcar #'(lambda (x) (poly-normalize ring x)) plist))
Note:
See TracChangeset
for help on using the changeset viewer.