1841
|
1 /* |
|
2 |
2847
|
3 Copyright (C) 1996, 1997 John W. Eaton |
1841
|
4 |
|
5 This file is part of Octave. |
|
6 |
|
7 Octave is free software; you can redistribute it and/or modify it |
|
8 under the terms of the GNU General Public License as published by the |
|
9 Free Software Foundation; either version 2, or (at your option) any |
|
10 later version. |
|
11 |
|
12 Octave is distributed in the hope that it will be useful, but WITHOUT |
|
13 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
|
14 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License |
|
15 for more details. |
|
16 |
|
17 You should have received a copy of the GNU General Public License |
|
18 along with Octave; see the file COPYING. If not, write to the Free |
|
19 Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
|
20 |
|
21 */ |
|
22 |
|
23 #if !defined (octave_LSODE_h) |
|
24 #define octave_LSODE_h 1 |
|
25 |
4192
|
26 #if defined (__GNUG__) && defined (USE_PRAGMA_INTERFACE_IMPLEMENTATION) |
1841
|
27 #pragma interface |
|
28 #endif |
|
29 |
1872
|
30 #include <cfloat> |
1867
|
31 #include <cmath> |
|
32 |
3998
|
33 #include "LSODE-opts.h" |
1841
|
34 |
1867
|
35 class |
|
36 LSODE : public ODE, public LSODE_options |
1841
|
37 { |
|
38 public: |
|
39 |
4049
|
40 LSODE (void) : ODE (), LSODE_options (), initialized (false) { } |
1841
|
41 |
4049
|
42 LSODE (const ColumnVector& state, double time, const ODEFunc& f) |
|
43 : ODE (state, time, f), LSODE_options (), initialized (false) { } |
1841
|
44 |
1945
|
45 ~LSODE (void) { } |
1841
|
46 |
|
47 ColumnVector do_integrate (double t); |
|
48 |
|
49 Matrix do_integrate (const ColumnVector& tout); |
|
50 |
3511
|
51 Matrix do_integrate (const ColumnVector& tout, const ColumnVector& tcrit); |
1841
|
52 |
3959
|
53 std::string error_message (void) const; |
|
54 |
1841
|
55 private: |
|
56 |
4049
|
57 bool initialized; |
|
58 |
3955
|
59 int method_flag; |
1841
|
60 int itask; |
3955
|
61 int iopt; |
4049
|
62 int itol; |
|
63 |
1841
|
64 int liw; |
|
65 int lrw; |
4049
|
66 |
|
67 Array<int> iwork; |
|
68 Array<double> rwork; |
|
69 |
|
70 double rel_tol; |
1841
|
71 |
4049
|
72 Array<double> abs_tol; |
1841
|
73 |
4049
|
74 double *px; |
|
75 double *pabs_tol; |
|
76 int *piwork; |
|
77 double *prwork; |
1841
|
78 }; |
|
79 |
|
80 #endif |
|
81 |
|
82 /* |
|
83 ;;; Local Variables: *** |
|
84 ;;; mode: C++ *** |
|
85 ;;; End: *** |
|
86 */ |