
(/VERSIONCHECK 2) 

(DEFUN |ODESYS;solve;MVMU;1| (|mm| |v| |solve| $)
  (PROG (|rec| |e| #0=#:G1862 |u| #1=#:G1861 |sols| |n| |part|
               #2=#:G1863 |SolMatrix| |sol| #3=#:G1864 |i| |er| |nn|
               |s| #4=#:G1865 |solVec| |m| |l| |k|)
    (RETURN
      (SEQ (EXIT (SEQ (LETT |rec| (SPADCALL |mm| |v| (QREFELT $ 14))
                            . #5=(|ODESYS;solve;MVMU;1|))
                      (LETT |sols| NIL . #5#)
                      (SEQ (LETT |e| NIL . #5#)
                           (LETT #0# (QCDR |rec|) . #5#) G190
                           (COND
                             ((OR (ATOM #0#)
                                  (PROGN
                                    (LETT |e| (CAR #0#) . #5#)
                                    NIL))
                              #6=(GO G191)))
                           (SEQ (LETT |u|
                                      (SPADCALL (QVELT |e| 2)
                                       (QVELT |e| 3) |solve|) . #5#)
                                (EXIT (COND
                                        ((QEQCAR |u| 1)
                                         (PROGN
                                           (LETT #1#
                                            (CONS 1 "failed") . #5#)
                                           (GO #1#)))
                                        ('T
                                         (LETT |sols|
                                          (CONS (QCDR |u|) |sols|) . #5#)))))
                           (LETT #0# (CDR #0#) . #5#) #7=(GO G190) G191
                           (EXIT NIL))
                      (LETT |n|
                            (SPADCALL (QCAR |rec|) (QREFELT $ 16)) . #5#)
                      (LETT |k| 0 . #5#) (LETT |i| 0 . #5#)
                      (LETT |m| 0 . #5#)
                      (LETT |part|
                            (SPADCALL |n| (|spadConstant| $ 17)
                                (QREFELT $ 19)) . #5#)
                      (SEQ (LETT |sol| NIL . #5#)
                           (LETT #2# |sols| . #5#) G190
                           (COND
                             ((OR (ATOM #2#)
                                  (PROGN
                                    (LETT |sol| (CAR #2#) . #5#)
                                    NIL))
                              #6#))
                           (SEQ (EXIT (LETT |m|
                                       (+ |m|
                                        (SPADCALL
                                         (CONS
                                          #'|ODESYS;solve;MVMU;1!0| $)
                                         (QCDR |sol|) (QREFELT $ 26))) . #5#)))
                           (LETT #2# (CDR #2#) . #5#) #7# G191
                           (EXIT NIL))
                      (LETT |SolMatrix|
                            (SPADCALL |n| |m| (|spadConstant| $ 17)
                                (QREFELT $ 27)) . #5#)
                      (LETT |m| 0 . #5#)
                      (SEQ (LETT |sol| NIL . #5#)
                           (LETT #3# (NREVERSE |sols|) . #5#) G190
                           (COND
                             ((OR (ATOM #3#)
                                  (PROGN
                                    (LETT |sol| (CAR #3#) . #5#)
                                    NIL))
                              #6#))
                           (SEQ (LETT |i| (+ |i| 1) . #5#)
                                (LETT |er|
                                      (SPADCALL (QCDR |rec|) |i|
                                       (QREFELT $ 32)) . #5#)
                                (LETT |nn|
                                      (QVSIZE (QVELT |er| 1)) . #5#)
                                (SEQ (LETT |s| NIL . #5#)
                                     (LETT #4# (QCDR |sol|) . #5#) G190
                                     (COND
                                       ((OR (ATOM #4#)
                                         (PROGN
                                           (LETT |s| (CAR #4#) . #5#)
                                           NIL))
                                        #6#))
                                     (SEQ
                                      (LETT |solVec|
                                       (SPADCALL |n|
                                        (|spadConstant| $ 17)
                                        (QREFELT $ 19)) . #5#)
                                      (SPADCALL |solVec| (+ |k| 1) |s|
                                       (QREFELT $ 33))
                                      (SEQ (LETT |l| 2 . #5#) G190
                                       (COND
                                         ((QSGREATERP |l| |nn|) #6#))
                                       (SEQ
                                        (EXIT
                                         (SPADCALL |solVec| (+ |k| |l|)
                                          (SPADCALL (QREFELT $ 9)
                                           (SPADCALL |solVec|
                                            (- (+ |k| |l|) 1)
                                            (QREFELT $ 34))
                                           (QREFELT $ 35))
                                          (QREFELT $ 33))))
                                       (LETT |l| (QSADD1 |l|) . #5#)
                                       #7# G191 (EXIT NIL))
                                      (LETT |m| (+ |m| 1) . #5#)
                                      (EXIT
                                       (SPADCALL |SolMatrix| |m|
                                        |solVec| (QREFELT $ 36))))
                                     (LETT #4# (CDR #4#) . #5#) #7#
                                     G191 (EXIT NIL))
                                (SPADCALL |part| (+ |k| 1) (QCAR |sol|)
                                    (QREFELT $ 33))
                                (SEQ (LETT |l| 2 . #5#) G190
                                     (COND
                                       ((QSGREATERP |l| |nn|) #6#))
                                     (SEQ
                                      (EXIT
                                       (SPADCALL |part| (+ |k| |l|)
                                        (SPADCALL
                                         (SPADCALL (QREFELT $ 9)
                                          (SPADCALL |part|
                                           (- (+ |k| |l|) 1)
                                           (QREFELT $ 34))
                                          (QREFELT $ 35))
                                         (SPADCALL (QVELT |er| 1)
                                          (- |l| 1) (QREFELT $ 34))
                                         (QREFELT $ 37))
                                        (QREFELT $ 33))))
                                     (LETT |l| (QSADD1 |l|) . #5#) #7#
                                     G191 (EXIT NIL))
                                (EXIT (LETT |k| (+ |k| |nn|) . #5#)))
                           (LETT #3# (CDR #3#) . #5#) #7# G191
                           (EXIT NIL))
                      (EXIT (CONS 0
                                  (CONS (SPADCALL (QCAR |rec|) |part|
                                         (QREFELT $ 38))
                                        (SPADCALL (QCAR |rec|)
                                         |SolMatrix| (QREFELT $ 39)))))))
           #1# (EXIT #1#))))) 

(DEFUN |ODESYS;solve;MVMU;1!0| (|#1| $)
  (COND
    ((SPADCALL |#1| (|spadConstant| $ 17) (QREFELT $ 21))
     (|spadConstant| $ 22))
    ('T (|spadConstant| $ 23)))) 

(DEFUN |ODESYS;triangulate;MVR;2| (|m| |v| $)
  (PROG (|rat| |l| |er| #0=#:G1881 |n| #1=#:G1882 |op| |sum| #2=#:G1883
               |j| |h0| |ler| |k|)
    (RETURN
      (SEQ (LETT |k| 0 . #3=(|ODESYS;triangulate;MVR;2|))
           (LETT |rat|
                 (SPADCALL |m| (|spadConstant| $ 47)
                     (CONS #'|ODESYS;triangulate;MVR;2!0|
                           (VECTOR $ (QREFELT $ 9)))
                     (QREFELT $ 52)) . #3#)
           (LETT |l|
                 (SPADCALL (QVELT |rat| 0)
                     (SPADCALL (QVELT |rat| 2) |v| (QREFELT $ 38))
                     (QREFELT $ 55)) . #3#)
           (LETT |ler| NIL . #3#)
           (SEQ (LETT |er| NIL . #3#) (LETT #0# |l| . #3#) G190
                (COND
                  ((OR (ATOM #0#)
                       (PROGN (LETT |er| (CAR #0#) . #3#) NIL))
                   #4=(GO G191)))
                (SEQ (LETT |n|
                           (SPADCALL (QCAR |er|) (QREFELT $ 16)) . #3#)
                     (LETT |op| (|spadConstant| $ 18) . #3#)
                     (SEQ (LETT |j| 0 . #3#) (LETT #1# (- |n| 1) . #3#)
                          G190 (COND ((QSGREATERP |j| #1#) #4#))
                          (SEQ (EXIT (LETT |op|
                                      (SPADCALL |op|
                                       (SPADCALL
                                        (SPADCALL (QCAR |er|) |n|
                                         (+ |j| 1) (QREFELT $ 56))
                                        |j| (QREFELT $ 57))
                                       (QREFELT $ 58)) . #3#)))
                          (LETT |j| (QSADD1 |j|) . #3#) #5=(GO G190)
                          G191 (EXIT NIL))
                     (LETT |op|
                           (SPADCALL
                               (SPADCALL (|spadConstant| $ 28) |n|
                                   (QREFELT $ 57))
                               |op| (QREFELT $ 59)) . #3#)
                     (LETT |sum|
                           (SPADCALL |n| (|spadConstant| $ 17)
                               (QREFELT $ 19)) . #3#)
                     (SEQ (LETT |j| 1 . #3#) (LETT #2# (- |n| 1) . #3#)
                          G190 (COND ((QSGREATERP |j| #2#) #4#))
                          (SEQ (EXIT (SPADCALL |sum| (+ |j| 1)
                                      (SPADCALL
                                       (SPADCALL (QREFELT $ 9)
                                        (SPADCALL |sum| |j|
                                         (QREFELT $ 34))
                                        (QREFELT $ 35))
                                       (SPADCALL (QCDR |er|) |j|
                                        (QREFELT $ 34))
                                       (QREFELT $ 60))
                                      (QREFELT $ 33))))
                          (LETT |j| (QSADD1 |j|) . #3#) #5# G191
                          (EXIT NIL))
                     (LETT |h0| (|spadConstant| $ 17) . #3#)
                     (SEQ (LETT |j| 1 . #3#) G190
                          (COND ((QSGREATERP |j| |n|) #4#))
                          (SEQ (EXIT (LETT |h0|
                                      (SPADCALL |h0|
                                       (SPADCALL
                                        (SPADCALL (QCAR |er|) |n| |j|
                                         (QREFELT $ 56))
                                        (SPADCALL |sum| |j|
                                         (QREFELT $ 34))
                                        (QREFELT $ 61))
                                       (QREFELT $ 37)) . #3#)))
                          (LETT |j| (QSADD1 |j|) . #3#) #5# G191
                          (EXIT NIL))
                     (LETT |h0|
                           (SPADCALL
                               (SPADCALL |h0|
                                   (SPADCALL (QREFELT $ 9)
                                    (SPADCALL |sum| |n| (QREFELT $ 34))
                                    (QREFELT $ 35))
                                   (QREFELT $ 60))
                               (SPADCALL (QCDR |er|) |n|
                                   (QREFELT $ 34))
                               (QREFELT $ 60)) . #3#)
                     (LETT |ler|
                           (CONS (VECTOR (QCAR |er|) (QCDR |er|) |op|
                                         |h0|)
                                 |ler|) . #3#)
                     (EXIT (LETT |k| (+ |k| |n|) . #3#)))
                (LETT #0# (CDR #0#) . #3#) #5# G191 (EXIT NIL))
           (EXIT (CONS (QVELT |rat| 1) |ler|)))))) 

(DEFUN |ODESYS;triangulate;MVR;2!0| (|#1| $$)
  (PROG ($)
    (LETT $ (QREFELT $$ 0) |ODESYS;triangulate;MVR;2|)
    (RETURN
      (PROGN
        (SPADCALL (SPADCALL (QREFELT $$ 1) |#1| (QREFELT $ 35))
            (QREFELT $ 48)))))) 

(DEFUN |ODESYS;backsolve| (|m| |v| |solve| $)
  (PROG (|mr| |offset| |rec| #0=#:G1889 |dim| |u| |part?| |part|
              #1=#:G1891 |hom| |b| #2=#:G1909 #3=#:G1908 |r| |c| |eq|
              |a| #4=#:G1910 |n| #5=#:G1911 |i| #6=#:G1912 |bas|)
    (RETURN
      (SEQ (LETT |r| (SPADCALL |m| (QREFELT $ 63))
                 . #7=(|ODESYS;backsolve|))
           (LETT |offset|
                 (- (SPADCALL |v| (QREFELT $ 64))
                    (LETT |mr| (SPADCALL |m| (QREFELT $ 65)) . #7#)) . #7#)
           (SEQ G190
                (COND
                  ((NULL (COND
                           ((< |r| |mr|) 'NIL)
                           ('T
                            (SPADCALL (ELT $ 66)
                                (SPADCALL |m| |r| (QREFELT $ 68))
                                (QREFELT $ 70)))))
                   #8=(GO G191)))
                (SEQ (EXIT (LETT |r| (- |r| 1) . #7#))) NIL
                #9=(GO G190) G191 (EXIT NIL))
           (EXIT (COND
                   ((< |r| |mr|)
                    (|error| "backsolve: system has a 0 matrix"))
                   ((NULL (EQL (LETT |c|
                                     (|ODESYS;firstnonzero| |m| |r| $) . #7#)
                               (SPADCALL |m| (QREFELT $ 71))))
                    (|error| "backsolve: undetermined system"))
                   ('T
                    (SEQ (LETT |rec|
                               (SPADCALL
                                   (SPADCALL |m| |r| |c|
                                    (QREFELT $ 72))
                                   (SPADCALL |v| (+ |r| |offset|)
                                    (QREFELT $ 34))
                                   |solve|) . #7#)
                         (LETT |dim|
                               (PROG1 (LETT #0#
                                       (+ (- |r| |mr|) 1) . #7#)
                                 (|check-subtype| (>= #0# 0)
                                     '(|NonNegativeInteger|) #0#)) . #7#)
                         (SEQ (LETT |part?|
                                    (QEQCAR
                                     (LETT |u| (QCAR |rec|) . #7#) 0) . #7#)
                              (EXIT (COND
                                      (|part?|
                                       (SEQ
                                        (LETT |part|
                                         (SPADCALL |dim|
                                          (|spadConstant| $ 17)
                                          (QREFELT $ 19)) . #7#)
                                        (EXIT
                                         (SPADCALL |part|
                                          (+ |r| |offset|)
                                          (PROG2 (LETT #1# |u| . #7#)
                                           (QCDR #1#)
                                            (|check-union|
                                             (QEQCAR #1# 0)
                                             (QREFELT $ 6) #1#))
                                          (QREFELT $ 33))))))))
                         (LETT |hom|
                               (SPADCALL |dim| (LENGTH (QCDR |rec|))
                                   (|spadConstant| $ 17)
                                   (QREFELT $ 27)) . #7#)
                         (SEQ (LETT |b| NIL . #7#)
                              (LETT #2# (QCDR |rec|) . #7#)
                              (LETT |i|
                                    (SPADCALL |hom| (QREFELT $ 73)) . #7#)
                              (LETT #3#
                                    (SPADCALL |hom| (QREFELT $ 74)) . #7#)
                              G190
                              (COND
                                ((OR (> |i| #3#) (ATOM #2#)
                                     (PROGN
                                       (LETT |b| (CAR #2#) . #7#)
                                       NIL))
                                 #8#))
                              (SEQ (EXIT
                                    (SPADCALL |hom| |r| |i| |b|
                                     (QREFELT $ 75))))
                              (LETT |i|
                                    (PROG1 (+ |i| 1)
                                      (LETT #2# (CDR #2#) . #7#)) . #7#)
                              #9# G191 (EXIT NIL))
                         (LETT |n| 1 . #7#)
                         (SEQ G190 (COND ((NULL (< |mr| |r|)) #8#))
                              (SEQ (LETT |r| (- |r| 1) . #7#)
                                   (LETT |c| (- |c| 1) . #7#)
                                   (COND
                                     ((NULL
                                       (EQL
                                        (|ODESYS;firstnonzero| |m| |r|
                                         $)
                                        |c|))
                                      (EXIT
                                       (|error|
                                        "backsolve: undetermined system"))))
                                   (EXIT
                                    (COND
                                      ((< 0
                                        (SPADCALL
                                         (LETT |eq|
                                          (SPADCALL |m| |r| |c|
                                           (QREFELT $ 72)) . #7#)
                                         (QREFELT $ 76)))
                                       (|error|
                                        "backsolve: pivot of order > 0"))
                                      ('T
                                       (SEQ
                                        (LETT |a|
                                         (SPADCALL |eq| (QREFELT $ 77)) . #7#)
                                        (COND
                                          (|part?|
                                           (SPADCALL |part|
                                            (+ |r| |offset|)
                                            (SPADCALL
                                             (SPADCALL
                                              (SPADCALL |v|
                                               (+ |r| |offset|)
                                               (QREFELT $ 34))
                                              (|ODESYS;applyLodo| |m|
                                               |r| |part| |n| $)
                                              (QREFELT $ 37))
                                             |a| (QREFELT $ 78))
                                            (QREFELT $ 33))))
                                        (SEQ
                                         (LETT |i|
                                          (SPADCALL |hom|
                                           (QREFELT $ 73)) . #7#)
                                         (LETT #4#
                                          (SPADCALL |hom|
                                           (QREFELT $ 74)) . #7#)
                                         G190 (COND ((> |i| #4#) #8#))
                                         (SEQ
                                          (EXIT
                                           (SPADCALL |hom| |r| |i|
                                            (SPADCALL
                                             (|ODESYS;applyLodo0| |m|
                                              |r| |hom| |i| |n| $)
                                             (QREFELT $ 48))
                                            (QREFELT $ 75))))
                                         (LETT |i| (+ |i| 1) . #7#) #9#
                                         G191 (EXIT NIL))
                                        (EXIT
                                         (LETT |n| (+ |n| 1) . #7#)))))))
                              NIL #9# G191 (EXIT NIL))
                         (LETT |bas|
                               (PROGN
                                 (LETT #5# NIL . #7#)
                                 (SEQ (LETT |i|
                                       (SPADCALL |hom| (QREFELT $ 73)) . #7#)
                                      (LETT #6#
                                       (SPADCALL |hom| (QREFELT $ 74)) . #7#)
                                      G190 (COND ((> |i| #6#) #8#))
                                      (SEQ
                                       (EXIT
                                        (LETT #5#
                                         (CONS
                                          (SPADCALL |hom| |i|
                                           (QREFELT $ 79))
                                          #5#) . #7#)))
                                      (LETT |i| (+ |i| 1) . #7#) #9#
                                      G191 (EXIT (NREVERSE0 #5#)))) . #7#)
                         (EXIT (COND
                                 (|part?| (CONS (CONS 0 |part|) |bas|))
                                 ('T (CONS (CONS 1 "failed") |bas|)))))))))))) 

(DEFUN |ODESYS;solveInField;MVMR;4| (|m| |v| |solve| $)
  (PROG (|n| #0=#:G1948 #1=#:G1949 |u| |uu| |rc| #2=#:G1950 |i|
             #3=#:G1951 #4=#:G1937 |rec|)
    (RETURN
      (SEQ (EXIT (SEQ (COND
                        ((EQL (LETT |n| (SPADCALL |m| (QREFELT $ 80))
                                    . #5=(|ODESYS;solveInField;MVMR;4|))
                              (SPADCALL |m| (QREFELT $ 81)))
                         (SEQ (LETT |u|
                                    (|ODESYS;M2F|
                                     (SPADCALL
                                      (SPADCALL
                                       (PRIMVEC2ARR
                                        (PROGN
                                          (LETT #0#
                                           (GETREFV |n|) . #5#)
                                          (SEQ (LETT #1# 0 . #5#)
                                           (LETT |i| 1 . #5#) G190
                                           (COND
                                             ((QSGREATERP |i| |n|)
                                              #6=(GO G191)))
                                           (SEQ
                                            (EXIT
                                             (SETELT #0# #1#
                                              (QREFELT $ 9))))
                                           (LETT |i|
                                            (PROG1 (QSADD1 |i|)
                                              (LETT #1#
                                               (QSADD1 #1#) . #5#)) . #5#)
                                           #7=(GO G190) G191
                                           (EXIT NIL))
                                          #0#))
                                       (QREFELT $ 82))
                                      |m| (QREFELT $ 83))
                                     $) . #5#)
                              (EXIT (COND
                                      ((QEQCAR |u| 0)
                                       (PROGN
                                         (LETT #4#
                                          (SEQ
                                           (LETT |uu|
                                            (SPADCALL (QCDR |u|) |v|
                                             (CONS
                                              #'|ODESYS;solveInField;MVMR;4!0|
                                              (VECTOR $ |solve|))
                                             (QREFELT $ 45)) . #5#)
                                           (EXIT
                                            (COND
                                              ((QEQCAR |uu| 1)
                                               (CONS (CONS 1 "failed")
                                                NIL))
                                              ('T
                                               (SEQ
                                                (LETT |rc|
                                                 (QCDR |uu|) . #5#)
                                                (EXIT
                                                 (CONS
                                                  (CONS 0 (QCAR |rc|))
                                                  (PROGN
                                                    (LETT #2#
                                                     NIL . #5#)
                                                    (SEQ
                                                     (LETT |i| 1 . #5#)
                                                     (LETT #3#
                                                      (SPADCALL
                                                       (QCDR |rc|)
                                                       (QREFELT $ 84)) . #5#)
                                                     G190
                                                     (COND
                                                       ((QSGREATERP |i|
                                                         #3#)
                                                        #6#))
                                                     (SEQ
                                                      (EXIT
                                                       (LETT #2#
                                                        (CONS
                                                         (SPADCALL
                                                          (QCDR |rc|)
                                                          |i|
                                                          (QREFELT $
                                                           79))
                                                         #2#) . #5#)))
                                                     (LETT |i|
                                                      (QSADD1 |i|) . #5#)
                                                     #7# G191
                                                     (EXIT
                                                      (NREVERSE0 #2#))))))))))) . #5#)
                                         (GO #4#))))))))
                      (LETT |rec|
                            (SPADCALL |m| |v| (QREFELT $ 86)) . #5#)
                      (EXIT (|ODESYS;backsolve| (QCAR |rec|)
                                (QCDR |rec|) |solve| $))))
           #4# (EXIT #4#))))) 

(DEFUN |ODESYS;solveInField;MVMR;4!0| (|#1| |#2| $$)
  (|ODESYS;FSL2USL| (SPADCALL |#1| |#2| (QREFELT $$ 1)) (QREFELT $$ 0))) 

(DEFUN |ODESYS;M2F| (|m| $)
  (PROG (|mf| |i| #0=#:G1963 |j| #1=#:G1964 |u| #2=#:G1962)
    (RETURN
      (SEQ (EXIT (SEQ (LETT |mf|
                            (SPADCALL (SPADCALL |m| (QREFELT $ 80))
                                (SPADCALL |m| (QREFELT $ 81))
                                (|spadConstant| $ 17) (QREFELT $ 27))
                            . #3=(|ODESYS;M2F|))
                      (SEQ (LETT |i|
                                 (SPADCALL |m| (QREFELT $ 65)) . #3#)
                           (LETT #0#
                                 (SPADCALL |m| (QREFELT $ 63)) . #3#)
                           G190 (COND ((> |i| #0#) #4=(GO G191)))
                           (SEQ (EXIT (SEQ
                                       (LETT |j|
                                        (SPADCALL |m| (QREFELT $ 93)) . #3#)
                                       (LETT #1#
                                        (SPADCALL |m| (QREFELT $ 71)) . #3#)
                                       G190 (COND ((> |j| #1#) #4#))
                                       (SEQ
                                        (LETT |u|
                                         (SPADCALL
                                          (SPADCALL |m| |i| |j|
                                           (QREFELT $ 72))
                                          (QREFELT $ 94)) . #3#)
                                        (EXIT
                                         (COND
                                           ((QEQCAR |u| 1)
                                            (PROGN
                                              (LETT #2#
                                               (CONS 1 "failed") . #3#)
                                              (GO #2#)))
                                           ('T
                                            (SPADCALL |mf| |i| |j|
                                             (QCDR |u|) (QREFELT $ 75))))))
                                       (LETT |j| (+ |j| 1) . #3#)
                                       #5=(GO G190) G191 (EXIT NIL))))
                           (LETT |i| (+ |i| 1) . #3#) #5# G191
                           (EXIT NIL))
                      (EXIT (CONS 0 |mf|))))
           #2# (EXIT #2#))))) 

(DEFUN |ODESYS;FSL2USL| (|rec| $)
  (PROG (#0=#:G1971)
    (RETURN
      (COND
        ((QEQCAR (QCAR |rec|) 1) (CONS 1 "failed"))
        ('T
         (CONS 0
               (CONS (PROG2 (LETT #0# (QCAR |rec|) |ODESYS;FSL2USL|)
                            (QCDR #0#)
                       (|check-union| (QEQCAR #0# 0) (QREFELT $ 6) #0#))
                     (QCDR |rec|)))))))) 

(DEFUN |ODESYS;firstnonzero| (|m| |r| $)
  (PROG (|c| #0=#:G1979 #1=#:G1978 #2=#:G1976)
    (RETURN
      (SEQ (EXIT (SEQ (SEQ (EXIT (SEQ (LETT |c|
                                       (SPADCALL |m| (QREFELT $ 93))
                                       . #3=(|ODESYS;firstnonzero|))
                                      (LETT #0#
                                       (SPADCALL |m| (QREFELT $ 71)) . #3#)
                                      G190
                                      (COND ((> |c| #0#) (GO G191)))
                                      (SEQ
                                       (EXIT
                                        (COND
                                          ((NULL
                                            (SPADCALL
                                             (SPADCALL |m| |r| |c|
                                              (QREFELT $ 72))
                                             (|spadConstant| $ 18)
                                             (QREFELT $ 95)))
                                           (PROGN
                                             (LETT #2#
                                              (PROGN
                                                (LETT #1# |c| . #3#)
                                                (GO #1#)) . #3#)
                                             (GO #2#))))))
                                      (LETT |c| (+ |c| 1) . #3#)
                                      (GO G190) G191 (EXIT NIL)))
                           #2# (EXIT #2#))
                      (EXIT (|error| "firstnonzero: zero row"))))
           #1# (EXIT #1#))))) 

(DEFUN |ODESYS;applyLodo| (|m| |r| |v| |n| $)
  (PROG (|i| |ans| |c| |cv|)
    (RETURN
      (SEQ (LETT |ans| (|spadConstant| $ 17) . #0=(|ODESYS;applyLodo|))
           (LETT |c| (SPADCALL |m| (QREFELT $ 71)) . #0#)
           (LETT |cv| (QVSIZE |v|) . #0#)
           (SEQ (LETT |i| 1 . #0#) G190
                (COND ((QSGREATERP |i| |n|) (GO G191)))
                (SEQ (LETT |ans|
                           (SPADCALL |ans|
                               (SPADCALL
                                   (SPADCALL |m| |r| |c|
                                    (QREFELT $ 72))
                                   (SPADCALL |v| |cv| (QREFELT $ 34))
                                   (QREFELT $ 35))
                               (QREFELT $ 60)) . #0#)
                     (LETT |c| (- |c| 1) . #0#)
                     (EXIT (LETT |cv| (- |cv| 1) . #0#)))
                (LETT |i| (QSADD1 |i|) . #0#) (GO G190) G191
                (EXIT NIL))
           (EXIT |ans|))))) 

(DEFUN |ODESYS;applyLodo0| (|m| |r| |mm| |c| |n| $)
  (PROG (|i| |ans| |cc| |rr|)
    (RETURN
      (SEQ (LETT |ans| (|spadConstant| $ 17)
                 . #0=(|ODESYS;applyLodo0|))
           (LETT |rr| (SPADCALL |mm| (QREFELT $ 96)) . #0#)
           (LETT |cc| (SPADCALL |m| (QREFELT $ 71)) . #0#)
           (SEQ (LETT |i| 1 . #0#) G190
                (COND ((QSGREATERP |i| |n|) (GO G191)))
                (SEQ (LETT |ans|
                           (SPADCALL |ans|
                               (SPADCALL
                                   (SPADCALL |m| |r| |cc|
                                    (QREFELT $ 72))
                                   (SPADCALL |mm| |rr| |c|
                                    (QREFELT $ 56))
                                   (QREFELT $ 35))
                               (QREFELT $ 60)) . #0#)
                     (LETT |cc| (- |cc| 1) . #0#)
                     (EXIT (LETT |rr| (- |rr| 1) . #0#)))
                (LETT |i| (QSADD1 |i|) . #0#) (GO G190) G191
                (EXIT NIL))
           (EXIT |ans|))))) 

(DEFUN |ODESYS;triangulate;MVR;10| (|m| |v| $)
  (PROG (|w| |nrows| |ncols| |minr| |offset| |j| #0=#:G2000 |rown| |x|
             |k| |l| |a| |b| |k1| |i|)
    (RETURN
      (SEQ (LETT |x| (SPADCALL |m| (QREFELT $ 97))
                 . #1=(|ODESYS;triangulate;MVR;10|))
           (LETT |w| (SPADCALL |v| (QREFELT $ 98)) . #1#)
           (LETT |nrows| (SPADCALL |x| (QREFELT $ 63)) . #1#)
           (LETT |ncols| (SPADCALL |x| (QREFELT $ 71)) . #1#)
           (LETT |minr|
                 (LETT |i| (SPADCALL |x| (QREFELT $ 65)) . #1#) . #1#)
           (LETT |offset|
                 (- (SPADCALL |w| (QREFELT $ 64)) |minr|) . #1#)
           (SEQ (EXIT (SEQ (LETT |j|
                                 (SPADCALL |x| (QREFELT $ 93)) . #1#)
                           G190 (COND ((> |j| |ncols|) #2=(GO G191)))
                           (SEQ (COND
                                  ((< |nrows| |i|)
                                   (PROGN
                                     (LETT #0# |x| . #1#)
                                     (GO #0#))))
                                (LETT |rown| (- |minr| 1) . #1#)
                                (SEQ (LETT |k| |i| . #1#) G190
                                     (COND ((> |k| |nrows|) #2#))
                                     (SEQ
                                      (COND
                                        ((NULL
                                          (SPADCALL
                                           (SPADCALL |x| |k| |j|
                                            (QREFELT $ 72))
                                           (|spadConstant| $ 18)
                                           (QREFELT $ 95)))
                                         (COND
                                           ((OR
                                             (EQL |rown| (- |minr| 1))
                                             (<
                                              (SPADCALL
                                               (SPADCALL |x| |k| |j|
                                                (QREFELT $ 72))
                                               (QREFELT $ 76))
                                              (SPADCALL
                                               (SPADCALL |x| |rown| |j|
                                                (QREFELT $ 72))
                                               (QREFELT $ 76))))
                                            (LETT |rown| |k| . #1#)))))
                                      (EXIT
                                       (COND
                                         ((EQL |rown| (- |minr| 1))
                                          "enuf")
                                         ('T
                                          (SEQ
                                           (LETT |x|
                                            (SPADCALL |x| |i| |rown|
                                             (QREFELT $ 99)) . #1#)
                                           (EXIT
                                            (SPADCALL |w|
                                             (+ |i| |offset|)
                                             (+ |rown| |offset|)
                                             (QREFELT $ 101))))))))
                                     (LETT |k| (+ |k| 1) . #1#)
                                     #3=(GO G190) G191 (EXIT NIL))
                                (SEQ (LETT |k| (+ |i| 1) . #1#) G190
                                     (COND ((> |k| |nrows|) #2#))
                                     (SEQ
                                      (EXIT
                                       (COND
                                         ((COND
                                            ((SPADCALL
                                              (SPADCALL |x| |k| |j|
                                               (QREFELT $ 72))
                                              (|spadConstant| $ 18)
                                              (QREFELT $ 95))
                                             'NIL)
                                            ('T 'T))
                                          (SEQ
                                           (LETT |l|
                                            (SPADCALL
                                             (SPADCALL |x| |i| |j|
                                              (QREFELT $ 72))
                                             (SPADCALL |x| |k| |j|
                                              (QREFELT $ 72))
                                             (QREFELT $ 102)) . #1#)
                                           (LETT |a|
                                            (SPADCALL |l|
                                             (SPADCALL |x| |i| |j|
                                              (QREFELT $ 72))
                                             (QREFELT $ 103)) . #1#)
                                           (LETT |b|
                                            (SPADCALL |l|
                                             (SPADCALL |x| |k| |j|
                                              (QREFELT $ 72))
                                             (QREFELT $ 103)) . #1#)
                                           (SEQ
                                            (LETT |k1| (+ |j| 1) . #1#)
                                            G190
                                            (COND
                                              ((> |k1| |ncols|) #2#))
                                            (SEQ
                                             (EXIT
                                              (SPADCALL |x| |k| |k1|
                                               (SPADCALL
                                                (SPADCALL |a|
                                                 (SPADCALL |x| |i| |k1|
                                                  (QREFELT $ 72))
                                                 (QREFELT $ 104))
                                                (SPADCALL |b|
                                                 (SPADCALL |x| |k| |k1|
                                                  (QREFELT $ 72))
                                                 (QREFELT $ 104))
                                                (QREFELT $ 59))
                                               (QREFELT $ 105))))
                                            (LETT |k1|
                                             (+ |k1| 1) . #1#)
                                            #3# G191 (EXIT NIL))
                                           (SPADCALL |x| |k| |j|
                                            (|spadConstant| $ 18)
                                            (QREFELT $ 105))
                                           (EXIT
                                            (SPADCALL |w|
                                             (+ |k| |offset|)
                                             (SPADCALL
                                              (SPADCALL |a|
                                               (SPADCALL |w|
                                                (+ |i| |offset|)
                                                (QREFELT $ 34))
                                               (QREFELT $ 35))
                                              (SPADCALL |b|
                                               (SPADCALL |w|
                                                (+ |k| |offset|)
                                                (QREFELT $ 34))
                                               (QREFELT $ 35))
                                              (QREFELT $ 37))
                                             (QREFELT $ 33))))))))
                                     (LETT |k| (+ |k| 1) . #1#) #3#
                                     G191 (EXIT NIL))
                                (EXIT (LETT |i| (+ |i| 1) . #1#)))
                           (LETT |j| (+ |j| 1) . #1#) #3# G191
                           (EXIT NIL)))
                #0# (EXIT #0#))
           (EXIT (CONS |x| |w|)))))) 

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

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

(MAKEPROP '|SystemODESolver| '|infovec|
    (LIST '#(NIL NIL NIL NIL NIL NIL (|local| |#1|) (|local| |#2|)
             (0 . D) '|diff|
             (|Record| (|:| C 12) (|:| |g| 13) (|:| |eq| 7)
                 (|:| |rh| 6))
             (|Record| (|:| A 12) (|:| |eqs| 31)) (|Matrix| 6)
             (|Vector| 6) |ODESYS;triangulate;MVR;2|
             (|NonNegativeInteger|) (4 . |nrows|) (9 . |Zero|)
             (13 . |Zero|) (17 . |new|) (|Boolean|) (23 . =)
             (29 . |false|) (33 . |true|) (|Mapping| 20 6) (|List| 6)
             (37 . |count|) (43 . |new|) (50 . |One|) (54 . |One|)
             (|Integer|) (|List| 10) (58 . |elt|) (64 . |setelt|)
             (71 . |elt|) (77 . |elt|) (83 . |setColumn!|) (90 . -)
             (96 . *) (102 . *)
             (|Record| (|:| |particular| 13) (|:| |basis| 12))
             (|Union| 40 '"failed")
             (|Record| (|:| |particular| 6) (|:| |basis| 25))
             (|Union| 42 '"failed") (|Mapping| 43 7 6)
             |ODESYS;solve;MVMU;1| (|Automorphism| 6) (108 . |One|)
             (112 . -) (|Record| (|:| R 12) (|:| A 12) (|:| |Ainv| 12))
             (|Mapping| 6 6) (|PseudoLinearNormalForm| 6)
             (117 . |normalForm|) (|Record| (|:| C 12) (|:| |g| 13))
             (|List| 53) (124 . |companionBlocks|) (130 . |elt|)
             (137 . |monomial|) (143 . +) (149 . -) (155 . +) (161 . *)
             (|Matrix| 7) (167 . |maxRowIndex|) (172 . |minIndex|)
             (177 . |minRowIndex|) (182 . |zero?|) (|Vector| 7)
             (187 . |row|) (|Mapping| 20 7) (193 . |every?|)
             (199 . |maxColIndex|) (204 . |elt|) (211 . |minColIndex|)
             (216 . |maxColIndex|) (221 . |setelt|) (229 . |degree|)
             (234 . |leadingCoefficient|) (239 . /) (245 . |column|)
             (251 . |nrows|) (256 . |ncols|) (261 . |diagonalMatrix|)
             (266 . -) (272 . |ncols|)
             (|Record| (|:| |mat| 62) (|:| |vec| 13))
             |ODESYS;triangulate;MVR;10| (|Union| 13 '"failed")
             (|Record| (|:| |particular| 87) (|:| |basis| (|List| 13)))
             (|Union| 6 '"failed")
             (|Record| (|:| |particular| 89) (|:| |basis| 25))
             (|Mapping| 90 7 6) |ODESYS;solveInField;MVMR;4|
             (277 . |minColIndex|) (282 . |retractIfCan|) (287 . =)
             (293 . |maxRowIndex|) (298 . |copy|) (303 . |copy|)
             (308 . |swapRows!|) (|Void|) (315 . |swap!|)
             (322 . |rightLcm|) (328 . |rightQuotient|) (334 . *)
             (340 . |setelt|))
          '#(|triangulate| 348 |solveInField| 360 |solve| 367) 'NIL
          (CONS (|makeByteWordVec2| 1 'NIL)
                (CONS '#()
                      (CONS '#()
                            (|makeByteWordVec2| 105
                                '(0 7 0 8 1 12 15 0 16 0 6 0 17 0 7 0
                                  18 2 13 0 15 6 19 2 6 20 0 0 21 0 20
                                  0 22 0 20 0 23 2 25 15 24 0 26 3 12 0
                                  15 15 6 27 0 6 0 28 0 7 0 29 2 31 10
                                  0 30 32 3 13 6 0 30 6 33 2 13 6 0 30
                                  34 2 7 6 0 6 35 3 12 0 0 30 13 36 2 6
                                  0 0 0 37 2 12 13 0 13 38 2 12 0 0 0
                                  39 0 46 0 47 1 6 0 0 48 3 51 49 12 46
                                  50 52 2 51 54 12 13 55 3 12 6 0 30 30
                                  56 2 7 0 6 15 57 2 7 0 0 0 58 2 7 0 0
                                  0 59 2 6 0 0 0 60 2 6 0 0 0 61 1 62
                                  30 0 63 1 13 30 0 64 1 62 30 0 65 1 7
                                  20 0 66 2 62 67 0 30 68 2 67 20 69 0
                                  70 1 62 30 0 71 3 62 7 0 30 30 72 1
                                  12 30 0 73 1 12 30 0 74 4 12 6 0 30
                                  30 6 75 1 7 15 0 76 1 7 6 0 77 2 6 0
                                  0 0 78 2 12 13 0 30 79 1 62 15 0 80 1
                                  62 15 0 81 1 62 0 67 82 2 62 0 0 0 83
                                  1 12 15 0 84 1 62 30 0 93 1 7 89 0 94
                                  2 7 20 0 0 95 1 12 30 0 96 1 62 0 0
                                  97 1 13 0 0 98 3 62 0 0 30 30 99 3 13
                                  100 0 30 30 101 2 7 0 0 0 102 2 7 0 0
                                  0 103 2 7 0 0 0 104 4 62 7 0 30 30 7
                                  105 2 0 85 62 13 86 2 0 11 12 13 14 3
                                  0 88 62 13 91 92 3 0 41 12 13 44 45)))))
          '|lookupComplete|)) 
