OSSIM - Open Source Software Image Map  Version 1.9.0 (20180803)
Public Member Functions | Private Member Functions | List of all members
SquareMatrix Class Reference

#include <newmat.h>

Inheritance diagram for SquareMatrix:
Matrix GeneralMatrix BaseMatrix

Public Member Functions

 SquareMatrix ()
 
 ~SquareMatrix ()
 
 SquareMatrix (ArrayLengthSpecifier)
 
 SquareMatrix (const BaseMatrix &)
 
void operator= (const BaseMatrix &)
 
void operator= (Real f)
 
void operator= (const SquareMatrix &m)
 
void operator= (const Matrix &m)
 
MatrixType Type () const
 
 SquareMatrix (const SquareMatrix &gm)
 
 SquareMatrix (const Matrix &gm)
 
void ReSize (int)
 
virtual void ReSize (int, int)
 
void ReSize (const GeneralMatrix &A)
 
void operator+= (const Matrix &M)
 
void operator-= (const Matrix &M)
 
void operator+= (Real f)
 
void operator-= (Real f)
 
- Public Member Functions inherited from Matrix
 Matrix ()
 
 ~Matrix ()
 
 Matrix (int, int)
 
 Matrix (const BaseMatrix &)
 
void operator= (const BaseMatrix &)
 
void operator= (Real f)
 
void operator= (const Matrix &m)
 
Real & operator() (int, int)
 
Real & element (int, int)
 
Real operator() (int, int) const
 
Real element (int, int) const
 
 Matrix (const Matrix &gm)
 
GeneralMatrixMakeSolver ()
 
Real Trace () const
 
void GetRow (MatrixRowCol &)
 
void GetCol (MatrixRowCol &)
 
void GetCol (MatrixColX &)
 
void RestoreCol (MatrixRowCol &)
 
void RestoreCol (MatrixColX &)
 
void NextRow (MatrixRowCol &)
 
void NextCol (MatrixRowCol &)
 
void NextCol (MatrixColX &)
 
Real MaximumAbsoluteValue2 (int &i, int &j) const
 
Real MinimumAbsoluteValue2 (int &i, int &j) const
 
Real Maximum2 (int &i, int &j) const
 
Real Minimum2 (int &i, int &j) const
 
void operator+= (const Matrix &M)
 
void operator-= (const Matrix &M)
 
void operator+= (Real f)
 
void operator-= (Real f)
 
- Public Member Functions inherited from GeneralMatrix
GeneralMatrixEvaluate (MatrixType mt=MatrixTypeUnSp)
 
int Nrows () const
 
int Ncols () const
 
int Storage () const
 
RealStore () const
 
virtual ~GeneralMatrix ()
 
void tDelete ()
 
bool reuse ()
 
void Protect ()
 
int Tag () const
 
bool IsZero () const
 
void Release ()
 
void Release (int t)
 
void ReleaseAndDelete ()
 
void operator<< (const Real *)
 
void operator<< (const int *)
 
void operator<< (const BaseMatrix &X)
 
void Inject (const GeneralMatrix &)
 
void operator+= (const BaseMatrix &)
 
void operator-= (const BaseMatrix &)
 
void operator*= (const BaseMatrix &)
 
void operator|= (const BaseMatrix &)
 
void operator &= (const BaseMatrix &)
 
void operator+= (Real)
 
void operator-= (Real r)
 
void operator*= (Real)
 
void operator/= (Real r)
 
virtual void Solver (MatrixColX &, const MatrixColX &)
 
virtual void RestoreRow (MatrixRowCol &)
 
Real SumSquare () const
 
Real SumAbsoluteValue () const
 
Real Sum () const
 
Real MaximumAbsoluteValue1 (int &i) const
 
Real MinimumAbsoluteValue1 (int &i) const
 
Real Maximum1 (int &i) const
 
Real Minimum1 (int &i) const
 
Real MaximumAbsoluteValue () const
 
Real MinimumAbsoluteValue () const
 
