dbleSCHUR.h

Go to the documentation of this file.
00001 /*
00002 
00003 Copyright (C) 1994-2012 John W. Eaton
00004 
00005 This file is part of Octave.
00006 
00007 Octave is free software; you can redistribute it and/or modify it
00008 under the terms of the GNU General Public License as published by the
00009 Free Software Foundation; either version 3 of the License, or (at your
00010 option) any later version.
00011 
00012 Octave is distributed in the hope that it will be useful, but WITHOUT
00013 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
00014 FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
00015 for more details.
00016 
00017 You should have received a copy of the GNU General Public License
00018 along with Octave; see the file COPYING.  If not, see
00019 <http://www.gnu.org/licenses/>.
00020 
00021 */
00022 
00023 #if !defined (octave_SCHUR_h)
00024 #define octave_SCHUR_h 1
00025 
00026 #include <iosfwd>
00027 #include <string>
00028 
00029 #include "dMatrix.h"
00030 
00031 class
00032 OCTAVE_API
00033 SCHUR
00034 {
00035 public:
00036 
00037   SCHUR (void) : schur_mat (), unitary_mat (), selector (0) { }
00038 
00039   SCHUR (const Matrix& a, const std::string& ord, bool calc_unitary = true)
00040     : schur_mat (), unitary_mat (), selector (0)
00041     {
00042       init (a, ord, calc_unitary);
00043     }
00044 
00045   SCHUR (const Matrix& a, const std::string& ord, int& info,
00046          bool calc_unitary = true)
00047     : schur_mat (), unitary_mat (), selector (0)
00048     {
00049       info = init (a, ord, calc_unitary);
00050     }
00051 
00052   SCHUR (const SCHUR& a)
00053     : schur_mat (a.schur_mat), unitary_mat (a.unitary_mat), selector (0)
00054     { }
00055 
00056   SCHUR (const Matrix& s, const Matrix& u);
00057 
00058   SCHUR& operator = (const SCHUR& a)
00059     {
00060       if (this != &a)
00061         {
00062           schur_mat = a.schur_mat;
00063           unitary_mat = a.unitary_mat;
00064         }
00065       return *this;
00066     }
00067 
00068   ~SCHUR (void) { }
00069 
00070   Matrix schur_matrix (void) const { return schur_mat; }
00071 
00072   Matrix unitary_matrix (void) const { return unitary_mat; }
00073 
00074   friend std::ostream& operator << (std::ostream& os, const SCHUR& a);
00075 
00076   typedef octave_idx_type (*select_function) (const double&, const double&);
00077 
00078 private:
00079 
00080   Matrix schur_mat;
00081   Matrix unitary_mat;
00082 
00083   select_function selector;
00084 
00085   octave_idx_type init (const Matrix& a, const std::string& ord, bool calc_unitary);
00086 };
00087 
00088 #endif
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Friends Defines