Changeset 870 for branches/f4grobner
- Timestamp:
- 2015-06-09T11:48:42-07:00 (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/f4grobner/monomial.lisp
r869 r870 121 121 "Return the sugar of a monomial M. Optinally, a range 122 122 of variables may be specified with arguments START and END." 123 (declare (type monom m) (fixnum start end))124 123 (monom-total-degree m start end)) 125 124 126 125 (defun monom-div (m1 m2 &aux (result (copy-structure m1))) 127 126 "Divide monomial M1 by monomial M2." 128 (declare (type monom m1 m2)) 129 (map-into (monom-exponents result) #'- (monom-exponents m1) (monom-exponents m2)) 130 result) 127 (map-into result #'- m1 m2)) 131 128 132 129 (defun monom-mul (m1 m2 &aux (result (copy-structure m1))) 133 130 "Multiply monomial M1 by monomial M2." 134 (declare (type monom m1 m2 result)) 135 (map-into (monom-exponents result) #'+ (monom-exponents m1) (monom-exponents m2)) 136 result) 131 (map-into result #'+ m1 m2)) 137 132 138 133 (defun monom-divides-p (m1 m2)
Note:
See TracChangeset
for help on using the changeset viewer.