Real Maximum () const
 
Real Minimum () const
 
LogAndSign LogDeterminant () const
 
virtual bool IsEqual (const GeneralMatrix &) const
 
void CheckStore () const
 
virtual void SetParameters (const GeneralMatrix *)
 
 operator ReturnMatrix () const
 
ReturnMatrix ForReturn () const
 
virtual bool SameStorageType (const GeneralMatrix &A) const
 
virtual void ReSizeForAdd (const GeneralMatrix &A, const GeneralMatrix &B)
 
virtual void ReSizeForSP (const GeneralMatrix &A, const GeneralMatrix &B)
 
MatrixInput operator<< (Real)
 
MatrixInput operator<< (int f)
 
void CleanUp ()
 
- Public Member Functions inherited from BaseMatrix
AddedMatrix operator+ (const BaseMatrix &) const
 
MultipliedMatrix operator* (const BaseMatrix &) const
 
SubtractedMatrix operator- (const BaseMatrix &) const
 
ConcatenatedMatrix operator| (const BaseMatrix &) const
 
StackedMatrix operator & (const BaseMatrix &) const
 
ShiftedMatrix operator+ (Real) const
 
ScaledMatrix operator* (Real) const
 
ScaledMatrix operator/ (Real) const
 
ShiftedMatrix operator- (Real) const
 
TransposedMatrix t () const
 
NegatedMatrix operator- () const
 
ReversedMatrix Reverse () const
 
InvertedMatrix i () const
 
RowedMatrix AsRow () const
 
ColedMatrix AsColumn () const
 
DiagedMatrix AsDiagonal () const
 
MatedMatrix AsMatrix (int, int) const
 
GetSubMatrix SubMatrix (int, int, int, int) const
 
GetSubMatrix SymSubMatrix (int, int) const
 
GetSubMatrix Row (int) const
 
GetSubMatrix Rows (int, int) const
 
GetSubMatrix Column (int) const
 
GetSubMatrix Columns (int, int) const
 
Real AsScalar () const
 
Real Determinant () const
 
Real NormFrobenius () const
 
Real Norm1 () const
 
Real NormInfinity () const
 
virtual MatrixBandWidth BandWidth () const
 
void IEQND () const
 

Private Member Functions

GeneralMatrixImage () const
 

Additional Inherited Members

- Protected Member Functions inherited from GeneralMatrix
 GeneralMatrix ()
 
 GeneralMatrix (ArrayLengthSpecifier)
 
void Add (GeneralMatrix *, Real)
 
void Add (Real)
 
void NegAdd (GeneralMatrix *, Real)
 
void NegAdd (Real)
 
void Multiply (GeneralMatrix *, Real)
 
void Multiply (Real)
 
void Negate (GeneralMatrix *)
 
void Negate ()
 
void ReverseElements ()
 
void ReverseElements (GeneralMatrix *)
 
void operator= (Real)
 
Real * GetStore ()
 
GeneralMatrixBorrowStore (GeneralMatrix *, MatrixType)
 
void GetMatrix (const GeneralMatrix *)
 
void Eq (const BaseMatrix &, MatrixType)
 
void Eq (const GeneralMatrix &)
 
void Eq (const BaseMatrix &, MatrixType, bool)
 
void Eq2 (const BaseMatrix &, MatrixType)
 
int search (const BaseMatrix *) const
 
virtual GeneralMatrixTranspose (TransposedMatrix *, MatrixType)
 
void CheckConversion (const BaseMatrix &)
 
void ReSize (int, int, int)
 
virtual short SimpleAddOK (const GeneralMatrix *)
 
virtual void MiniCleanUp ()
 
void PlusEqual (const GeneralMatrix &gm)
 
void MinusEqual (const GeneralMatrix &gm)
 
void PlusEqual (Real f)
 
void MinusEqual (Real f)
 
- Protected Attributes inherited from GeneralMatrix
int tag
 
int nrows
 
int ncols
 
int storage
 
