GNU Octave  3.8.0
A high-level interpreted language, primarily intended for numerical computations, mostly compatible with Matlab
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
fCmplxSCHUR.h
Go to the documentation of this file.
1 /*
2 
3 Copyright (C) 1994-2013 John W. Eaton
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 3 of the License, or (at your
10 option) any 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, see
19 <http://www.gnu.org/licenses/>.
20 
21 */
22 
23 #if !defined (octave_fCmplxSCHUR_h)
24 #define octave_fCmplxSCHUR_h 1
25 
26 #include <iosfwd>
27 #include <string>
28 
29 #include "fCMatrix.h"
30 #include "floatSCHUR.h"
31 
32 class
33 OCTAVE_API
35 {
36 public:
37 
38  FloatComplexSCHUR (void) : schur_mat (), unitary_mat (), selector (0) { }
39 
40  FloatComplexSCHUR (const FloatComplexMatrix& a, const std::string& ord,
41  bool calc_unitary = true)
42  : schur_mat (), unitary_mat (), selector (0)
43  {
44  init (a, ord, calc_unitary);
45  }
46 
47  FloatComplexSCHUR (const FloatComplexMatrix& a, const std::string& ord,
48  octave_idx_type& info, bool calc_unitary = true)
49  : schur_mat (), unitary_mat (), selector (0)
50  {
51  info = init (a, ord, calc_unitary);
52  }
53 
55  : schur_mat (a.schur_mat), unitary_mat (a.unitary_mat), selector (0)
56  { }
57 
59 
60  FloatComplexSCHUR (const FloatSCHUR& s);
61 
63  {
64  if (this != &a)
65  {
66  schur_mat = a.schur_mat;
67  unitary_mat = a.unitary_mat;
68  }
69  return *this;
70  }
71 
72  ~FloatComplexSCHUR (void) { }
73 
74  FloatComplexMatrix schur_matrix (void) const { return schur_mat; }
75 
76  FloatComplexMatrix unitary_matrix (void) const { return unitary_mat; }
77 
78  friend std::ostream& operator << (std::ostream& os,
79  const FloatComplexSCHUR& a);
80 
81  typedef octave_idx_type (*select_function) (const FloatComplex&);
82 
83 private:
84 
87 
88  select_function selector;
89 
90  octave_idx_type init (const FloatComplexMatrix& a, const std::string& ord,
91  bool calc_unitary);
92 };
93 
94 #endif