| 1 | ;;; -*- Mode: Lisp; Package: Maxima; Syntax: Common-Lisp; Base: 10 -*-
|
---|
| 2 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
---|
| 3 | ;;;
|
---|
| 4 | ;;; Copyright (C) 1999, 2002, 2009, 2015 Marek Rychlik <rychlik@u.arizona.edu>
|
---|
| 5 | ;;;
|
---|
| 6 | ;;; This program is free software; you can redistribute it and/or modify
|
---|
| 7 | ;;; it under the terms of the GNU General Public License as published by
|
---|
| 8 | ;;; the Free Software Foundation; either version 2 of the License, or
|
---|
| 9 | ;;; (at your option) any later version.
|
---|
| 10 | ;;;
|
---|
| 11 | ;;; This program is distributed in the hope that it will be useful,
|
---|
| 12 | ;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
|
---|
| 13 | ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
---|
| 14 | ;;; GNU General Public License for more details.
|
---|
| 15 | ;;;
|
---|
| 16 | ;;; You should have received a copy of the GNU General Public License
|
---|
| 17 | ;;; along with this program; if not, write to the Free Software
|
---|
| 18 | ;;; Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
---|
| 19 | ;;;
|
---|
| 20 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
---|
| 21 |
|
---|
| 22 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
---|
| 23 | ;;
|
---|
| 24 | ;; Create the main Groebner Basis package.
|
---|
| 25 | ;;
|
---|
| 26 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
---|
| 27 |
|
---|
| 28 | (defpackage "NGROBNER"
|
---|
| 29 | (:use :cl :ring :monomial :order :term :infix :infix-printer :polynomial :grobner-debug
|
---|
| 30 | :division :buchberger :gebauer-moeller :gb-postprocessing :ideal
|
---|
| 31 | :utils :grobner-wrap)
|
---|
| 32 | (:export
|
---|
| 33 | ;;
|
---|
| 34 | ;; Global symbols/switches usable at Maxima interpreter level
|
---|
| 35 | ;;
|
---|
| 36 | "$LEX" "$GRLEX" "$GREVLEX" "$INVLEX" ;names of monomial orders
|
---|
| 37 | "$RING_OF_INTEGERS" ;name of ring of integers
|
---|
| 38 | "$POLY_ELIMINATION_ORDER" "$POLY_MONOMIAL_ORDER"
|
---|
| 39 | "$POLY_MONOMIAL_ORDER" "$POLY_PRIMARY_ELIMINATION_ORDER"
|
---|
| 40 | "$POLY_PRIMARY_ELIMINATION_ORDER"
|
---|
| 41 | "$POLY_SECONDARY_ELIMINATION_ORDER"
|
---|
| 42 | "$POLY_RETURN_TERM_LIST"
|
---|
| 43 | "$POLY_COEFFICIENT_RING"
|
---|
| 44 | "$POLY_GROBNER_DEBUG" ;debugging switch
|
---|
| 45 | ;;
|
---|
| 46 | ;; Global variables
|
---|
| 47 | ;;
|
---|
| 48 | "*EXPRESSION-RING*"
|
---|
| 49 | "*ELIMINATION-ORDER*"
|
---|
| 50 | "*MONOMIAL-ORDER*"
|
---|
| 51 | "*PRIMARY-ELIMINATION-ORDER*"
|
---|
| 52 | "*SECONDARY-ELIMINATION-ORDER*"
|
---|
| 53 | "*RATDISREP-FUN*"
|
---|
| 54 | ;;
|
---|
| 55 | ;; Polynomial ring operations
|
---|
| 56 | ;; Note that some require Groebner basis.
|
---|
| 57 | ;;
|
---|
| 58 | "POLY-ADD" "POLY-SUB" "POLY-UMINUS"
|
---|
| 59 | "POLY-MUL" "POLY-EXPT"
|
---|
| 60 | "POLY-ZEROP" "POLY-LM" "POLY-LT"
|
---|
| 61 | "POLY-PSEUDO-DIVIDE"
|
---|
| 62 | "POLY-NORMALIZE" "POLY-NORMALIZE-LIST"
|
---|
| 63 | ;;
|
---|
| 64 | ;; High-level Groebner Basis related functions
|
---|
| 65 | ;;
|
---|
| 66 | "FIND-ORDER" "FIND-RING"
|
---|
| 67 | "NORMAL-FORM"
|
---|
| 68 | "POLY-EXACT-DIVIDE"
|
---|
| 69 | "COLON-IDEAL" "ELIMINATION-IDEAL"
|
---|
| 70 | "GROBNER"
|
---|
| 71 | "REDUCED-GROBNER"
|
---|
| 72 | "MINIMIZATION" "REDUCTION"
|
---|
| 73 | "POLY-LCM"
|
---|
| 74 | "GROBNER-EQUAL" "GROBNER-MEMBER" "GROBNER-SUBSETP"
|
---|
| 75 | "IDEAL-INTERSECTION" "IDEAL-POLYSATURATION"
|
---|
| 76 | "IDEAL-POLYSATURATION-1" "IDEAL-SATURATION" "IDEAL-SATURATION-1"
|
---|
| 77 | "BUCHBERGER" "BUCHBERGER-CRITERION"
|
---|
| 78 | ;;
|
---|
| 79 | ;; Low-level functions
|
---|
| 80 | ;;
|
---|
| 81 | "COERCE-COEFF" "COERCE-TO-INFIX" "MAKE-POLY-FROM-TERMLIST" "MAKE-POLY-ZERO"
|
---|
| 82 | "MAKE-RING" "MAKE-TERM" "MAKE-VARIABLE" "MONOM-EXPONENTS"
|
---|
| 83 | "POLY-CONTENT" "POLY-DEPENDS-P" "POLY-PRIMITIVE-PART"
|
---|
| 84 | "POLYSATURATION-EXTENSION" "POLY-TERMLIST" "RING-UNIT"
|
---|
| 85 | "SATURATION-EXTENSION" "SPOLY" "$POLY_ELIMINATION_ORDER" "TERM-COEFF"
|
---|
| 86 | "TERM-MONOM" "MAKELIST-1" "MAKELIST" "MAKE-MONOM" "LEX>" "GRLEX>"
|
---|
| 87 | "GREVLEX>" "REVLEX>" "INVLEX>" "ELIMINATION-ORDER"
|
---|
| 88 | "ELIMINATION-ORDER-1" "*PRIMARY-ELIMINATION-ORDER*"
|
---|
| 89 | "*SECONDARY-ELIMINATION-ORDER*" "*ELIMINATION-ORDER*"
|
---|
| 90 | "INFIX-PRINT"
|
---|
| 91 | ))
|
---|