- Location:
- /trunk
- Files:
-
- 1 deleted
- 1 edited
-
Docs (deleted)
-
grobner.lisp (modified) (5 diffs)
Legend:
- Unmodified
- Added
- Removed
-
/trunk/grobner.lisp
r30 r20 1074 1074 (setf r (scalar-times-poly ring cg r) 1075 1075 c (funcall (ring-mul ring) c cg) 1076 ;; p := cg*p-cp*m*g1077 1076 p (grobner-op ring cp cg m p g)))) 1078 1077 (debug-cgb "/")) … … 1675 1674 J the polynomial W*H belongs to I." 1676 1675 (cond 1677 ((endp g)1678 ;;Id(G) consists of 0 only so W*0=0 belongs to Id(F)1679 (if (every #'poly-zerop f)1680 (error "First ideal must be non-zero.")1681 (list (make-poly1682 (list (make-term1683 (make-monom (monom-dimension (poly-lm (find-if-not #'poly-zerop f)))1684 :initial-element 0)1685 (funcall (ring-unit ring))))))))1686 ((endp (cdr g))1687 (colon-ideal-1 ring f (car g) top-reduction-only))1688 (t1689 (ideal-intersection ring1690 (colon-ideal-1 ring f (car g) top-reduction-only)1691 (colon-ideal ring f (rest g) top-reduction-only)1692 top-reduction-only))))1676 ((endp g) 1677 ;;Id(G) consists of 0 only so W*0=0 belongs to Id(F) 1678 (if (every #'poly-zerop f) 1679 (error "First ideal must be non-zero.") 1680 (list (make-poly 1681 (list (make-term 1682 (make-monom (monom-dimension (poly-lm (find-if-not #'poly-zerop f))) 1683 :initial-element 0) 1684 (funcall (ring-unit ring)))))))) 1685 ((endp (cdr g)) 1686 (colon-ideal-1 ring f (car g) top-reduction-only)) 1687 (t 1688 (ideal-intersection ring 1689 (colon-ideal-1 ring f (car g) top-reduction-only) 1690 (colon-ideal ring f (rest g) top-reduction-only) 1691 top-reduction-only)))) 1693 1692 1694 1693 (defun colon-ideal-1 (ring f g &optional (top-reduction-only $poly_top_reduction_only)) … … 2049 2048 ,@(mapcar #'(lambda (var power) `((mexpt) ,var ,power)) 2050 2049 vars (monom-exponents (term-monom object))))) 2051 ;; Assumes that Lisp and Maxima logicals coincide2052 (:logical object)2053 2050 (otherwise 2054 2051 object))) … … 2186 2183 2187 2184 (defmfun $poly_buchberger_criterion (g vars) 2188 (with-parsed-polynomials ((vars) :poly-lists (g) :value-type :logical)2185 (with-parsed-polynomials ((vars) :poly-lists (g)) 2189 2186 (buchberger-criterion *maxima-ring* g))) 2190 2187 … … 2290 2287 (ideal-polysaturation *maxima-ring* f ideal-list 0 nil))) 2291 2288 2292 (defmfun $poly_lt (f vars)2293 (with-parsed-polynomials ((vars) :polynomials (f) :value-type :polynomial)2294 (make-poly-from-termlist (list (poly-lt f)))))2295 2296 (defmfun $poly_lm (f vars)2297 (with-parsed-polynomials ((vars) :polynomials (f) :value-type :polynomial)2298 (make-poly-from-termlist (list (make-term (poly-lm f) (funcall (ring-unit *maxima-ring*)))))))2299
Note:
See TracChangeset
for help on using the changeset viewer.
