Math::Matrix struct reference
[Core module]

Declaration  

#include <Goptical/Math/Matrix>

namespace Goptical {
namespace Math {
template <int N> struct Matrix;
};
};

This struct is a member of the Math namespace.

Description  

NxN square matrix class.

Members  

See also the full member list section for this struct.

Functions  

Members detail  

void adjugate(Matrix &result) const  

replace matrix by the adjugate matrix

Matrix adjugate() const  

Get the adjugate matrix

double determinant() const  

compute matrix determinant

void inverse(Matrix &result) const  

replace matrix by the inverse matrix

Matrix inverse() const  

Get the inverse matrix

Matrix operator*(double scale) const  

Scale matrix

Matrix operator*(const Matrix &m) const  

Multiply matrix

Vector<N> operator*(const Vector<N> &v) const  

Multiply matrix with vector. See Vector class for vector/matrix multiplication.

Matrix operator+(const Matrix &m) const  

Add matrix

Matrix operator-(const Matrix &m) const  

Subtract matrix

Matrix operator/(double scale) const  

Scale matrix

Matrix & set(double value = 0)  

Set whole matrix to specified value.

Matrix & set_col(int col, double value)  

Set whole matrix column to specified value.

Matrix & set_col(int col, const Vector<N> &v)  

Set matrix column to specified vector.

Matrix & set_diag(double value = 1)  

Set matrix diagonal to specified value.

Matrix & set_diag(const Vector<N> &v)  

Set matrix diagonal to specified value.

Matrix & set_id()  

Setup an identity matrix.

Matrix & set_row(int row, double value)  

Set whole matrix row to specified value.

Matrix & set_row(int row, const Vector<N> &v)  

Set matrix row to specified vector.

void transpose(Matrix &result) const  

replace matrix by the transposed matrix

Matrix transpose() const  

Get the transposed matrix

double value(int x, int y) const  

Get value at x row and y column

double & value(int x, int y)  

Get modifiable reference to value at x row and y column

Valid XHTML 1.0 StrictGenerated by diaxen on Sun Jan 8 00:47:24 2012 using MkDoc