3
|
1 /* |
|
2 |
2847
|
3 Copyright (C) 1996, 1997 John W. Eaton |
3
|
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 |
7016
|
9 Free Software Foundation; either version 3 of the License, or (at your |
|
10 option) any later version. |
3
|
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 |
7016
|
18 along with Octave; see the file COPYING. If not, see |
|
19 <http://www.gnu.org/licenses/>. |
3
|
20 |
|
21 */ |
|
22 |
382
|
23 #if !defined (octave_NLConst_h) |
|
24 #define octave_NLConst_h 1 |
|
25 |
465
|
26 class ColumnVector; |
|
27 |
238
|
28 #include "Bounds.h" |
3
|
29 #include "NLFunc.h" |
|
30 |
1865
|
31 class |
|
32 NLConst : public Bounds, public NLFunc |
3
|
33 { |
|
34 public: |
|
35 |
1865
|
36 NLConst (void) |
|
37 : Bounds (), NLFunc () { } |
1528
|
38 |
5275
|
39 NLConst (octave_idx_type n) |
1865
|
40 : Bounds (n), NLFunc () { } |
1528
|
41 |
|
42 NLConst (const ColumnVector& lb, const NLFunc f, const ColumnVector& ub) |
|
43 : Bounds (lb, ub), NLFunc (f) { } |
|
44 |
1865
|
45 NLConst (const NLConst& a) |
|
46 : Bounds (a.lb, a.ub), NLFunc (a.fun, a.jac) { } |
3
|
47 |
1528
|
48 NLConst& operator = (const NLConst& a) |
|
49 { |
1865
|
50 if (this != &a) |
|
51 { |
|
52 Bounds::operator = (a); |
|
53 NLFunc::operator = (a); |
|
54 } |
1528
|
55 return *this; |
|
56 } |
3
|
57 |
1865
|
58 ~NLConst (void) { } |
|
59 |
3
|
60 private: |
|
61 |
|
62 void error (const char *msg); |
|
63 }; |
|
64 |
|
65 #endif |
|
66 |
|
67 /* |
|
68 ;;; Local Variables: *** |
|
69 ;;; mode: C++ *** |
|
70 ;;; End: *** |
|
71 */ |