Main Page   Class Hierarchy   Compound List   File List   Compound Members  

Matrix Class Reference

Mathematical matrix. More...

#include <mmatrix.h>

Inheritance diagram for Matrix::

PackTable Object List of all members.

Public Types

enum  iters { }

Public Methods

 Matrix ()
 Matrix (int rows, int cols)
 Matrix (const Matrix &o)
 ~Matrix ()
void make (int rs, int cs)
void load (const String &filename)
void load (FILE *in)
void save (FILE *out) const
const Matrix& transpose ()
const Matrix& multiplyToSum (double s)
double sum () const
void splitVertical (Matrix &a, Matrix &b, int column) const
void splitHorizontal (Matrix &a, Matrix &b, int column) const
Matrix sub (int row0, int row1, int col0, int col1) const
void insertColumn (int cols)
void joinVertical (const Matrix &a, const Matrix &b)
void joinHorizontal (const Matrix &a, const Matrix &b)
const Matrix& operator= (double x)
const Matrix& operator+= (const Matrix &other)
const Matrix& operator+ (const Matrix &other) const
const Matrix& operator+= (double k)
const Matrix& operator+ (double k) const
const Matrix& operator *= (const Matrix &other)
const Matrix& operator * (const Matrix &other) const
const Matrix& operator *= (double k)
const Matrix& operator * (double k) const
const Matrix& operator/ (double k) const
const Matrix& operator/= (double k)
void operator>> (OStream &out) const
const Matrix& operator= (const Matrix &other)

Detailed Description

Mathematical matrix.

Definition at line 23 of file mmatrix.h.


Member Function Documentation

void load ( FILE * in )
 

Load matrix from stream.

Columns are whitespace-separated, rows newline-separated.

void load ( const String & filename )
 

Load matrix from file.

Columns are whitespace-separated, rows newline-separated.

void make ( int rs,
int cs ) [inline, virtual]
 

Creates or recreates the Table with the given dimensions.

If the Table has any old contents, they are destroyed.

Parameters:
nrows   Number of rows in the Table.
ncols   Number of columns in the Table.

Reimplemented from PackTable.

Definition at line 30 of file mmatrix.h.

void operator>> ( OStream & out ) const [virtual]
 

Ordinary free-formatted printout.

Reimplemented from Object.


The documentation for this class was generated from the following file:
Generated at Tue Dec 4 19:53:31 2001 for MagiC++ by doxygen1.2.6 written by Dimitri van Heesch, © 1997-2001