In documentation for lreduce and rreduce, supply second argument as an explicit list
[maxima.git] / share / odepack / src / dhesl.lisp
blob2e683c3d9aea5cbe99d0cdb20dd1fff8ad65ddfc
1 ;;; Compiled by f2cl version:
2 ;;; ("f2cl1.l,v 95098eb54f13 2013/04/01 00:45:16 toy $"
3 ;;; "f2cl2.l,v 95098eb54f13 2013/04/01 00:45:16 toy $"
4 ;;; "f2cl3.l,v 96616d88fb7e 2008/02/22 22:19:34 rtoy $"
5 ;;; "f2cl4.l,v 96616d88fb7e 2008/02/22 22:19:34 rtoy $"
6 ;;; "f2cl5.l,v 95098eb54f13 2013/04/01 00:45:16 toy $"
7 ;;; "f2cl6.l,v 1d5cbacbb977 2008/08/24 00:56:27 rtoy $"
8 ;;; "macros.l,v 1409c1352feb 2013/03/24 20:44:50 toy $")
10 ;;; Using Lisp CMU Common Lisp snapshot-2013-11 (20E Unicode)
11 ;;;
12 ;;; Options: ((:prune-labels nil) (:auto-save t) (:relaxed-array-decls t)
13 ;;; (:coerce-assigns :as-needed) (:array-type ':array)
14 ;;; (:array-slicing t) (:declare-common nil)
15 ;;; (:float-format single-float))
17 (in-package "ODEPACK")
20 (defun dhesl (a lda n ipvt b)
21 (declare (type (array f2cl-lib:integer4 (*)) ipvt)
22 (type (f2cl-lib:integer4) n lda)
23 (type (array double-float (*)) b a))
24 (f2cl-lib:with-multi-array-data
25 ((a double-float a-%data% a-%offset%)
26 (b double-float b-%data% b-%offset%)
27 (ipvt f2cl-lib:integer4 ipvt-%data% ipvt-%offset%))
28 (prog ((k 0) (kb 0) (l 0) (nm1 0) (t$ 0.0d0))
29 (declare (type (double-float) t$) (type (f2cl-lib:integer4) nm1 l kb k))
30 (setf nm1 (f2cl-lib:int-sub n 1))
31 (if (< nm1 1) (go label30))
32 (f2cl-lib:fdo (k 1 (f2cl-lib:int-add k 1))
33 ((> k nm1) nil)
34 (tagbody
35 (setf l (f2cl-lib:fref ipvt-%data% (k) ((1 *)) ipvt-%offset%))
36 (setf t$ (f2cl-lib:fref b-%data% (l) ((1 *)) b-%offset%))
37 (if (= l k) (go label10))
38 (setf (f2cl-lib:fref b-%data% (l) ((1 *)) b-%offset%)
39 (f2cl-lib:fref b-%data% (k) ((1 *)) b-%offset%))
40 (setf (f2cl-lib:fref b-%data% (k) ((1 *)) b-%offset%) t$)
41 label10
42 (setf (f2cl-lib:fref b-%data%
43 ((f2cl-lib:int-add k 1))
44 ((1 *))
45 b-%offset%)
47 (f2cl-lib:fref b-%data%
48 ((f2cl-lib:int-add k 1))
49 ((1 *))
50 b-%offset%)
51 (* t$
52 (f2cl-lib:fref a-%data%
53 ((f2cl-lib:int-add k 1) k)
54 ((1 lda) (1 *))
55 a-%offset%))))
56 label20))
57 label30
58 (f2cl-lib:fdo (kb 1 (f2cl-lib:int-add kb 1))
59 ((> kb n) nil)
60 (tagbody
61 (setf k (f2cl-lib:int-sub (f2cl-lib:int-add n 1) kb))
62 (setf (f2cl-lib:fref b-%data% (k) ((1 *)) b-%offset%)
63 (/ (f2cl-lib:fref b-%data% (k) ((1 *)) b-%offset%)
64 (f2cl-lib:fref a-%data%
65 (k k)
66 ((1 lda) (1 *))
67 a-%offset%)))
68 (setf t$ (- (f2cl-lib:fref b-%data% (k) ((1 *)) b-%offset%)))
69 (daxpy (f2cl-lib:int-sub k 1) t$
70 (f2cl-lib:array-slice a-%data%
71 double-float
72 (1 k)
73 ((1 lda) (1 *))
74 a-%offset%)
76 (f2cl-lib:array-slice b-%data% double-float (1) ((1 *)) b-%offset%)
78 label40))
79 (go end_label)
80 end_label
81 (return (values nil nil nil nil nil)))))
83 (in-package #:cl-user)
84 #+#.(cl:if (cl:find-package '#:f2cl) '(and) '(or))
85 (eval-when (:load-toplevel :compile-toplevel :execute)
86 (setf (gethash 'fortran-to-lisp::dhesl fortran-to-lisp::*f2cl-function-info*)
87 (fortran-to-lisp::make-f2cl-finfo
88 :arg-types '((array double-float (*)) (fortran-to-lisp::integer4)
89 (fortran-to-lisp::integer4)
90 (array fortran-to-lisp::integer4 (*))
91 (array double-float (*)))
92 :return-values '(nil nil nil nil nil)
93 :calls '(fortran-to-lisp::daxpy))))