
(/VERSIONCHECK 2) 

(DEFPARAMETER |PermutationCategory;CAT| 'NIL) 

(DEFPARAMETER |PermutationCategory;AL| 'NIL) 

(DEFUN |PermutationCategory| (#0=#:G1816)
  (LET (#1=#:G1817)
    (COND
      ((SETQ #1#
             (|assoc| #2=(|devaluate| #0#) |PermutationCategory;AL|))
       (CDR #1#))
      (T (SETQ |PermutationCategory;AL|
               (|cons5| (CONS #2#
                              (SETQ #1# (|PermutationCategory;| #0#)))
                        |PermutationCategory;AL|))
         #1#)))) 

(DEFUN |PermutationCategory;| (|t#1|)
  (PROG (#0=#:G1815)
    (RETURN
      (PROG1 (LETT #0#
                   (|sublisV|
                       (PAIR '(|t#1|) (LIST (|devaluate| |t#1|)))
                       (COND
                         (|PermutationCategory;CAT|)
                         ('T
                          (LETT |PermutationCategory;CAT|
                                (|Join| (|Group|)
                                        (|mkCategory| '|domain|
                                         '(((|cycle|
                                             ($ (|List| |t#1|)))
                                            T)
                                           ((|cycles|
                                             ($
                                              (|List| (|List| |t#1|))))
                                            T)
                                           ((|eval| (|t#1| $ |t#1|)) T)
                                           ((|elt| (|t#1| $ |t#1|)) T)
                                           ((|orbit|
                                             ((|Set| |t#1|) $ |t#1|))
                                            T)
                                           ((< ((|Boolean|) $ $)) T))
                                         '(((|OrderedSet|)
                                            (|has| |t#1|
                                             (|OrderedSet|)))
                                           ((|OrderedSet|)
                                            (|has| |t#1| (|Finite|))))
                                         '((|Boolean|) (|Set| |t#1|)
                                           (|List| (|List| |t#1|))
                                           (|List| |t#1|))
                                         NIL))
                                . #1=(|PermutationCategory|))))) . #1#)
        (SETELT #0# 0
                (LIST '|PermutationCategory| (|devaluate| |t#1|))))))) 
