close Warning: Can't synchronize with repository "(default)" (The repository directory has changed, you should resynchronize the repository with: trac-admin $ENV repository resync '(default)'). Look in the Trac log for more information.

Changeset 426 for branches


Ignore:
Timestamp:
2015-06-06T19:39:44-07:00 (10 years ago)
Author:
Marek Rychlik
Message:

* empty log message *

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/f4grobner/order.lisp

    r417 r426  
    6464
    6565
    66 ;; total degree, ties broken by reverse lexicographic
    67 (defun grevlex> (p q &optional (start 0) (end (monom-dimension  p)))
    68   "Return T if P>Q with respect to graded reverse lexicographic order,
    69 NIL otherwise. The second returned value is T if P=Q, otherwise it is NIL."
    70   (declare (type monom p q) (type fixnum start end))
    71   (let ((d1 (monom-total-degree p start end))
    72         (d2 (monom-total-degree q start end)))
    73     (cond
    74      ((> d1 d2) (values t nil))
    75      ((< d1 d2) (values nil nil))
    76      (t
    77       (revlex> p q start end)))))
    78 
    79 
    8066;; reverse lexicographic
    8167(defun revlex> (p q &optional (start 0) (end (monom-dimension  p)))
     
    9682
    9783
     84;; total degree, ties broken by reverse lexicographic
     85(defun grevlex> (p q &optional (start 0) (end (monom-dimension  p)))
     86  "Return T if P>Q with respect to graded reverse lexicographic order,
     87NIL otherwise. The second returned value is T if P=Q, otherwise it is NIL."
     88  (declare (type monom p q) (type fixnum start end))
     89  (let ((d1 (monom-total-degree p start end))
     90        (d2 (monom-total-degree q start end)))
     91    (cond
     92     ((> d1 d2) (values t nil))
     93     ((< d1 d2) (values nil nil))
     94     (t
     95      (revlex> p q start end)))))
     96
    9897(defun invlex> (p q &optional (start 0) (end (monom-dimension  p)))
    9998  "Return T if P>Q with respect to inverse lexicographic order, NIL otherwise
Note: See TracChangeset for help on using the changeset viewer.