457
|
1 /* |
|
2 |
2847
|
3 Copyright (C) 1996, 1997 John W. Eaton |
457
|
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 |
1315
|
19 Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
457
|
20 |
|
21 */ |
|
22 |
|
23 #if !defined (octave_ComplexDET_h) |
|
24 #define octave_ComplexDET_h 1 |
|
25 |
3503
|
26 #include <iostream> |
457
|
27 |
1650
|
28 #include "oct-cmplx.h" |
457
|
29 |
1881
|
30 class |
|
31 ComplexDET |
457
|
32 { |
1881
|
33 friend class ComplexMatrix; |
5164
|
34 friend class SparseComplexMatrix; |
532
|
35 |
457
|
36 public: |
|
37 |
1528
|
38 ComplexDET (void) { } |
|
39 |
|
40 ComplexDET (const ComplexDET& a) |
|
41 { |
|
42 det[0] = a.det[0]; |
|
43 det[1] = a.det[1]; |
|
44 } |
457
|
45 |
1528
|
46 ComplexDET& operator = (const ComplexDET& a) |
|
47 { |
1881
|
48 if (this != &a) |
|
49 { |
|
50 det[0] = a.det[0]; |
|
51 det[1] = a.det[1]; |
|
52 } |
1528
|
53 return *this; |
|
54 } |
457
|
55 |
|
56 int value_will_overflow (void) const; |
|
57 int value_will_underflow (void) const; |
1528
|
58 |
457
|
59 Complex coefficient (void) const; |
1528
|
60 |
457
|
61 int exponent (void) const; |
1528
|
62 |
457
|
63 Complex value (void) const; |
|
64 |
3504
|
65 friend std::ostream& operator << (std::ostream& os, const ComplexDET& a); |
457
|
66 |
|
67 private: |
|
68 |
1528
|
69 ComplexDET (const Complex *d) |
|
70 { |
|
71 det[0] = d[0]; |
|
72 det[1] = d[1]; |
|
73 } |
457
|
74 |
|
75 Complex det [2]; |
|
76 }; |
|
77 |
|
78 #endif |
|
79 |
|
80 /* |
|
81 ;;; Local Variables: *** |
|
82 ;;; mode: C++ *** |
|
83 ;;; End: *** |
|
84 */ |