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 |
|
26 #if defined (__GNUG__) |
|
27 #pragma interface |
|
28 #endif |
|
29 |
1872
|
30 #include <cfloat> |
1867
|
31 #include <cmath> |
|
32 |
1841
|
33 #include "ODE.h" |
|
34 |
3998
|
35 #include "LSODE-opts.h" |
1841
|
36 |
1867
|
37 class |
|
38 LSODE : public ODE, public LSODE_options |
1841
|
39 { |
|
40 public: |
|
41 |
|
42 LSODE (void); |
|
43 |
|
44 LSODE (int n); |
|
45 |
|
46 LSODE (const ColumnVector& state, double time, const ODEFunc& f); |
|
47 |
1945
|
48 ~LSODE (void) { } |
1841
|
49 |
|
50 ColumnVector do_integrate (double t); |
|
51 |
|
52 Matrix do_integrate (const ColumnVector& tout); |
|
53 |
3511
|
54 Matrix do_integrate (const ColumnVector& tout, const ColumnVector& tcrit); |
1841
|
55 |
3959
|
56 std::string error_message (void) const; |
|
57 |
1841
|
58 private: |
|
59 |
|
60 int n; |
3955
|
61 int method_flag; |
1945
|
62 Array<int> iwork; |
|
63 Array<double> rwork; |
1841
|
64 int itask; |
3955
|
65 int iopt; |
1841
|
66 int liw; |
|
67 int lrw; |
3995
|
68 bool sanity_checked; |
1841
|
69 |
|
70 friend int lsode_f (int *neq, double *t, double *y, double *ydot); |
|
71 |
|
72 friend int lsode_j (int *neq, double *t, double *y, int *ml, int *mu, |
|
73 double *pd, int *nrowpd); |
|
74 }; |
|
75 |
|
76 #endif |
|
77 |
|
78 /* |
|
79 ;;; Local Variables: *** |
|
80 ;;; mode: C++ *** |
|
81 ;;; End: *** |
|
82 */ |