Realstore
 

Detailed Description

Definition at line 589 of file newmat.h.

Constructor & Destructor Documentation

◆ SquareMatrix() [1/5]

SquareMatrix::SquareMatrix ( )
inline

Definition at line 593 of file newmat.h.

Referenced by Image().

593 {}

◆ ~SquareMatrix()

SquareMatrix::~SquareMatrix ( )
inline

Definition at line 594 of file newmat.h.

594 {}

◆ SquareMatrix() [2/5]

SquareMatrix::SquareMatrix ( ArrayLengthSpecifier  n)

Definition at line 51 of file newmat4.cpp.

References REPORT.

52  : Matrix(n.Value(),n.Value())
53 { REPORT }
Matrix()
Definition: newmat.h:547
#define REPORT
Definition: newmat4.cpp:19
os2<< "> n<< " > nendobj n

◆ SquareMatrix() [3/5]

SquareMatrix::SquareMatrix ( const BaseMatrix M)

Definition at line 78 of file newmat4.cpp.

References GeneralMatrix::ncols, GeneralMatrix::nrows, and REPORT.

78  : Matrix(M)
79 {
80  REPORT
81  if (ncols != nrows)
82  {
83  Tracer tr("SquareMatrix");
84  Throw(NotSquareException(*this));
85  }
86 }
Matrix()
Definition: newmat.h:547
#define REPORT
Definition: newmat4.cpp:19

◆ SquareMatrix() [4/5]

SquareMatrix::SquareMatrix ( const SquareMatrix gm)
inline

Definition at line 602 of file newmat.h.

602 :Matrix(gm) { GetMatrix(&gm); }
Matrix()
Definition: newmat.h:547
void GetMatrix(const GeneralMatrix *)
Definition: newmat4.cpp:610

◆ SquareMatrix() [5/5]

SquareMatrix::SquareMatrix ( const Matrix gm)

Definition at line 89 of file newmat4.cpp.

References GeneralMatrix::GetMatrix(), GeneralMatrix::ncols, GeneralMatrix::nrows, and REPORT.

90 {
91  REPORT
92  if (gm.ncols != gm.nrows)
93  {
94  Tracer tr("SquareMatrix(Matrix)");
95  Throw(NotSquareException(gm));
96  }
97  GetMatrix(&gm);
98 }
#define REPORT
Definition: newmat4.cpp:19
void GetMatrix(const GeneralMatrix *)
Definition: newmat4.cpp:610

Member Function Documentation

◆ Image()

GeneralMatrix * SquareMatrix::Image ( ) const
privatevirtual

Reimplemented from Matrix.

Definition at line 747 of file newmat4.cpp.

References MatrixErrorNoSpace(), REPORT, and SquareMatrix().

748 {
749  REPORT
750  GeneralMatrix* gm = new SquareMatrix(*this); MatrixErrorNoSpace(gm);
751  return gm;
752 }
SquareMatrix()
Definition: newmat.h:593
void MatrixErrorNoSpace(const void *)
Definition: newmatex.cpp:292
#define REPORT
Definition: newmat4.cpp:19

◆ operator+=() [1/2]

void SquareMatrix::operator+= ( const Matrix M)
inline

Definition at line 608 of file newmat.h.

608 { PlusEqual(M); }
void PlusEqual(const GeneralMatrix &gm)
Definition: newmat7.cpp:148

◆ operator+=() [2/2]

void SquareMatrix::operator+= ( Real  f)
inline

Definition at line 610 of file newmat.h.

References GeneralMatrix::Add().

610 { GeneralMatrix::Add(f); }
void Add(GeneralMatrix *, Real)
Definition: newmat5.cpp:311

◆ operator-=() [1/2]

void SquareMatrix::operator-= ( const Matrix M)
inline

Definition at line 609 of file newmat.h.

609 { MinusEqual(M); }
void MinusEqual(const GeneralMatrix &gm)
Definition: newmat7.cpp:178

◆ operator-=() [2/2]

