
(/VERSIONCHECK 2) 

(DEFPARAMETER |XPolynomialsCat;CAT| 'NIL) 

(DEFPARAMETER |XPolynomialsCat;AL| 'NIL) 

(DEFUN |XPolynomialsCat| (&REST #0=#:G1817)
  (LET (#1=#:G1818)
    (COND
      ((SETQ #1#
             (|assoc| #2=(|devaluateList| #0#) |XPolynomialsCat;AL|))
       (CDR #1#))
      (T (SETQ |XPolynomialsCat;AL|
               (|cons5| (CONS #2#
                              (SETQ #1#
                                    (APPLY #'|XPolynomialsCat;| #0#)))
                        |XPolynomialsCat;AL|))
         #1#)))) 

(DEFUN |XPolynomialsCat;| (|t#1| |t#2|)
  (PROG (#0=#:G1816)
    (RETURN
      (PROG1 (LETT #0#
                   (|sublisV|
                       (PAIR '(|t#1| |t#2|)
                             (LIST (|devaluate| |t#1|)
                                   (|devaluate| |t#2|)))
                       (COND
                         (|XPolynomialsCat;CAT|)
                         ('T
                          (LETT |XPolynomialsCat;CAT|
                                (|Join| (|XFreeAlgebra| '|t#1| '|t#2|)
                                        (|mkCategory| '|domain|
                                         '(((|maxdeg|
                                             ((|OrderedFreeMonoid|
                                               |t#1|)
                                              $))
                                            T)
                                           ((|degree|
                                             ((|NonNegativeInteger|) $))
                                            T)
                                           ((|trunc|
                                             ($ $
                                              (|NonNegativeInteger|)))
                                            T))
                                         NIL
                                         '((|NonNegativeInteger|)
                                           (|OrderedFreeMonoid| |t#1|))
                                         NIL))
                                . #1=(|XPolynomialsCat|))))) . #1#)
        (SETELT #0# 0
                (LIST '|XPolynomialsCat| (|devaluate| |t#1|)
                      (|devaluate| |t#2|))))))) 
