
(/VERSIONCHECK 2) 

(DEFUN |LIMITPS;noX?| (|fcn| |x| $)
  (COND ((SPADCALL |x| (SPADCALL |fcn| (QREFELT $ 11)) (QREFELT $ 14)) 'NIL)
        ('T 'T))) 

(DEFUN |LIMITPS;constant?| (|fcn| $) (NULL (SPADCALL |fcn| (QREFELT $ 11)))) 

(DEFUN |LIMITPS;firstNonLogPtr| (|fcn| |x| $)
  (PROG (|list| #1=#:G1915 |ker|)
    (RETURN
     (SEQ
      (EXIT
       (SEQ
        (LETT |list| (SPADCALL |fcn| (QREFELT $ 16))
              . #2=(|LIMITPS;firstNonLogPtr|))
        (SEQ G190 (COND ((NULL (COND ((NULL |list|) 'NIL) ('T 'T))) (GO G191)))
             (SEQ (LETT |ker| (|SPADfirst| |list|) . #2#)
                  (COND
                   ((NULL
                     (SPADCALL |ker| (SPADCALL "log" (QREFELT $ 18))
                               (QREFELT $ 20)))
                    (COND
                     ((SPADCALL |x|
                                (SPADCALL (SPADCALL |ker| (QREFELT $ 22))
                                          (QREFELT $ 11))
                                (QREFELT $ 14))
                      (COND
                       ((NULL (EQUAL |x| (SPADCALL |ker| (QREFELT $ 23))))
                        (EXIT (PROGN (LETT #1# |list| . #2#) (GO #1#)))))))))
                  (EXIT (LETT |list| (CDR |list|) . #2#)))
             NIL (GO G190) G191 (EXIT NIL))
        (EXIT NIL)))
      #1# (EXIT #1#))))) 

(DEFUN |LIMITPS;finiteValueAtInfinity?| (|ker| $)
  (COND
   ((OR (SPADCALL |ker| (SPADCALL "erf" (QREFELT $ 18)) (QREFELT $ 20))
        (OR (SPADCALL |ker| (SPADCALL "sech" (QREFELT $ 18)) (QREFELT $ 20))
            (OR
             (SPADCALL |ker| (SPADCALL "csch" (QREFELT $ 18)) (QREFELT $ 20))
             (OR
              (SPADCALL |ker| (SPADCALL "tanh" (QREFELT $ 18)) (QREFELT $ 20))
              (OR
               (SPADCALL |ker| (SPADCALL "coth" (QREFELT $ 18)) (QREFELT $ 20))
               (OR
                (SPADCALL |ker| (SPADCALL "atan" (QREFELT $ 18))
                          (QREFELT $ 20))
                (OR
                 (SPADCALL |ker| (SPADCALL "acot" (QREFELT $ 18))
                           (QREFELT $ 20))
                 (OR
                  (SPADCALL |ker| (SPADCALL "asec" (QREFELT $ 18))
                            (QREFELT $ 20))
                  (OR
                   (SPADCALL |ker| (SPADCALL "acsc" (QREFELT $ 18))
                             (QREFELT $ 20))
                   (OR
                    (SPADCALL |ker| (SPADCALL "acsch" (QREFELT $ 18))
                              (QREFELT $ 20))
                    (SPADCALL |ker| (SPADCALL "acoth" (QREFELT $ 18))
                              (QREFELT $ 20))))))))))))
    'T)
   ('T 'NIL))) 

(DEFUN |LIMITPS;knownValueAtInfinity?| (|ker| $)
  (COND
   ((OR (SPADCALL |ker| (SPADCALL "exp" (QREFELT $ 18)) (QREFELT $ 20))
        (OR (SPADCALL |ker| (SPADCALL "sinh" (QREFELT $ 18)) (QREFELT $ 20))
            (SPADCALL |ker| (SPADCALL "cosh" (QREFELT $ 18)) (QREFELT $ 20))))
    'T)
   ('T 'NIL))) 

(DEFUN |LIMITPS;leftOrRight| (|fcn| |x| |limVal| $)
  (PROG (|inf| |val| |value|)
    (RETURN
     (SEQ
      (LETT |value|
            (|LIMITPS;limitPlus|
             (SPADCALL (SPADCALL |fcn| |limVal| (QREFELT $ 24)) (QREFELT $ 25))
             |x| $)
            . #1=(|LIMITPS;leftOrRight|))
      (EXIT
       (COND ((QEQCAR |value| 1) 0)
             (#2='T
              (SEQ
               (LETT |inf|
                     (SPADCALL (LETT |val| (QCDR |value|) . #1#)
                               (QREFELT $ 28))
                     . #1#)
               (EXIT
                (COND ((EQL |inf| 0) (|error| "limit package: internal error"))
                      (#2# |inf|))))))))))) 

(DEFUN |LIMITPS;specialLimit| (|fcn| |x| $)
  (PROG (#1=#:G1955 |den| |num| |finVal| |valu| |val| |fval| #2=#:G1958 |k|
         |xkers| #3=#:G1957 #4=#:G1956)
    (RETURN
     (SEQ
      (EXIT
       (SEQ
        (LETT |xkers|
              (PROGN
               (LETT #4# NIL . #5=(|LIMITPS;specialLimit|))
               (SEQ (LETT |k| NIL . #5#)
                    (LETT #3# (SPADCALL |fcn| (QREFELT $ 16)) . #5#) G190
                    (COND
                     ((OR (ATOM #3#) (PROGN (LETT |k| (CAR #3#) . #5#) NIL))
                      #6=(GO G191)))
                    (SEQ
                     (EXIT
                      (COND
                       ((SPADCALL |x|
                                  (SPADCALL (SPADCALL |k| (QREFELT $ 22))
                                            (QREFELT $ 11))
                                  (QREFELT $ 14))
                        (LETT #4# (CONS |k| #4#) . #5#)))))
                    (LETT #3# (CDR #3#) . #5#) #7=(GO G190) G191
                    (EXIT (NREVERSE0 #4#))))
              . #5#)
        (EXIT
         (COND ((EQL (LENGTH |xkers|) 1) (|LIMITPS;specialLimit1| |fcn| |x| $))
               ('T
                (SEQ (LETT |num| (SPADCALL |fcn| (QREFELT $ 31)) . #5#)
                     (LETT |den| (SPADCALL |fcn| (QREFELT $ 32)) . #5#)
                     (SEQ (LETT |k| NIL . #5#) (LETT #2# |xkers| . #5#) G190
                          (COND
                           ((OR (ATOM #2#)
                                (PROGN (LETT |k| (CAR #2#) . #5#) NIL))
                            #6#))
                          (SEQ
                           (LETT |fval|
                                 (|LIMITPS;limitPlus|
                                  (SPADCALL |k| (QREFELT $ 22)) |x| $)
                                 . #5#)
                           (EXIT
                            (COND
                             ((OR (QEQCAR |fval| 1)
                                  (NULL
                                   (EQL
                                    (SPADCALL (LETT |val| (QCDR |fval|) . #5#)
                                              (QREFELT $ 28))
                                    0)))
                              (PROGN
                               (LETT #1#
                                     (|LIMITPS;specialLimitNormalize| |fcn| |x|
                                      $)
                                     . #5#)
                               (GO #1#)))
                             ('T
                              (SEQ
                               (LETT |valu| (SPADCALL |val| (QREFELT $ 34))
                                     . #5#)
                               (EXIT
                                (COND
                                 ((QEQCAR |valu| 1)
                                  (PROGN
                                   (LETT #1#
                                         (|LIMITPS;specialLimitNormalize| |fcn|
                                          |x| $)
                                         . #5#)
                                   (GO #1#)))
                                 ('T
                                  (SEQ (LETT |finVal| (QCDR |valu|) . #5#)
                                       (LETT |num|
                                             (SPADCALL |num| |k| |finVal|
                                                       (QREFELT $ 35))
                                             . #5#)
                                       (LETT |den|
                                             (SPADCALL |den| |k| |finVal|
                                                       (QREFELT $ 35))
                                             . #5#)
                                       (EXIT
                                        (COND
                                         ((SPADCALL |den| (|spadConstant| $ 8)
                                                    (QREFELT $ 36))
                                          (PROGN
                                           (LETT #1#
                                                 (|LIMITPS;specialLimitNormalize|
                                                  |fcn| |x| $)
                                                 . #5#)
                                           (GO #1#))))))))))))))
                          (LETT #2# (CDR #2#) . #5#) #7# G191 (EXIT NIL))
                     (EXIT
                      (CONS 0
                            (SPADCALL (SPADCALL |num| |den| (QREFELT $ 37))
                                      (QREFELT $ 38))))))))))
      #1# (EXIT #1#))))) 

(DEFUN |LIMITPS;specialLimitNormalize| (|fcn| |x| $)
  (PROG (|lim| |limm| |limVal| |expKerLim| |cc| |eq| |vv| |fval| |expKer|
         |expKers| #1=#:G1982 |k| #2=#:G1981 |xkers| #3=#:G1980 #4=#:G1979
         |nfcn|)
    (RETURN
     (SEQ
      (LETT |nfcn| (SPADCALL |fcn| (QREFELT $ 40))
            . #5=(|LIMITPS;specialLimitNormalize|))
      (EXIT
       (COND
        ((SPADCALL |fcn| |nfcn| (QREFELT $ 36))
         (SEQ
          (LETT |xkers|
                (PROGN
                 (LETT #4# NIL . #5#)
                 (SEQ (LETT |k| NIL . #5#)
                      (LETT #3# (SPADCALL |fcn| (QREFELT $ 41)) . #5#) G190
                      (COND
                       ((OR (ATOM #3#) (PROGN (LETT |k| (CAR #3#) . #5#) NIL))
                        #6=(GO G191)))
                      (SEQ
                       (EXIT
                        (COND
                         ((SPADCALL |x|
                                    (SPADCALL (SPADCALL |k| (QREFELT $ 22))
                                              (QREFELT $ 11))
                                    (QREFELT $ 14))
                          (LETT #4# (CONS |k| #4#) . #5#)))))
                      (LETT #3# (CDR #3#) . #5#) #7=(GO G190) G191
                      (EXIT (NREVERSE0 #4#))))
                . #5#)
          (COND ((NULL (EQL (LENGTH |xkers|) 2)) (EXIT (CONS 1 "failed"))))
          (LETT |expKers|
                (PROGN
                 (LETT #2# NIL . #5#)
                 (SEQ (LETT |k| NIL . #5#) (LETT #1# |xkers| . #5#) G190
                      (COND
                       ((OR (ATOM #1#) (PROGN (LETT |k| (CAR #1#) . #5#) NIL))
                        #6#))
                      (SEQ
                       (EXIT
                        (COND
                         ((SPADCALL |k| (SPADCALL "exp" (QREFELT $ 18))
                                    (QREFELT $ 20))
                          (LETT #2# (CONS |k| #2#) . #5#)))))
                      (LETT #1# (CDR #1#) . #5#) #7# G191
                      (EXIT (NREVERSE0 #2#))))
                . #5#)
          (COND ((NULL (EQL (LENGTH |expKers|) 1)) (EXIT (CONS 1 "failed"))))
          (LETT |expKer| (|SPADfirst| |expKers|) . #5#)
          (LETT |fval|
                (|LIMITPS;limitPlus| (SPADCALL |expKer| (QREFELT $ 22)) |x| $)
                . #5#)
          (EXIT
           (COND ((QEQCAR |fval| 1) (CONS 1 "failed"))
                 (#8='T
                  (SEQ (LETT |vv| (SPADCALL (QREFELT $ 42)) . #5#)
                       (LETT |eq|
                             (SPADCALL (SPADCALL |expKer| (QREFELT $ 22))
                                       (SPADCALL |vv| (QREFELT $ 43))
                                       (QREFELT $ 45))
                             . #5#)
                       (LETT |cc| (SPADCALL |fcn| |eq| (QREFELT $ 47)) . #5#)
                       (LETT |expKerLim| (QCDR |fval|) . #5#)
                       (LETT |limVal|
                             (|LIMITPS;locallimit| |cc| |vv| |expKerLim| $)
                             . #5#)
                       (EXIT
                        (COND
                         ((OR (QEQCAR |limVal| 2) (NULL (QEQCAR |limVal| 0)))
                          (CONS 1 "failed"))
                         ('T
                          (SEQ (LETT |limm| (QCDR |limVal|) . #5#)
                               (LETT |lim| (SPADCALL |limm| (QREFELT $ 34))
                                     . #5#)
                               (EXIT
                                (COND ((QEQCAR |lim| 1) (CONS 1 "failed"))
                                      (#8#
                                       (|LIMITPS;limitPlus| (QCDR |lim|) |x|
                                        $))))))))))))))
        (#8# (|LIMITPS;limitPlus| |nfcn| |x| $)))))))) 

(DEFUN |LIMITPS;specialLimit1| (|fcn| |x| $)
  (PROG (|limVal| |argLim| |lim| |cc| |eq| |vv| |ker| |xkers| #1=#:G1998 |k|
         #2=#:G1997)
    (RETURN
     (SEQ
      (LETT |xkers|
            (PROGN
             (LETT #2# NIL . #3=(|LIMITPS;specialLimit1|))
             (SEQ (LETT |k| NIL . #3#)
                  (LETT #1# (SPADCALL |fcn| (QREFELT $ 16)) . #3#) G190
                  (COND
                   ((OR (ATOM #1#) (PROGN (LETT |k| (CAR #1#) . #3#) NIL))
                    (GO G191)))
                  (SEQ
                   (EXIT
                    (COND
                     ((SPADCALL |x|
                                (SPADCALL (SPADCALL |k| (QREFELT $ 22))
                                          (QREFELT $ 11))
                                (QREFELT $ 14))
                      (LETT #2# (CONS |k| #2#) . #3#)))))
                  (LETT #1# (CDR #1#) . #3#) (GO G190) G191
                  (EXIT (NREVERSE0 #2#))))
            . #3#)
      (COND ((NULL (EQL (LENGTH |xkers|) 1)) (EXIT (CONS 1 "failed"))))
      (LETT |ker| (|SPADfirst| |xkers|) . #3#)
      (LETT |vv| (SPADCALL (QREFELT $ 42)) . #3#)
      (LETT |eq|
            (SPADCALL (SPADCALL |ker| (QREFELT $ 22))
                      (SPADCALL |vv| (QREFELT $ 43)) (QREFELT $ 45))
            . #3#)
      (LETT |cc| (SPADCALL |fcn| |eq| (QREFELT $ 47)) . #3#)
      (EXIT
       (COND
        ((SPADCALL |x| (SPADCALL |cc| (QREFELT $ 11)) (QREFELT $ 14))
         (CONS 1 "failed"))
        (#4='T
         (SEQ (LETT |lim| (|LIMITPS;specialLimitKernel| |ker| |x| $) . #3#)
              (EXIT
               (COND ((QEQCAR |lim| 1) |lim|)
                     (#4#
                      (SEQ (LETT |argLim| (QCDR |lim|) . #3#)
                           (LETT |limVal|
                                 (|LIMITPS;locallimit| |cc| |vv| |argLim| $)
                                 . #3#)
                           (EXIT
                            (COND
                             ((OR (QEQCAR |limVal| 2)
                                  (NULL (QEQCAR |limVal| 0)))
                              (CONS 1 "failed"))
                             ('T (CONS 0 (QCDR |limVal|))))))))))))))))) 

(DEFUN |LIMITPS;specialLimitKernel| (|ker| |x| $)
  (PROG (|val| |kerValue| |inf| |f| |var| |lim| |limm| |arg| |args| |argLim|
         #1=#:G2052 |li| #2=#:G2004)
    (RETURN
     (SEQ
      (EXIT
       (COND
        ((SPADCALL |ker| (SPADCALL "log" (QREFELT $ 18)) (QREFELT $ 20))
         (SEQ
          (LETT |args| (SPADCALL |ker| (QREFELT $ 49))
                . #3=(|LIMITPS;specialLimitKernel|))
          (EXIT
           (COND
            ((OR (NULL |args|) (NULL (NULL (CDR |args|)))) (CONS 1 "failed"))
            ('T
             (SEQ (LETT |arg| (|SPADfirst| |args|) . #3#)
                  (LETT |limm| (|LIMITPS;limitPlus| |arg| |x| $) . #3#)
                  (EXIT
                   (COND ((QEQCAR |limm| 1) (CONS 1 "failed"))
                         (#4='T
                          (SEQ (LETT |lim| (QCDR |limm|) . #3#)
                               (EXIT
                                (COND
                                 ((EQL
                                   (LETT |inf| (SPADCALL |lim| (QREFELT $ 28))
                                         . #3#)
                                   -1)
                                  (CONS 1 "failed"))
                                 (#4#
                                  (LETT |argLim|
                                        (CONS 0
                                              (COND ((EQL |inf| 1) |lim|)
                                                    (#4#
                                                     (SEQ
                                                      (LETT |li|
                                                            (PROG2
                                                                (LETT #2#
                                                                      (SPADCALL
                                                                       |lim|
                                                                       (QREFELT
                                                                        $ 34))
                                                                      . #3#)
                                                                (QCDR #2#)
                                                              (|check-union|
                                                               (QEQCAR #2# 0)
                                                               (QREFELT $ 7)
                                                               #2#))
                                                            . #3#)
                                                      (EXIT
                                                       (COND
                                                        ((SPADCALL |li|
                                                                   (|spadConstant|
                                                                    $ 8)
                                                                   (QREFELT $
                                                                            36))
                                                         (COND
                                                          ((EQL
                                                            (|LIMITPS;leftOrRight|
                                                             |arg| |x|
                                                             (|spadConstant| $
                                                                             8)
                                                             $)
                                                            1)
                                                           (SPADCALL
                                                            (QREFELT $ 52)))
                                                          (#4#
                                                           (PROGN
                                                            (LETT #1#
                                                                  (CONS 1
                                                                        "failed")
                                                                  . #3#)
                                                            (GO #1#)))))
                                                        (#4#
                                                         (SPADCALL
                                                          (SPADCALL |li|
                                                                    (QREFELT $
                                                                             53))
                                                          (QREFELT $
                                                                   38)))))))))
                                        . #3#))))))))))))))
        (#4#
         (SEQ (LETT |args| (SPADCALL |ker| (QREFELT $ 49)) . #3#)
              (EXIT
               (COND
                ((OR (NULL |args|) (NULL (NULL (CDR |args|))))
                 (CONS 1 "failed"))
                ('T
                 (SEQ (LETT |arg| (|SPADfirst| |args|) . #3#)
                      (LETT |limm| (|LIMITPS;limitPlus| |arg| |x| $) . #3#)
                      (EXIT
                       (COND ((QEQCAR |limm| 1) (CONS 1 "failed"))
                             (#4#
                              (SEQ (LETT |lim| (QCDR |limm|) . #3#)
                                   (LETT |f|
                                         (SPADCALL
                                          (SPADCALL |ker| (QREFELT $ 55))
                                          (SPADCALL
                                           (LETT |var|
                                                 (SPADCALL (QREFELT $ 42))
                                                 . #3#)
                                           (QREFELT $ 43))
                                          (QREFELT $ 56))
                                         . #3#)
                                   (LETT |inf| (SPADCALL |lim| (QREFELT $ 28))
                                         . #3#)
                                   (EXIT
                                    (COND
                                     ((EQL |inf| 0)
                                      (COND
                                       ((SPADCALL |ker|
                                                  (SPADCALL "erf"
                                                            (QREFELT $ 18))
                                                  (QREFELT $ 20))
                                        (CONS 0
                                              (SPADCALL
                                               (SPADCALL
                                                (SPADCALL |lim| (QREFELT $ 57))
                                                (QREFELT $ 59))
                                               (QREFELT $ 38))))
                                       (#4#
                                        (SEQ
                                         (LETT |kerValue|
                                               (|LIMITPS;locallimit| |f| |var|
                                                |lim| $)
                                               . #3#)
                                         (EXIT
                                          (COND
                                           ((OR (QEQCAR |kerValue| 2)
                                                (NULL (QEQCAR |kerValue| 0)))
                                            (CONS 1 "failed"))
                                           ('T
                                            (CONS 0 (QCDR |kerValue|)))))))))
                                     ((EQL |inf| 1)
                                      (COND
                                       ((|LIMITPS;finiteValueAtInfinity?| |ker|
                                         $)
                                        (SEQ
                                         (LETT |val|
                                               (COND
                                                ((SPADCALL |ker|
                                                           (SPADCALL "erf"
                                                                     (QREFELT $
                                                                              18))
                                                           (QREFELT $ 20))
                                                 (|spadConstant| $ 50))
                                                ((OR
                                                  (SPADCALL |ker|
                                                            (SPADCALL "sech"
                                                                      (QREFELT
                                                                       $ 18))
                                                            (QREFELT $ 20))
                                                  (OR
                                                   (SPADCALL |ker|
                                                             (SPADCALL "csch"
                                                                       (QREFELT
                                                                        $ 18))
                                                             (QREFELT $ 20))
                                                   (OR
                                                    (SPADCALL |ker|
                                                              (SPADCALL "tanh"
                                                                        (QREFELT
                                                                         $ 18))
                                                              (QREFELT $ 20))
                                                    (SPADCALL |ker|
                                                              (SPADCALL "coth"
                                                                        (QREFELT
                                                                         $ 18))
                                                              (QREFELT $
                                                                       20)))))
                                                 (|spadConstant| $ 8))
                                                ((SPADCALL |ker|
                                                           (SPADCALL "atan"
                                                                     (QREFELT $
                                                                              18))
                                                           (QREFELT $ 20))
                                                 (SPADCALL
                                                  (SPADCALL (QREFELT $ 60))
                                                  (SPADCALL 2 (QREFELT $ 62))
                                                  (QREFELT $ 37)))
                                                ((SPADCALL |ker|
                                                           (SPADCALL "acot"
                                                                     (QREFELT $
                                                                              18))
                                                           (QREFELT $ 20))
                                                 (|spadConstant| $ 8))
                                                ((SPADCALL |ker|
                                                           (SPADCALL "asec"
                                                                     (QREFELT $
                                                                              18))
                                                           (QREFELT $ 20))
                                                 (SPADCALL
                                                  (SPADCALL (QREFELT $ 60))
                                                  (SPADCALL 2 (QREFELT $ 62))
                                                  (QREFELT $ 37)))
                                                ((OR
                                                  (SPADCALL |ker|
                                                            (SPADCALL "acsc"
                                                                      (QREFELT
                                                                       $ 18))
                                                            (QREFELT $ 20))
                                                  (OR
                                                   (SPADCALL |ker|
                                                             (SPADCALL "acsch"
                                                                       (QREFELT
                                                                        $ 18))
                                                             (QREFELT $ 20))
                                                   #4#))
                                                 (|spadConstant| $ 8)))
                                               . #3#)
                                         (EXIT
                                          (CONS 0
                                                (SPADCALL |val|
                                                          (QREFELT $ 38))))))
                                       ((|LIMITPS;knownValueAtInfinity?| |ker|
                                         $)
                                        (CONS 0 |lim|))
                                       (#4# (CONS 1 "failed"))))
                                     (#4#
                                      (COND
                                       ((|LIMITPS;finiteValueAtInfinity?| |ker|
                                         $)
                                        (SEQ
                                         (LETT |val|
                                               (COND
                                                ((SPADCALL |ker|
                                                           (SPADCALL "erf"
                                                                     (QREFELT $
                                                                              18))
                                                           (QREFELT $ 20))
                                                 (SPADCALL
                                                  (|spadConstant| $ 50)
                                                  (QREFELT $ 63)))
                                                ((OR
                                                  (SPADCALL |ker|
                                                            (SPADCALL "sech"
                                                                      (QREFELT
                                                                       $ 18))
                                                            (QREFELT $ 20))
                                                  (OR
                                                   (SPADCALL |ker|
                                                             (SPADCALL "csch"
                                                                       (QREFELT
                                                                        $ 18))
                                                             (QREFELT $ 20))
                                                   (OR
                                                    (SPADCALL |ker|
                                                              (SPADCALL "tanh"
                                                                        (QREFELT
                                                                         $ 18))
                                                              (QREFELT $ 20))
                                                    (SPADCALL |ker|
                                                              (SPADCALL "coth"
                                                                        (QREFELT
                                                                         $ 18))
                                                              (QREFELT $
                                                                       20)))))
                                                 (|spadConstant| $ 8))
                                                ((SPADCALL |ker|
                                                           (SPADCALL "atan"
                                                                     (QREFELT $
                                                                              18))
                                                           (QREFELT $ 20))
                                                 (SPADCALL
                                                  (SPADCALL
                                                   (SPADCALL (QREFELT $ 60))
                                                   (SPADCALL 2 (QREFELT $ 62))
                                                   (QREFELT $ 37))
                                                  (QREFELT $ 63)))
                                                ((SPADCALL |ker|
                                                           (SPADCALL "acot"
                                                                     (QREFELT $
                                                                              18))
                                                           (QREFELT $ 20))
                                                 (SPADCALL (QREFELT $ 60)))
                                                ((SPADCALL |ker|
                                                           (SPADCALL "asec"
                                                                     (QREFELT $
                                                                              18))
                                                           (QREFELT $ 20))
                                                 (SPADCALL
                                                  (SPADCALL
                                                   (SPADCALL (QREFELT $ 60))
                                                   (SPADCALL 2 (QREFELT $ 62))
                                                   (QREFELT $ 37))
                                                  (QREFELT $ 63)))
                                                ((SPADCALL |ker|
                                                           (SPADCALL "acsc"
                                                                     (QREFELT $
                                                                              18))
                                                           (QREFELT $ 20))
                                                 (SPADCALL
                                                  (SPADCALL (QREFELT $ 60))
                                                  (QREFELT $ 63)))
                                                ((OR
                                                  (SPADCALL |ker|
                                                            (SPADCALL "acsch"
                                                                      (QREFELT
                                                                       $ 18))
                                                            (QREFELT $ 20))
                                                  #4#)
                                                 (|spadConstant| $ 8)))
                                               . #3#)
                                         (EXIT
                                          (CONS 0
                                                (SPADCALL |val|
                                                          (QREFELT $ 38))))))
                                       ((|LIMITPS;knownValueAtInfinity?| |ker|
                                         $)
                                        (COND
                                         ((SPADCALL |ker|
                                                    (SPADCALL "exp"
                                                              (QREFELT $ 18))
                                                    (QREFELT $ 20))
                                          (CONS 0
                                                (SPADCALL (|spadConstant| $ 8)
                                                          (QREFELT $ 38))))
                                         ((SPADCALL |ker|
                                                    (SPADCALL "sinh"
                                                              (QREFELT $ 18))
                                                    (QREFELT $ 20))
                                          (CONS 0 |lim|))
                                         ((SPADCALL |ker|
                                                    (SPADCALL "cosh"
                                                              (QREFELT $ 18))
                                                    (QREFELT $ 20))
                                          (CONS 0 (SPADCALL (QREFELT $ 64))))
                                         (#4# (CONS 1 "failed"))))
                                       (#4# (CONS 1 "failed"))))))))))))))))))
      #1# (EXIT #1#))))) 

(DEFUN |LIMITPS;logOnlyLimit| (|coef| |x| $)
  (PROG (|cc| |eq| |vv|)
    (RETURN
     (SEQ (LETT |vv| (SPADCALL (QREFELT $ 42)) . #1=(|LIMITPS;logOnlyLimit|))
          (LETT |eq|
                (SPADCALL
                 (SPADCALL (SPADCALL |x| (QREFELT $ 43)) (QREFELT $ 53))
                 (SPADCALL
                  (SPADCALL (SPADCALL |vv| (QREFELT $ 43)) (QREFELT $ 25))
                  (QREFELT $ 63))
                 (QREFELT $ 45))
                . #1#)
          (EXIT
           (COND
            ((SPADCALL |x|
                       (SPADCALL
                        (LETT |cc| (SPADCALL |coef| |eq| (QREFELT $ 47)) . #1#)
                        (QREFELT $ 11))
                       (QREFELT $ 14))
             (CONS 1 "failed"))
            ('T (|LIMITPS;limitPlus| |cc| |vv| $)))))))) 

(DEFUN |LIMITPS;locallimit| (|fcn| |x| |a| $)
  (PROG (|u| |n| |xK|)
    (RETURN
     (SEQ
      (LETT |xK| (SPADCALL (SPADCALL |x| (QREFELT $ 43)) (QREFELT $ 65))
            . #1=(|LIMITPS;locallimit|))
      (LETT |n| (SPADCALL |a| (QREFELT $ 28)) . #1#)
      (EXIT
       (COND
        ((EQL |n| 0)
         (|LIMITPS;realLimit|
          (|LIMITPS;localsubst| |fcn| |xK| 1 (SPADCALL |a| (QREFELT $ 57)) $)
          |x| $))
        (#2='T
         (SEQ
          (LETT |u|
                (|LIMITPS;limitPlus|
                 (SPADCALL |fcn| |xK|
                           (SPADCALL |n|
                                     (SPADCALL (SPADCALL |xK| (QREFELT $ 22))
                                               (QREFELT $ 25))
                                     (QREFELT $ 66))
                           (QREFELT $ 35))
                 |x| $)
                . #1#)
          (EXIT
           (COND ((QEQCAR |u| 1) (CONS 2 "failed"))
                 (#2# (CONS 0 (QCDR |u|))))))))))))) 

(DEFUN |LIMITPS;localsubst| (|fcn| |k| |n| |a| $)
  (SEQ
   (COND
    ((SPADCALL |a| (|spadConstant| $ 8) (QREFELT $ 36))
     (COND ((EQL |n| 1) (EXIT |fcn|)))))
   (EXIT
    (SPADCALL |fcn| |k|
              (SPADCALL
               (SPADCALL |n| (SPADCALL |k| (QREFELT $ 22)) (QREFELT $ 66)) |a|
               (QREFELT $ 67))
              (QREFELT $ 35))))) 

(DEFUN |LIMITPS;locallimitcomplex| (|fcn| |x| |a| $)
  (PROG (|g| |xK|)
    (RETURN
     (SEQ
      (LETT |xK| (SPADCALL (SPADCALL |x| (QREFELT $ 43)) (QREFELT $ 65))
            . #1=(|LIMITPS;locallimitcomplex|))
      (LETT |g| (SPADCALL |a| (QREFELT $ 69)) . #1#)
      (EXIT
       (COND
        ((QEQCAR |g| 0)
         (|LIMITPS;complLimit| (|LIMITPS;localsubst| |fcn| |xK| 1 (QCDR |g|) $)
          |x| $))
        ('T
         (|LIMITPS;complLimit|
          (SPADCALL |fcn| |xK|
                    (SPADCALL (SPADCALL |xK| (QREFELT $ 22)) (QREFELT $ 25))
                    (QREFELT $ 35))
          |x| $)))))))) 

(DEFUN |LIMITPS;limit;FEESU;15| (|fcn| |eq| |str| $)
  (PROG (|xK| |a| |x| |xx|)
    (RETURN
     (SEQ
      (LETT |xx| (SPADCALL (SPADCALL |eq| (QREFELT $ 70)) (QREFELT $ 72))
            . #1=(|LIMITPS;limit;FEESU;15|))
      (EXIT
       (COND
        ((QEQCAR |xx| 1) (|error| "limit:left hand side must be a variable"))
        ('T
         (SEQ (LETT |x| (QCDR |xx|) . #1#)
              (LETT |a| (SPADCALL |eq| (QREFELT $ 73)) . #1#)
              (LETT |xK|
                    (SPADCALL (SPADCALL |x| (QREFELT $ 43)) (QREFELT $ 65))
                    . #1#)
              (EXIT
               (|LIMITPS;limitPlus|
                (|LIMITPS;localsubst| |fcn| |xK|
                 (SPADCALL |str| (QREFELT $ 75)) |a| $)
                |x| $)))))))))) 

(DEFUN |LIMITPS;anyRootsOrAtrigs?| (|fcn| $)
  (PROG (#1=#:G2097 #2=#:G2104 #3=#:G2105 |kernel|)
    (RETURN
     (SEQ
      (EXIT
       (SEQ
        (SEQ (LETT |kernel| NIL . #4=(|LIMITPS;anyRootsOrAtrigs?|))
             (LETT #3# (SPADCALL |fcn| (QREFELT $ 41)) . #4#) G190
             (COND
              ((OR (ATOM #3#) (PROGN (LETT |kernel| (CAR #3#) . #4#) NIL))
               (GO G191)))
             (SEQ
              (EXIT
               (COND
                ((OR
                  (SPADCALL |kernel| (SPADCALL "nthRoot" (QREFELT $ 18))
                            (QREFELT $ 20))
                  (OR
                   (SPADCALL |kernel| (SPADCALL "asin" (QREFELT $ 18))
                             (QREFELT $ 20))
                   (OR
                    (SPADCALL |kernel| (SPADCALL "acos" (QREFELT $ 18))
                              (QREFELT $ 20))
                    (SPADCALL |kernel| (SPADCALL "asec" (QREFELT $ 18))
                              (QREFELT $ 20)))))
                 (PROGN (LETT #2# 'T . #4#) (GO #2#)))
                ('T
                 (SEQ
                  (EXIT
                   (COND
                    ((SPADCALL |kernel| (SPADCALL "acsc" (QREFELT $ 18))
                               (QREFELT $ 20))
                     (PROGN
                      (LETT #1# (PROGN (LETT #2# 'T . #4#) (GO #2#)) . #4#)
                      (GO #1#)))))
                  #1# (EXIT #1#))))))
             (LETT #3# (CDR #3#) . #4#) (GO G190) G191 (EXIT NIL))
        (EXIT 'NIL)))
      #2# (EXIT #2#))))) 

(DEFUN |LIMITPS;complLimit| (|fcn| |x| $)
  (PROG (|answer| |lim| #1=#:G2125 |uls| |lseries| |lpack| |upxs| |pseries|
         |ppack|)
    (RETURN
     (SEQ
      (EXIT
       (SEQ
        (LETT |lim|
              (COND
               ((|LIMITPS;anyRootsOrAtrigs?| |fcn| $)
                (SEQ
                 (LETT |ppack|
                       (|FunctionSpaceToUnivariatePowerSeries| (QREFELT $ 6)
                                                               (QREFELT $ 7)
                                                               (|Fraction|
                                                                (|Integer|))
                                                               (|UnivariatePuiseuxSeries|
                                                                (QREFELT $ 7)
                                                                |x|
                                                                (QREFELT $ 9))
                                                               (|ElementaryFunctionsUnivariatePuiseuxSeries|
                                                                (QREFELT $ 7)
                                                                (|UnivariateLaurentSeries|
                                                                 (QREFELT $ 7)
                                                                 |x|
                                                                 (QREFELT $ 9))
                                                                (|UnivariatePuiseuxSeries|
                                                                 (QREFELT $ 7)
                                                                 |x|
                                                                 (QREFELT $ 9))
                                                                (|ElementaryFunctionsUnivariateLaurentSeries|
                                                                 (QREFELT $ 7)
                                                                 (|UnivariateTaylorSeries|
                                                                  (QREFELT $ 7)
                                                                  |x|
                                                                  (QREFELT $
                                                                           9))
                                                                 (|UnivariateLaurentSeries|
                                                                  (QREFELT $ 7)
                                                                  |x|
                                                                  (QREFELT $
                                                                           9))))
                                                               |x|)
                       . #2=(|LIMITPS;complLimit|))
                 (LETT |pseries|
                       (SPADCALL |fcn| 'NIL "complex"
                                 (|compiledLookupCheck| '|exprToUPS|
                                                        (LIST
                                                         (LIST '|Union|
                                                               (LIST '|:|
                                                                     '|%series|
                                                                     (LIST
                                                                      '|UnivariatePuiseuxSeries|
                                                                      (|devaluate|
                                                                       (ELT $
                                                                            7))
                                                                      |x|
                                                                      (|devaluate|
                                                                       (ELT $
                                                                            9))))
                                                               (LIST '|:|
                                                                     '|%problem|
                                                                     (LIST
                                                                      '|Record|
                                                                      (LIST
                                                                       '|:|
                                                                       '|func|
                                                                       (LIST
                                                                        '|String|))
                                                                      (LIST
                                                                       '|:|
                                                                       '|prob|
                                                                       (LIST
                                                                        '|String|)))))
                                                         (|devaluate|
                                                          (ELT $ 7))
                                                         (LIST '|Boolean|)
                                                         (LIST '|String|))
                                                        |ppack|))
                       . #2#)
                 (EXIT
                  (COND
                   ((QEQCAR |pseries| 1)
                    (PROGN (LETT #1# (CONS 1 "failed") . #2#) (GO #1#)))
                   (#3='T
                    (SEQ
                     (COND
                      ((SPADCALL (LETT |upxs| (CDR |pseries|) . #2#)
                                 (|compiledLookupCheck| '|pole?|
                                                        (LIST (LIST '|Boolean|)
                                                              '$)
                                                        (|UnivariatePuiseuxSeries|
                                                         (ELT $ 7) |x|
                                                         (ELT $ 9))))
                       (LETT |upxs|
                             (SPADCALL (ELT $ 40) |upxs|
                                       (|compiledLookupCheck| '|map|
                                                              (LIST '$
                                                                    (LIST
                                                                     '|Mapping|
                                                                     (|devaluate|
                                                                      (ELT $
                                                                           7))
                                                                     (|devaluate|
                                                                      (ELT $
                                                                           7)))
                                                                    '$)
                                                              (|UnivariatePuiseuxSeries|
                                                               (ELT $ 7) |x|
                                                               (ELT $ 9))))
                             . #2#)))
                     (EXIT
                      (COND
                       ((SPADCALL |upxs|
                                  (|compiledLookupCheck| '|pole?|
                                                         (LIST
                                                          (LIST '|Boolean|) '$)
                                                         (|UnivariatePuiseuxSeries|
                                                          (ELT $ 7) |x|
                                                          (ELT $ 9))))
                        (PROGN
                         (LETT #1# (CONS 0 (SPADCALL (QREFELT $ 78))) . #2#)
                         (GO #1#)))
                       (#3#
                        (SPADCALL |upxs| (|spadConstant| $ 80)
                                  (|compiledLookupCheck| '|coefficient|
                                                         (LIST
                                                          (|devaluate|
                                                           (ELT $ 7))
                                                          '$
                                                          (LIST '|Fraction|
                                                                (LIST
                                                                 '|Integer|)))
                                                         (|UnivariatePuiseuxSeries|
                                                          (ELT $ 7) |x|
                                                          (ELT $ 9)))))))))))))
               (#3#
                (SEQ
                 (LETT |lpack|
                       (|FunctionSpaceToUnivariatePowerSeries| (QREFELT $ 6)
                                                               (QREFELT $ 7)
                                                               (|Integer|)
                                                               (|UnivariateLaurentSeries|
                                                                (QREFELT $ 7)
                                                                |x|
                                                                (QREFELT $ 9))
                                                               (|ElementaryFunctionsUnivariateLaurentSeries|
                                                                (QREFELT $ 7)
                                                                (|UnivariateTaylorSeries|
                                                                 (QREFELT $ 7)
                                                                 |x|
                                                                 (QREFELT $ 9))
                                                                (|UnivariateLaurentSeries|
                                                                 (QREFELT $ 7)
                                                                 |x|
                                                                 (QREFELT $
                                                                          9)))
                                                               |x|)
                       . #2#)
                 (LETT |lseries|
                       (SPADCALL |fcn| 'NIL "complex"
                                 (|compiledLookupCheck| '|exprToUPS|
                                                        (LIST
                                                         (LIST '|Union|
                                                               (LIST '|:|
                                                                     '|%series|
                                                                     (LIST
                                                                      '|UnivariateLaurentSeries|
                                                                      (|devaluate|
                                                                       (ELT $
                                                                            7))
                                                                      |x|
                                                                      (|devaluate|
                                                                       (ELT $
                                                                            9))))
                                                               (LIST '|:|
                                                                     '|%problem|
                                                                     (LIST
                                                                      '|Record|
                                                                      (LIST
                                                                       '|:|
                                                                       '|func|
                                                                       (LIST
                                                                        '|String|))
                                                                      (LIST
                                                                       '|:|
                                                                       '|prob|
                                                                       (LIST
                                                                        '|String|)))))
                                                         (|devaluate|
                                                          (ELT $ 7))
                                                         (LIST '|Boolean|)
                                                         (LIST '|String|))
                                                        |lpack|))
                       . #2#)
                 (EXIT
                  (COND
                   ((QEQCAR |lseries| 1)
                    (PROGN (LETT #1# (CONS 1 "failed") . #2#) (GO #1#)))
                   (#3#
                    (SEQ
                     (COND
                      ((SPADCALL (LETT |uls| (CDR |lseries|) . #2#)
                                 (|compiledLookupCheck| '|pole?|
                                                        (LIST (LIST '|Boolean|)
                                                              '$)
                                                        (|UnivariateLaurentSeries|
                                                         (ELT $ 7) |x|
                                                         (ELT $ 9))))
                       (LETT |uls|
                             (SPADCALL (ELT $ 40) |uls|
                                       (|compiledLookupCheck| '|map|
                                                              (LIST '$
                                                                    (LIST
                                                                     '|Mapping|
                                                                     (|devaluate|
                                                                      (ELT $
                                                                           7))
                                                                     (|devaluate|
                                                                      (ELT $
                                                                           7)))
                                                                    '$)
                                                              (|UnivariateLaurentSeries|
                                                               (ELT $ 7) |x|
                                                               (ELT $ 9))))
                             . #2#)))
                     (EXIT
                      (COND
                       ((SPADCALL |uls|
                                  (|compiledLookupCheck| '|pole?|
                                                         (LIST
                                                          (LIST '|Boolean|) '$)
                                                         (|UnivariateLaurentSeries|
                                                          (ELT $ 7) |x|
                                                          (ELT $ 9))))
                        (PROGN
                         (LETT #1# (CONS 0 (SPADCALL (QREFELT $ 78))) . #2#)
                         (GO #1#)))
                       (#3#
                        (SPADCALL |uls| 0
                                  (|compiledLookupCheck| '|coefficient|
                                                         (LIST
                                                          (|devaluate|
                                                           (ELT $ 7))
                                                          '$ (LIST '|Integer|))
                                                         (|UnivariateLaurentSeries|
                                                          (ELT $ 7) |x|
                                                          (ELT $
                                                               9))))))))))))))
              . #2#)
        (EXIT
         (COND
          ((SPADCALL |x| (SPADCALL |lim| (QREFELT $ 11)) (QREFELT $ 14))
           (COND
            ((SPADCALL |x|
                       (SPADCALL
                        (LETT |answer| (SPADCALL |lim| (QREFELT $ 40)) . #2#)
                        (QREFELT $ 11))
                       (QREFELT $ 14))
             (|error| "limit: can't evaluate limit"))
            (#3# (CONS 0 (SPADCALL |answer| (QREFELT $ 81))))))
          (#3# (CONS 0 (SPADCALL |lim| (QREFELT $ 81))))))))
      #1# (EXIT #1#))))) 

(DEFUN |LIMITPS;okProblem?| (|function| |problem| $)
  (COND
   ((OR (EQUAL |function| "log") (EQUAL |function| "nth root"))
    (COND ((EQUAL |problem| "series of non-zero order") 'T)
          (#1='T (EQUAL |problem| "negative leading coefficient"))))
   ('T
    (COND ((EQUAL |function| "atan") (EQUAL |problem| "branch problem"))
          ((EQUAL |function| "erf") (EQUAL |problem| "unknown kernel"))
          (#1# (EQUAL |problem| "essential singularity")))))) 

(DEFUN |LIMITPS;poleLimit| (|order| |coef| |x| $)
  (PROG (|rtLim| |s|)
    (RETURN
     (SEQ
      (COND
       ((NULL (SPADCALL |x| (SPADCALL |coef| (QREFELT $ 11)) (QREFELT $ 14)))
        (SEQ
         (LETT |s| (SPADCALL |coef| (QREFELT $ 84)) . #1=(|LIMITPS;poleLimit|))
         (EXIT
          (COND
           ((QEQCAR |s| 0)
            (SEQ
             (LETT |rtLim|
                   (SPADCALL (QCDR |s|) (SPADCALL (QREFELT $ 64))
                             (QREFELT $ 85))
                   . #1#)
             (EXIT
              (COND
               ((SPADCALL (SPADCALL |order| (QREFELT $ 86)) (QREFELT $ 87))
                (CONS 0 |rtLim|))
               ((SPADCALL (SPADCALL |order| (QREFELT $ 88)) (QREFELT $ 87))
                (CONS 1 (CONS (CONS 1 "failed") (CONS 0 |rtLim|))))
               (#2='T
                (CONS 1
                      (CONS (CONS 0 (SPADCALL |rtLim| (QREFELT $ 89)))
                            (CONS 0 |rtLim|))))))))
           (#2# (CONS 2 "failed"))))))
       ('T (|error| "limit: can't evaluate limit"))))))) 

(DEFUN |LIMITPS;poleLimitPlus| (|order| |coef| |x| $)
  (PROG (|tt| |t| |ss| |cclim| |lim| |clim| |s|)
    (RETURN
     (SEQ
      (COND
       ((NULL (SPADCALL |x| (SPADCALL |coef| (QREFELT $ 11)) (QREFELT $ 14)))
        (SEQ
         (LETT |s| (SPADCALL |coef| (QREFELT $ 84))
               . #1=(|LIMITPS;poleLimitPlus|))
         (EXIT
          (COND
           ((QEQCAR |s| 0)
            (CONS 0
                  (SPADCALL (QCDR |s|) (SPADCALL (QREFELT $ 64))
                            (QREFELT $ 85))))
           (#2='T (CONS 1 "failed"))))))
       ('T
        (SEQ (LETT |clim| (|LIMITPS;specialLimit| |coef| |x| $) . #1#)
             (EXIT
              (COND ((QEQCAR |clim| 1) (CONS 1 "failed"))
                    ((SPADCALL (LETT |lim| (QCDR |clim|) . #1#) (QREFELT $ 90))
                     (SEQ
                      (LETT |cclim|
                            (|LIMITPS;specialLimit|
                             (SPADCALL |coef| (QREFELT $ 25)) |x| $)
                            . #1#)
                      (EXIT
                       (COND ((QEQCAR |cclim| 1) (CONS 1 "failed"))
                             (#2#
                              (SEQ
                               (LETT |ss|
                                     (SPADCALL (QCDR |cclim|) (QREFELT $ 28))
                                     . #1#)
                               (EXIT
                                (COND
                                 ((ZEROP |ss|)
                                  (|error| "limit: internal error"))
                                 (#2#
                                  (CONS 0
                                        (SPADCALL |ss|
                                                  (SPADCALL (QREFELT $ 64))
                                                  (QREFELT $ 85))))))))))))
                    (#2#
                     (SEQ (LETT |t| (SPADCALL |lim| (QREFELT $ 28)) . #1#)
                          (EXIT
                           (COND
                            ((ZEROP |t|)
                             (SEQ
                              (LETT |tt| (SPADCALL |coef| (QREFELT $ 84))
                                    . #1#)
                              (EXIT
                               (COND
                                ((QEQCAR |tt| 0)
                                 (CONS 0
                                       (SPADCALL (QCDR |tt|)
                                                 (SPADCALL (QREFELT $ 64))
                                                 (QREFELT $ 85))))
                                (#2# (CONS 1 "failed"))))))
                            (#2#
                             (CONS 0
                                   (SPADCALL |t| (SPADCALL (QREFELT $ 64))
                                             (QREFELT $ 85))))))))))))))))) 

(DEFUN |LIMITPS;realLimit| (|fcn| |x| $)
  (PROG (|answer| |lim| #1=#:G2200 |cl| |ordl| |uls| |right| |left| |fcn0| |xK|
         |problem| |function| |trouble| |lseries| |lpack| |cp| |ordp| |upxs|
         |pseries| |ppack|)
    (RETURN
     (SEQ
      (EXIT
       (SEQ
        (LETT |lim|
              (COND
               ((|LIMITPS;anyRootsOrAtrigs?| |fcn| $)
                (SEQ
                 (LETT |ppack|
                       (|FunctionSpaceToUnivariatePowerSeries| (QREFELT $ 6)
                                                               (QREFELT $ 7)
                                                               (|Fraction|
                                                                (|Integer|))
                                                               (|UnivariatePuiseuxSeries|
                                                                (QREFELT $ 7)
                                                                |x|
                                                                (QREFELT $ 9))
                                                               (|ElementaryFunctionsUnivariatePuiseuxSeries|
                                                                (QREFELT $ 7)
                                                                (|UnivariateLaurentSeries|
                                                                 (QREFELT $ 7)
                                                                 |x|
                                                                 (QREFELT $ 9))
                                                                (|UnivariatePuiseuxSeries|
                                                                 (QREFELT $ 7)
                                                                 |x|
                                                                 (QREFELT $ 9))
                                                                (|ElementaryFunctionsUnivariateLaurentSeries|
                                                                 (QREFELT $ 7)
                                                                 (|UnivariateTaylorSeries|
                                                                  (QREFELT $ 7)
                                                                  |x|
                                                                  (QREFELT $
                                                                           9))
                                                                 (|UnivariateLaurentSeries|
                                                                  (QREFELT $ 7)
                                                                  |x|
                                                                  (QREFELT $
                                                                           9))))
                                                               |x|)
                       . #2=(|LIMITPS;realLimit|))
                 (LETT |pseries|
                       (SPADCALL |fcn| 'T "real: two sides"
                                 (|compiledLookupCheck| '|exprToUPS|
                                                        (LIST
                                                         (LIST '|Union|
                                                               (LIST '|:|
                                                                     '|%series|
                                                                     (LIST
                                                                      '|UnivariatePuiseuxSeries|
                                                                      (|devaluate|
                                                                       (ELT $
                                                                            7))
                                                                      |x|
                                                                      (|devaluate|
                                                                       (ELT $
                                                                            9))))
                                                               (LIST '|:|
                                                                     '|%problem|
                                                                     (LIST
                                                                      '|Record|
                                                                      (LIST
                                                                       '|:|
                                                                       '|func|
                                                                       (LIST
                                                                        '|String|))
                                                                      (LIST
                                                                       '|:|
                                                                       '|prob|
                                                                       (LIST
                                                                        '|String|)))))
                                                         (|devaluate|
                                                          (ELT $ 7))
                                                         (LIST '|Boolean|)
                                                         (LIST '|String|))
                                                        |ppack|))
                       . #2#)
                 (EXIT
                  (COND
                   ((QEQCAR |pseries| 1)
                    (SEQ (LETT |trouble| (CDR |pseries|) . #2#)
                         (LETT |function| (QCAR |trouble|) . #2#)
                         (LETT |problem| (QCDR |trouble|) . #2#)
                         (EXIT
                          (COND
                           ((|LIMITPS;okProblem?| |function| |problem| $)
                            (SEQ
                             (LETT |left|
                                   (SEQ
                                    (LETT |xK| (SPADCALL |x| (QREFELT $ 91))
                                          . #2#)
                                    (LETT |fcn0|
                                          (SPADCALL |fcn| |xK|
                                                    (SPADCALL
                                                     (SPADCALL |xK|
                                                               (QREFELT $ 22))
                                                     (QREFELT $ 63))
                                                    (QREFELT $ 35))
                                          . #2#)
                                    (EXIT (|LIMITPS;limitPlus| |fcn0| |x| $)))
                                   . #2#)
                             (LETT |right| (|LIMITPS;limitPlus| |fcn| |x| $)
                                   . #2#)
                             (COND
                              ((QEQCAR |left| 1)
                               (COND
                                ((QEQCAR |right| 1)
                                 (EXIT
                                  (PROGN
                                   (LETT #1# (CONS 2 "failed") . #2#)
                                   (GO #1#)))))))
                             (COND
                              ((QEQCAR |left| 0)
                               (COND
                                ((QEQCAR |right| 0)
                                 (COND
                                  ((SPADCALL (QCDR |left|) (QCDR |right|)
                                             (QREFELT $ 92))
                                   (EXIT
                                    (PROGN
                                     (LETT #1# (CONS 0 (QCDR |left|)) . #2#)
                                     (GO #1#)))))))))
                             (EXIT
                              (PROGN
                               (LETT #1# (CONS 1 (CONS |left| |right|)) . #2#)
                               (GO #1#)))))
                           (#3='T
                            (PROGN
                             (LETT #1# (CONS 2 "failed") . #2#)
                             (GO #1#)))))))
                   (#3#
                    (SEQ
                     (COND
                      ((SPADCALL (LETT |upxs| (CDR |pseries|) . #2#)
                                 (|compiledLookupCheck| '|pole?|
                                                        (LIST (LIST '|Boolean|)
                                                              '$)
                                                        (|UnivariatePuiseuxSeries|
                                                         (ELT $ 7) |x|
                                                         (ELT $ 9))))
                       (LETT |upxs|
                             (SPADCALL (ELT $ 40) |upxs|
                                       (|compiledLookupCheck| '|map|
                                                              (LIST '$
                                                                    (LIST
                                                                     '|Mapping|
                                                                     (|devaluate|
                                                                      (ELT $
                                                                           7))
                                                                     (|devaluate|
                                                                      (ELT $
                                                                           7)))
                                                                    '$)
                                                              (|UnivariatePuiseuxSeries|
                                                               (ELT $ 7) |x|
                                                               (ELT $ 9))))
                             . #2#)))
                     (EXIT
                      (COND
                       ((SPADCALL |upxs|
                                  (|compiledLookupCheck| '|pole?|
                                                         (LIST
                                                          (LIST '|Boolean|) '$)
                                                         (|UnivariatePuiseuxSeries|
                                                          (ELT $ 7) |x|
                                                          (ELT $ 9))))
                        (SEQ
                         (LETT |cp|
                               (SPADCALL |upxs|
                                         (LETT |ordp|
                                               (SPADCALL |upxs|
                                                         (|compiledLookupCheck|
                                                          '|order|
                                                          (LIST
                                                           (LIST '|Fraction|
                                                                 (LIST
                                                                  '|Integer|))
                                                           '$)
                                                          (|UnivariatePuiseuxSeries|
                                                           (ELT $ 7) |x|
                                                           (ELT $ 9))))
                                               . #2#)
                                         (|compiledLookupCheck| '|coefficient|
                                                                (LIST
                                                                 (|devaluate|
                                                                  (ELT $ 7))
                                                                 '$
                                                                 (LIST
                                                                  '|Fraction|
                                                                  (LIST
                                                                   '|Integer|)))
                                                                (|UnivariatePuiseuxSeries|
                                                                 (ELT $ 7) |x|
                                                                 (ELT $ 9))))
                               . #2#)
                         (EXIT
                          (PROGN
                           (LETT #1# (|LIMITPS;poleLimit| |ordp| |cp| |x| $)
                                 . #2#)
                           (GO #1#)))))
                       (#3#
                        (CONS 0
                              (SPADCALL |upxs| (|spadConstant| $ 80)
                                        (|compiledLookupCheck| '|coefficient|
                                                               (LIST
                                                                (|devaluate|
                                                                 (ELT $ 7))
                                                                '$
                                                                (LIST
                                                                 '|Fraction|
                                                                 (LIST
                                                                  '|Integer|)))
                                                               (|UnivariatePuiseuxSeries|
                                                                (ELT $ 7) |x|
                                                                (ELT $
                                                                     9))))))))))))))
               (#3#
                (SEQ
                 (LETT |lpack|
                       (|FunctionSpaceToUnivariatePowerSeries| (QREFELT $ 6)
                                                               (QREFELT $ 7)
                                                               (|Integer|)
                                                               (|UnivariateLaurentSeries|
                                                                (QREFELT $ 7)
                                                                |x|
                                                                (QREFELT $ 9))
                                                               (|ElementaryFunctionsUnivariateLaurentSeries|
                                                                (QREFELT $ 7)
                                                                (|UnivariateTaylorSeries|
                                                                 (QREFELT $ 7)
                                                                 |x|
                                                                 (QREFELT $ 9))
                                                                (|UnivariateLaurentSeries|
                                                                 (QREFELT $ 7)
                                                                 |x|
                                                                 (QREFELT $
                                                                          9)))
                                                               |x|)
                       . #2#)
                 (LETT |lseries|
                       (SPADCALL |fcn| 'T "real: two sides"
                                 (|compiledLookupCheck| '|exprToUPS|
                                                        (LIST
                                                         (LIST '|Union|
                                                               (LIST '|:|
                                                                     '|%series|
                                                                     (LIST
                                                                      '|UnivariateLaurentSeries|
                                                                      (|devaluate|
                                                                       (ELT $
                                                                            7))
                                                                      |x|
                                                                      (|devaluate|
                                                                       (ELT $
                                                                            9))))
                                                               (LIST '|:|
                                                                     '|%problem|
                                                                     (LIST
                                                                      '|Record|
                                                                      (LIST
                                                                       '|:|
                                                                       '|func|
                                                                       (LIST
                                                                        '|String|))
                                                                      (LIST
                                                                       '|:|
                                                                       '|prob|
                                                                       (LIST
                                                                        '|String|)))))
                                                         (|devaluate|
                                                          (ELT $ 7))
                                                         (LIST '|Boolean|)
                                                         (LIST '|String|))
                                                        |lpack|))
                       . #2#)
                 (EXIT
                  (COND
                   ((QEQCAR |lseries| 1)
                    (SEQ (LETT |trouble| (CDR |lseries|) . #2#)
                         (LETT |function| (QCAR |trouble|) . #2#)
                         (LETT |problem| (QCDR |trouble|) . #2#)
                         (EXIT
                          (COND
                           ((|LIMITPS;okProblem?| |function| |problem| $)
                            (SEQ
                             (LETT |left|
                                   (SEQ
                                    (LETT |xK| (SPADCALL |x| (QREFELT $ 91))
                                          . #2#)
                                    (LETT |fcn0|
                                          (SPADCALL |fcn| |xK|
                                                    (SPADCALL
                                                     (SPADCALL |xK|
                                                               (QREFELT $ 22))
                                                     (QREFELT $ 63))
                                                    (QREFELT $ 35))
                                          . #2#)
                                    (EXIT (|LIMITPS;limitPlus| |fcn0| |x| $)))
                                   . #2#)
                             (LETT |right| (|LIMITPS;limitPlus| |fcn| |x| $)
                                   . #2#)
                             (COND
                              ((QEQCAR |left| 1)
                               (COND
                                ((QEQCAR |right| 1)
                                 (EXIT
                                  (PROGN
                                   (LETT #1# (CONS 2 "failed") . #2#)
                                   (GO #1#)))))))
                             (COND
                              ((QEQCAR |left| 0)
                               (COND
                                ((QEQCAR |right| 0)
                                 (COND
                                  ((SPADCALL (QCDR |left|) (QCDR |right|)
                                             (QREFELT $ 92))
                                   (EXIT
                                    (PROGN
                                     (LETT #1# (CONS 0 (QCDR |left|)) . #2#)
                                     (GO #1#)))))))))
                             (EXIT
                              (PROGN
                               (LETT #1# (CONS 1 (CONS |left| |right|)) . #2#)
                               (GO #1#)))))
                           (#3#
                            (PROGN
                             (LETT #1# (CONS 2 "failed") . #2#)
                             (GO #1#)))))))
                   (#3#
                    (SEQ
                     (COND
                      ((SPADCALL (LETT |uls| (CDR |lseries|) . #2#)
                                 (|compiledLookupCheck| '|pole?|
                                                        (LIST (LIST '|Boolean|)
                                                              '$)
                                                        (|UnivariateLaurentSeries|
                                                         (ELT $ 7) |x|
                                                         (ELT $ 9))))
                       (LETT |uls|
                             (SPADCALL (ELT $ 40) |uls|
                                       (|compiledLookupCheck| '|map|
                                                              (LIST '$
                                                                    (LIST
                                                                     '|Mapping|
                                                                     (|devaluate|
                                                                      (ELT $
                                                                           7))
                                                                     (|devaluate|
                                                                      (ELT $
                                                                           7)))
                                                                    '$)
                                                              (|UnivariateLaurentSeries|
                                                               (ELT $ 7) |x|
                                                               (ELT $ 9))))
                             . #2#)))
                     (EXIT
                      (COND
                       ((SPADCALL |uls|
                                  (|compiledLookupCheck| '|pole?|
                                                         (LIST
                                                          (LIST '|Boolean|) '$)
                                                         (|UnivariateLaurentSeries|
                                                          (ELT $ 7) |x|
                                                          (ELT $ 9))))
                        (SEQ
                         (LETT |cl|
                               (SPADCALL |uls|
                                         (LETT |ordl|
                                               (SPADCALL |uls|
                                                         (|compiledLookupCheck|
                                                          '|order|
                                                          (LIST
                                                           (LIST '|Integer|)
                                                           '$)
                                                          (|UnivariateLaurentSeries|
                                                           (ELT $ 7) |x|
                                                           (ELT $ 9))))
                                               . #2#)
                                         (|compiledLookupCheck| '|coefficient|
                                                                (LIST
                                                                 (|devaluate|
                                                                  (ELT $ 7))
                                                                 '$
                                                                 (LIST
                                                                  '|Integer|))
                                                                (|UnivariateLaurentSeries|
                                                                 (ELT $ 7) |x|
                                                                 (ELT $ 9))))
                               . #2#)
                         (EXIT
                          (PROGN
                           (LETT #1#
                                 (|LIMITPS;poleLimit|
                                  (SPADCALL |ordl| (QREFELT $ 93)) |cl| |x| $)
                                 . #2#)
                           (GO #1#)))))
                       (#3#
                        (CONS 0
                              (SPADCALL |uls| 0
                                        (|compiledLookupCheck| '|coefficient|
                                                               (LIST
                                                                (|devaluate|
                                                                 (ELT $ 7))
                                                                '$
                                                                (LIST
                                                                 '|Integer|))
                                                               (|UnivariateLaurentSeries|
                                                                (ELT $ 7) |x|
                                                                (ELT $
                                                                     9)))))))))))))))
              . #2#)
        (EXIT
         (COND ((QEQCAR |lim| 1) (CONS 2 "failed"))
               ((SPADCALL |x| (SPADCALL (QCDR |lim|) (QREFELT $ 11))
                          (QREFELT $ 14))
                (COND
                 ((SPADCALL |x|
                            (SPADCALL
                             (LETT |answer|
                                   (SPADCALL (QCDR |lim|) (QREFELT $ 40))
                                   . #2#)
                             (QREFELT $ 11))
                            (QREFELT $ 14))
                  (|error| "limit: can't evaluate limit"))
                 (#3# (CONS 0 (SPADCALL |answer| (QREFELT $ 38))))))
               (#3# (CONS 0 (SPADCALL (QCDR |lim|) (QREFELT $ 38))))))))
      #1# (EXIT #1#))))) 

(DEFUN |LIMITPS;xxpLimit| (|fcn| |x| $)
  (PROG (|xxp| |xpack|)
    (RETURN
     (SEQ
      (LETT |xpack|
            (|FunctionSpaceToExponentialExpansion| (QREFELT $ 6) (QREFELT $ 7)
                                                   |x| (QREFELT $ 9))
            . #1=(|LIMITPS;xxpLimit|))
      (LETT |xxp|
            (SPADCALL |fcn| 'T
                      (|compiledLookupCheck| '|exprToXXP|
                                             (LIST
                                              (LIST '|Union|
                                                    (LIST '|:| '|%expansion|
                                                          (LIST
                                                           '|ExponentialExpansion|
                                                           (|devaluate|
                                                            (ELT $ 6))
                                                           (|devaluate|
                                                            (ELT $ 7))
                                                           |x|
                                                           (|devaluate|
                                                            (ELT $ 9))))
                                                    (LIST '|:| '|%problem|
                                                          (LIST '|Record|
                                                                (LIST '|:|
                                                                      '|func|
                                                                      (LIST
                                                                       '|String|))
                                                                (LIST '|:|
                                                                      '|prob|
                                                                      (LIST
                                                                       '|String|)))))
                                              (|devaluate| (ELT $ 7))
                                              (LIST '|Boolean|))
                                             |xpack|))
            . #1#)
      (EXIT
       (COND ((QEQCAR |xxp| 1) (CONS 1 "failed"))
             ('T
              (SPADCALL (CDR |xxp|)
                        (|compiledLookupCheck| '|limitPlus|
                                               (LIST
                                                (LIST '|Union|
                                                      (LIST
                                                       '|OrderedCompletion|
                                                       (|devaluate| (ELT $ 7)))
                                                      '"failed")
                                                '$)
                                               (|ExponentialExpansion|
                                                (ELT $ 6) (ELT $ 7) |x|
                                                (ELT $ 9))))))))))) 

(DEFUN |LIMITPS;limitPlus| (|fcn| |x| $)
  (PROG (|xLim| |answer| |lim| #1=#:G2238 |cl| |ordl| |uls| |pp| |ff| |trouble|
         |lseries| |lpack| |cp| |ordp| |upxs| |pseries| |ppack|)
    (RETURN
     (SEQ
      (EXIT
       (SEQ
        (LETT |lim|
              (COND
               ((|LIMITPS;anyRootsOrAtrigs?| |fcn| $)
                (SEQ
                 (LETT |ppack|
                       (|FunctionSpaceToUnivariatePowerSeries| (QREFELT $ 6)
                                                               (QREFELT $ 7)
                                                               (|Fraction|
                                                                (|Integer|))
                                                               (|UnivariatePuiseuxSeries|
                                                                (QREFELT $ 7)
                                                                |x|
                                                                (QREFELT $ 9))
                                                               (|ElementaryFunctionsUnivariatePuiseuxSeries|
                                                                (QREFELT $ 7)
                                                                (|UnivariateLaurentSeries|
                                                                 (QREFELT $ 7)
                                                                 |x|
                                                                 (QREFELT $ 9))
                                                                (|UnivariatePuiseuxSeries|
                                                                 (QREFELT $ 7)
                                                                 |x|
                                                                 (QREFELT $ 9))
                                                                (|ElementaryFunctionsUnivariateLaurentSeries|
                                                                 (QREFELT $ 7)
                                                                 (|UnivariateTaylorSeries|
                                                                  (QREFELT $ 7)
                                                                  |x|
                                                                  (QREFELT $
                                                                           9))
                                                                 (|UnivariateLaurentSeries|
                                                                  (QREFELT $ 7)
                                                                  |x|
                                                                  (QREFELT $
                                                                           9))))
                                                               |x|)
                       . #2=(|LIMITPS;limitPlus|))
                 (LETT |pseries|
                       (SPADCALL |fcn| 'T "real: right side"
                                 (|compiledLookupCheck| '|exprToGenUPS|
                                                        (LIST
                                                         (LIST '|Union|
                                                               (LIST '|:|
                                                                     '|%series|
                                                                     (LIST
                                                                      '|UnivariatePuiseuxSeries|
                                                                      (|devaluate|
                                                                       (ELT $
                                                                            7))
                                                                      |x|
                                                                      (|devaluate|
                                                                       (ELT $
                                                                            9))))
                                                               (LIST '|:|
                                                                     '|%problem|
                                                                     (LIST
                                                                      '|Record|
                                                                      (LIST
                                                                       '|:|
                                                                       '|func|
                                                                       (LIST
                                                                        '|String|))
                                                                      (LIST
                                                                       '|:|
                                                                       '|prob|
                                                                       (LIST
                                                                        '|String|)))))
                                                         (|devaluate|
                                                          (ELT $ 7))
                                                         (LIST '|Boolean|)
                                                         (LIST '|String|))
                                                        |ppack|))
                       . #2#)
                 (EXIT
                  (COND
                   ((QEQCAR |pseries| 1)
                    (SEQ (LETT |trouble| (CDR |pseries|) . #2#)
                         (LETT |ff| (QCAR |trouble|) . #2#)
                         (LETT |pp| (QCDR |trouble|) . #2#)
                         (EXIT
                          (COND
                           ((EQUAL |pp| "negative leading coefficient")
                            (PROGN
                             (LETT #1# (CONS 1 "failed") . #2#)
                             (GO #1#)))
                           (#3='T (CONS 1 "failed"))))))
                   (#3#
                    (SEQ
                     (COND
                      ((SPADCALL (LETT |upxs| (CDR |pseries|) . #2#)
                                 (|compiledLookupCheck| '|pole?|
                                                        (LIST (LIST '|Boolean|)
                                                              '$)
                                                        (|UnivariatePuiseuxSeries|
                                                         (ELT $ 7) |x|
                                                         (ELT $ 9))))
                       (LETT |upxs|
                             (SPADCALL (ELT $ 40) |upxs|
                                       (|compiledLookupCheck| '|map|
                                                              (LIST '$
                                                                    (LIST
                                                                     '|Mapping|
                                                                     (|devaluate|
                                                                      (ELT $
                                                                           7))
                                                                     (|devaluate|
                                                                      (ELT $
                                                                           7)))
                                                                    '$)
                                                              (|UnivariatePuiseuxSeries|
                                                               (ELT $ 7) |x|
                                                               (ELT $ 9))))
                             . #2#)))
                     (EXIT
                      (COND
                       ((SPADCALL |upxs|
                                  (|compiledLookupCheck| '|pole?|
                                                         (LIST
                                                          (LIST '|Boolean|) '$)
                                                         (|UnivariatePuiseuxSeries|
                                                          (ELT $ 7) |x|
                                                          (ELT $ 9))))
                        (SEQ
                         (LETT |cp|
                               (SPADCALL |upxs|
                                         (LETT |ordp|
                                               (SPADCALL |upxs|
                                                         (|compiledLookupCheck|
                                                          '|order|
                                                          (LIST
                                                           (LIST '|Fraction|
                                                                 (LIST
                                                                  '|Integer|))
                                                           '$)
                                                          (|UnivariatePuiseuxSeries|
                                                           (ELT $ 7) |x|
                                                           (ELT $ 9))))
                                               . #2#)
                                         (|compiledLookupCheck| '|coefficient|
                                                                (LIST
                                                                 (|devaluate|
                                                                  (ELT $ 7))
                                                                 '$
                                                                 (LIST
                                                                  '|Fraction|
                                                                  (LIST
                                                                   '|Integer|)))
                                                                (|UnivariatePuiseuxSeries|
                                                                 (ELT $ 7) |x|
                                                                 (ELT $ 9))))
                               . #2#)
                         (EXIT
                          (PROGN
                           (LETT #1#
                                 (|LIMITPS;poleLimitPlus| |ordp| |cp| |x| $)
                                 . #2#)
                           (GO #1#)))))
                       (#3#
                        (CONS 0
                              (SPADCALL |upxs| (|spadConstant| $ 80)
                                        (|compiledLookupCheck| '|coefficient|
                                                               (LIST
                                                                (|devaluate|
                                                                 (ELT $ 7))
                                                                '$
                                                                (LIST
                                                                 '|Fraction|
                                                                 (LIST
                                                                  '|Integer|)))
                                                               (|UnivariatePuiseuxSeries|
                                                                (ELT $ 7) |x|
                                                                (ELT $
                                                                     9))))))))))))))
               (#3#
                (SEQ
                 (LETT |lpack|
                       (|FunctionSpaceToUnivariatePowerSeries| (QREFELT $ 6)
                                                               (QREFELT $ 7)
                                                               (|Integer|)
                                                               (|UnivariateLaurentSeries|
                                                                (QREFELT $ 7)
                                                                |x|
                                                                (QREFELT $ 9))
                                                               (|ElementaryFunctionsUnivariateLaurentSeries|
                                                                (QREFELT $ 7)
                                                                (|UnivariateTaylorSeries|
                                                                 (QREFELT $ 7)
                                                                 |x|
                                                                 (QREFELT $ 9))
                                                                (|UnivariateLaurentSeries|
                                                                 (QREFELT $ 7)
                                                                 |x|
                                                                 (QREFELT $
                                                                          9)))
                                                               |x|)
                       . #2#)
                 (LETT |lseries|
                       (SPADCALL |fcn| 'T "real: right side"
                                 (|compiledLookupCheck| '|exprToGenUPS|
                                                        (LIST
                                                         (LIST '|Union|
                                                               (LIST '|:|
                                                                     '|%series|
                                                                     (LIST
                                                                      '|UnivariateLaurentSeries|
                                                                      (|devaluate|
                                                                       (ELT $
                                                                            7))
                                                                      |x|
                                                                      (|devaluate|
                                                                       (ELT $
                                                                            9))))
                                                               (LIST '|:|
                                                                     '|%problem|
                                                                     (LIST
                                                                      '|Record|
                                                                      (LIST
                                                                       '|:|
                                                                       '|func|
                                                                       (LIST
                                                                        '|String|))
                                                                      (LIST
                                                                       '|:|
                                                                       '|prob|
                                                                       (LIST
                                                                        '|String|)))))
                                                         (|devaluate|
                                                          (ELT $ 7))
                                                         (LIST '|Boolean|)
                                                         (LIST '|String|))
                                                        |lpack|))
                       . #2#)
                 (EXIT
                  (COND
                   ((QEQCAR |lseries| 1)
                    (SEQ (LETT |trouble| (CDR |lseries|) . #2#)
                         (LETT |ff| (QCAR |trouble|) . #2#)
                         (LETT |pp| (QCDR |trouble|) . #2#)
                         (EXIT
                          (COND
                           ((EQUAL |pp| "negative leading coefficient")
                            (PROGN
                             (LETT #1# (CONS 1 "failed") . #2#)
                             (GO #1#)))
                           (#3# (CONS 1 "failed"))))))
                   (#3#
                    (SEQ
                     (COND
                      ((SPADCALL (LETT |uls| (CDR |lseries|) . #2#)
                                 (|compiledLookupCheck| '|pole?|
                                                        (LIST (LIST '|Boolean|)
                                                              '$)
                                                        (|UnivariateLaurentSeries|
                                                         (ELT $ 7) |x|
                                                         (ELT $ 9))))
                       (LETT |uls|
                             (SPADCALL (ELT $ 40) |uls|
                                       (|compiledLookupCheck| '|map|
                                                              (LIST '$
                                                                    (LIST
                                                                     '|Mapping|
                                                                     (|devaluate|
                                                                      (ELT $
                                                                           7))
                                                                     (|devaluate|
                                                                      (ELT $
                                                                           7)))
                                                                    '$)
                                                              (|UnivariateLaurentSeries|
                                                               (ELT $ 7) |x|
                                                               (ELT $ 9))))
                             . #2#)))
                     (EXIT
                      (COND
                       ((SPADCALL |uls|
                                  (|compiledLookupCheck| '|pole?|
                                                         (LIST
                                                          (LIST '|Boolean|) '$)
                                                         (|UnivariateLaurentSeries|
                                                          (ELT $ 7) |x|
                                                          (ELT $ 9))))
                        (SEQ
                         (LETT |cl|
                               (SPADCALL |uls|
                                         (LETT |ordl|
                                               (SPADCALL |uls|
                                                         (|compiledLookupCheck|
                                                          '|order|
                                                          (LIST
                                                           (LIST '|Integer|)
                                                           '$)
                                                          (|UnivariateLaurentSeries|
                                                           (ELT $ 7) |x|
                                                           (ELT $ 9))))
                                               . #2#)
                                         (|compiledLookupCheck| '|coefficient|
                                                                (LIST
                                                                 (|devaluate|
                                                                  (ELT $ 7))
                                                                 '$
                                                                 (LIST
                                                                  '|Integer|))
                                                                (|UnivariateLaurentSeries|
                                                                 (ELT $ 7) |x|
                                                                 (ELT $ 9))))
                               . #2#)
                         (EXIT
                          (PROGN
                           (LETT #1#
                                 (|LIMITPS;poleLimitPlus|
                                  (SPADCALL |ordl| (QREFELT $ 93)) |cl| |x| $)
                                 . #2#)
                           (GO #1#)))))
                       (#3#
                        (CONS 0
                              (SPADCALL |uls| 0
                                        (|compiledLookupCheck| '|coefficient|
                                                               (LIST
                                                                (|devaluate|
                                                                 (ELT $ 7))
                                                                '$
                                                                (LIST
                                                                 '|Integer|))
                                                               (|UnivariateLaurentSeries|
                                                                (ELT $ 7) |x|
                                                                (ELT $
                                                                     9)))))))))))))))
              . #2#)
        (EXIT
         (COND
          ((QEQCAR |lim| 1)
           (SEQ (LETT |xLim| (|LIMITPS;xxpLimit| |fcn| |x| $) . #2#)
                (EXIT
                 (COND ((QEQCAR |xLim| 1) (|LIMITPS;specialLimit| |fcn| |x| $))
                       (#3# |xLim|)))))
          ((SPADCALL |x| (SPADCALL (QCDR |lim|) (QREFELT $ 11)) (QREFELT $ 14))
           (COND
            ((SPADCALL |x|
                       (SPADCALL
                        (LETT |answer| (SPADCALL (QCDR |lim|) (QREFELT $ 40))
                              . #2#)
                        (QREFELT $ 11))
                       (QREFELT $ 14))
             (SEQ (LETT |xLim| (|LIMITPS;xxpLimit| |answer| |x| $) . #2#)
                  (EXIT
                   (COND
                    ((QEQCAR |xLim| 1) (|LIMITPS;specialLimit| |answer| |x| $))
                    (#3# |xLim|)))))
            (#3# (CONS 0 (SPADCALL |answer| (QREFELT $ 38))))))
          (#3# (CONS 0 (SPADCALL (QCDR |lim|) (QREFELT $ 38))))))))
      #1# (EXIT #1#))))) 

(DEFUN |LIMITPS;limit;FEEU;24| (|fcn| |eq| $)
  (PROG (|a| |x| |xx| |f|)
    (RETURN
     (SEQ
      (LETT |f| (SPADCALL (SPADCALL |eq| (QREFELT $ 95)) (QREFELT $ 34))
            . #1=(|LIMITPS;limit;FEEU;24|))
      (EXIT
       (COND
        ((QEQCAR |f| 1) (|error| "limit:left hand side must be a variable"))
        (#2='T
         (SEQ (LETT |xx| (SPADCALL (QCDR |f|) (QREFELT $ 72)) . #1#)
              (EXIT
               (COND
                ((QEQCAR |xx| 1)
                 (|error| "limit:left hand side must be a variable"))
                (#2#
                 (SEQ (LETT |x| (QCDR |xx|) . #1#)
                      (LETT |a| (SPADCALL |eq| (QREFELT $ 96)) . #1#)
                      (EXIT (|LIMITPS;locallimit| |fcn| |x| |a| $)))))))))))))) 

(DEFUN |LIMITPS;complexLimit;FEEU;25| (|fcn| |eq| $)
  (PROG (|a| |x| |xx| |f|)
    (RETURN
     (SEQ
      (LETT |f| (SPADCALL (SPADCALL |eq| (QREFELT $ 101)) (QREFELT $ 69))
            . #1=(|LIMITPS;complexLimit;FEEU;25|))
      (EXIT
       (COND
        ((QEQCAR |f| 1) (|error| "limit:left hand side must be a variable"))
        (#2='T
         (SEQ (LETT |xx| (SPADCALL (QCDR |f|) (QREFELT $ 72)) . #1#)
              (EXIT
               (COND
                ((QEQCAR |xx| 1)
                 (|error| "limit:left hand side must be a variable"))
                (#2#
                 (SEQ (LETT |x| (QCDR |xx|) . #1#)
                      (LETT |a| (SPADCALL |eq| (QREFELT $ 102)) . #1#)
                      (EXIT
                       (|LIMITPS;locallimitcomplex| |fcn| |x| |a|
                        $)))))))))))))) 

(DEFUN |PowerSeriesLimitPackage| (&REST #1=#:G2275)
  (PROG ()
    (RETURN
     (PROG (#2=#:G2276)
       (RETURN
        (COND
         ((LETT #2#
                (|lassocShiftWithFunction| (|devaluateList| #1#)
                                           (HGET |$ConstructorCache|
                                                 '|PowerSeriesLimitPackage|)
                                           '|domainEqualList|)
                . #3=(|PowerSeriesLimitPackage|))
          (|CDRwithIncrement| #2#))
         ('T
          (UNWIND-PROTECT
              (PROG1 (APPLY (|function| |PowerSeriesLimitPackage;|) #1#)
                (LETT #2# T . #3#))
            (COND
             ((NOT #2#)
              (HREM |$ConstructorCache| '|PowerSeriesLimitPackage|))))))))))) 

(DEFUN |PowerSeriesLimitPackage;| (|#1| |#2|)
  (PROG (|pv$| $ |dv$| DV$2 DV$1)
    (RETURN
     (PROGN
      (LETT DV$1 (|devaluate| |#1|) . #1=(|PowerSeriesLimitPackage|))
      (LETT DV$2 (|devaluate| |#2|) . #1#)
      (LETT |dv$| (LIST '|PowerSeriesLimitPackage| DV$1 DV$2) . #1#)
      (LETT $ (GETREFV 105) . #1#)
      (QSETREFV $ 0 |dv$|)
      (QSETREFV $ 3 (LETT |pv$| (|buildPredVector| 0 0 NIL) . #1#))
      (|haddProp| |$ConstructorCache| '|PowerSeriesLimitPackage|
                  (LIST DV$1 DV$2) (CONS 1 $))
      (|stuffDomainSlots| $)
      (QSETREFV $ 6 |#1|)
      (QSETREFV $ 7 |#2|)
      (QSETREFV $ 9 (|spadConstant| $ 8))
      $)))) 

(MAKEPROP '|PowerSeriesLimitPackage| '|infovec|
          (LIST
           '#(NIL NIL NIL NIL NIL NIL (|local| |#1|) (|local| |#2|)
              (0 . |Zero|) '|zeroFE| (|List| 13) (4 . |variables|) (|Boolean|)
              (|Symbol|) (9 . |member?|) (|List| 21) (15 . |kernels|)
              (|String|) (20 . |coerce|) (|Kernel| 7) (25 . |is?|) (|Kernel| $)
              (31 . |coerce|) (36 . |name|) (41 . -) (47 . |inv|)
              (|SingleInteger|) (|OrderedCompletion| 7) (52 . |whatInfinity|)
              (57 . |Zero|) (61 . |One|) (65 . |numerator|)
              (70 . |denominator|) (|Union| 7 '#1="failed")
              (75 . |retractIfCan|) (80 . |eval|) (87 . =) (93 . /)
              (99 . |coerce|) (|ElementaryFunctionStructurePackage| 6 7)
              (104 . |normalize|) (109 . |tower|) (114 . |new|)
              (118 . |coerce|) (|Equation| 7) (123 . |equation|) (|Equation| $)
              (129 . |eval|) (|List| 7) (135 . |argument|) (140 . |One|)
              (144 . -) (149 . |minusInfinity|) (153 . |log|) (|BasicOperator|)
              (158 . |operator|) (163 . |elt|) (169 . |retract|)
              (|LiouvillianFunction| 6 7) (174 . |erf|) (179 . |pi|)
              (|Integer|) (183 . |coerce|) (188 . -) (193 . |plusInfinity|)
              (197 . |retract|) (202 . *) (208 . +) (|OnePointCompletion| 7)
              (214 . |retractIfCan|) (219 . |lhs|) (|Union| 13 '#1#)
              (224 . |retractIfCan|) (229 . |rhs|) (|ToolsForSign| 6)
              (234 . |direction|) (|Union| 27 '"failed")
              |LIMITPS;limit;FEESU;15| (239 . |infinity|) (|Fraction| 61)
              (243 . |Zero|) (247 . |coerce|) (|Union| 61 '"failed")
              (|ElementaryFunctionSign| 6 7) (252 . |sign|) (257 . *)
              (263 . |numer|) (268 . |even?|) (273 . |denom|) (278 . -)
              (283 . |zero?|) (288 . |kernel|) (293 . =) (299 . |coerce|)
              (|Equation| 27) (304 . |lhs|) (309 . |rhs|)
              (|Record| (|:| |leftHandLimit| 76) (|:| |rightHandLimit| 76))
              (|Union| 27 97 '"failed") |LIMITPS;limit;FEEU;24| (|Equation| 68)
              (314 . |lhs|) (319 . |rhs|) (|Union| 68 '"failed")
              |LIMITPS;complexLimit;FEEU;25|)
           '#(|limit| 324 |complexLimit| 337) 'NIL
           (CONS (|makeByteWordVec2| 1 'NIL)
                 (CONS '#()
                       (CONS '#()
                             (|makeByteWordVec2| 104
                                                 '(0 7 0 8 1 7 10 0 11 2 10 12
                                                   13 0 14 1 7 15 0 16 1 13 0
                                                   17 18 2 19 12 0 13 20 1 7 0
                                                   21 22 1 19 13 0 23 2 7 0 0 0
                                                   24 1 7 0 0 25 1 27 26 0 28 0
                                                   6 0 29 0 6 0 30 1 7 0 0 31 1
                                                   7 0 0 32 1 27 33 0 34 3 7 0
                                                   0 21 0 35 2 7 12 0 0 36 2 7
                                                   0 0 0 37 1 27 0 7 38 1 39 7
                                                   7 40 1 7 15 0 41 0 13 0 42 1
                                                   7 0 13 43 2 44 0 7 7 45 2 7
                                                   0 0 46 47 1 19 48 0 49 0 7 0
                                                   50 1 6 0 0 51 0 27 0 52 1 7
                                                   0 0 53 1 19 54 0 55 2 7 0 54
                                                   0 56 1 27 7 0 57 1 58 7 7 59
                                                   0 7 0 60 1 7 0 61 62 1 7 0 0
                                                   63 0 27 0 64 1 7 21 0 65 2 7
                                                   0 61 0 66 2 7 0 0 0 67 1 68
                                                   33 0 69 1 44 7 0 70 1 7 71 0
                                                   72 1 44 7 0 73 1 74 61 17 75
                                                   0 68 0 78 0 79 0 80 1 68 0 7
                                                   81 1 83 82 7 84 2 27 0 61 0
                                                   85 1 79 61 0 86 1 61 12 0 87
                                                   1 79 61 0 88 1 27 0 0 89 1
                                                   27 12 0 90 1 19 0 13 91 2 27
                                                   12 0 0 92 1 79 0 61 93 1 94
                                                   27 0 95 1 94 27 0 96 1 100
                                                   68 0 101 1 100 68 0 102 2 0
                                                   98 7 94 99 3 0 76 7 44 17 77
                                                   2 0 103 7 100 104)))))
           '|lookupComplete|)) 