void SquareMatrix::operator-= ( Real  f)
inline

Definition at line 611 of file newmat.h.

References GeneralMatrix::Add().

611 { GeneralMatrix::Add(-f); }
void Add(GeneralMatrix *, Real)
Definition: newmat5.cpp:311

◆ operator=() [1/4]

void SquareMatrix::operator= ( const BaseMatrix X)

Definition at line 352 of file newmat6.cpp.

References REPORT, and MatrixType::Rt.

353 {
354  REPORT //CheckConversion(X);
355  // MatrixConversionCheck mcc;
356  Eq(X,MatrixType::Rt);
357  if (nrows != ncols)
358  { Tracer tr("SquareMatrix(=)"); Throw(NotSquareException(*this)); }
359 }
#define REPORT
Definition: newmat6.cpp:19
void Eq(const BaseMatrix &, MatrixType)
Definition: newmat4.cpp:637

◆ operator=() [2/4]

void SquareMatrix::operator= ( Real  f)
inline

Definition at line 598 of file newmat.h.

References GeneralMatrix::operator=().

void operator=(Real)
Definition: newmat6.cpp:342

◆ operator=() [3/4]

void SquareMatrix::operator= ( const SquareMatrix m)
inline

Definition at line 599 of file newmat.h.

599 { Eq(m); }
void Eq(const BaseMatrix &, MatrixType)
Definition: newmat4.cpp:637

◆ operator=() [4/4]

void SquareMatrix::operator= ( const Matrix m)

Definition at line 361 of file newmat6.cpp.

References GeneralMatrix::ncols, GeneralMatrix::nrows, and REPORT.

362 {
363  REPORT
364  if (m.nrows != m.ncols)
365  { Tracer tr("SquareMatrix(=Matrix)"); Throw(NotSquareException(*this)); }
366  Eq(m);
367 }
#define REPORT
Definition: newmat6.cpp:19
void Eq(const BaseMatrix &, MatrixType)
Definition: newmat4.cpp:637

◆ ReSize() [1/3]

void SquareMatrix::ReSize ( int  n)

Definition at line 236 of file newmat4.cpp.

References n, REPORT, and GeneralMatrix::ReSize().

Referenced by ReSize().

#define REPORT
Definition: newmat4.cpp:19
os2<< "> n<< " > nendobj n
void ReSize(int, int, int)
Definition: newmat4.cpp:216

◆ ReSize() [2/3]

void SquareMatrix::ReSize ( int  nr,
int  nc 
)
virtual

Reimplemented from Matrix.

Definition at line 239 of file newmat4.cpp.

References REPORT, and GeneralMatrix::ReSize().

240 {
241  REPORT
242  Tracer tr("SquareMatrix::ReSize");
243  if (nc != nr) Throw(NotSquareException(*this));
244  GeneralMatrix::ReSize(nr,nc,nr*nc);
245 }
#define REPORT
Definition: newmat4.cpp:19
void ReSize(int, int, int)
Definition: newmat4.cpp:216

◆ ReSize() [3/3]

void SquareMatrix::ReSize ( const GeneralMatrix A)
virtual

Reimplemented from Matrix.

Definition at line 286 of file newmat4.cpp.

References A, n, REPORT, and ReSize().

287 {
288  REPORT
289  int n = A.Nrows();
290  if (n != A.Ncols())
291  {
292  Tracer tr("SquareMatrix::ReSize(GM)");
293  Throw(NotSquareException(*this));
294  }
295  ReSize(n);
296 }
void ReSize(int)
Definition: newmat4.cpp:236
#define A(r, c)
#define REPORT
Definition: newmat4.cpp:19
os2<< "> n<< " > nendobj n

◆ Type()

MatrixType SquareMatrix::Type ( ) const
virtual

Reimplemented from Matrix.

Definition at line 414 of file newmat4.cpp.

References MatrixType::Sq.

414 { return MatrixType::Sq; }

The documentation for this class was generated from the following files: