|
JunkBox_Lib++ (for Windows) 1.10.1
|
#include <Matrix++.h>
Public Member Functions | |
| Matrix () | |
| Matrix (int nn,...) | |
| virtual | ~Matrix () |
| 関数にコピー渡しした場合に,関数内でディストラクトされても良い様に free() は使用しない. | |
| void | init () |
| void | init (int nn,...) |
| void | getm (int nn, int *size) |
| T & | element (int i,...) |
| void | clear (T v=T(0)) |
| void | dup (Matrix< T > a) |
| void | free () |
| free() は手動で呼び出す. | |
Public Attributes | |
| int | n |
| 次元数 | |
| int | r |
| 全要素数 sz[0]*sz[1]*...*sz[n-1] | |
| int | d |
| 汎用 | |
| int * | sz |
| 各次元の要素数 sz[0] 〜 sz[n-1] | |
| T * | mx |
| 要素 mx[0] 〜 mx[r-1] | |
| T | err |
| エラー時にこれを参照用として返す. | |
template <typename T=double>> class Matrix
Definition at line 28 of file Matrix++.h.
Definition at line 39 of file Matrix++.h.
References Matrix< T >::init().

template <typename T> Matrix<T>::Matrix(int nn, ...)
コンストラクタ
| nn | マトリックスの次元数. |
| ... | 各次元の要素数. |
Definition at line 71 of file Matrix++.h.
Definition at line 41 of file Matrix++.h.
Definition at line 48 of file Matrix++.h.
References Matrix< T >::mx, Matrix< T >::r, and Matrix< T >::sz.
Definition at line 49 of file Matrix++.h.
References jbxl::dup_Matrix(), and Matrix< T >::sz.

template <typename T> T& Matrix<T>::element(int i, ...)
Matrix の要素を返す.次元数に制限はない.インデックスは1から数える(0からではない).
Definition at line 204 of file Matrix++.h.
Referenced by AffineTrans< T >::computeComponents(), AffineTrans< T >::computeMatrix(), jbxl::ExtEulerXYZ2RotMatrix(), jbxl::ExtEulerXZY2RotMatrix(), jbxl::ExtEulerYXZ2RotMatrix(), jbxl::ExtEulerYZX2RotMatrix(), jbxl::ExtEulerZXY2RotMatrix(), jbxl::ExtEulerZYX2RotMatrix(), AffineTrans< T >::getInverseAffine(), AffineTrans< T >::getRotationMatrix(), Quaternion< T >::getRotMatrix(), jbxl::RotMatrix2ExtEulerXYZ(), jbxl::RotMatrix2ExtEulerXZY(), jbxl::RotMatrix2ExtEulerYXZ(), jbxl::RotMatrix2ExtEulerYZX(), jbxl::RotMatrix2ExtEulerZXY(), and jbxl::RotMatrix2ExtEulerZYX().

Definition at line 52 of file Matrix++.h.
References Matrix< T >::free(), Matrix< T >::init(), Matrix< T >::mx, and Matrix< T >::sz.
Referenced by AffineTrans< T >::computeComponents(), AffineTrans< T >::computeMatrix(), AffineTrans< T >::execMatrixTrans(), Matrix< T >::free(), AffineTrans< T >::getInverseAffine(), jbxl::operator*(), jbxl::Quaternion2ExtEulerXYZ(), jbxl::Quaternion2ExtEulerXZY(), jbxl::Quaternion2ExtEulerYXZ(), jbxl::Quaternion2ExtEulerYZX(), jbxl::Quaternion2ExtEulerZXY(), and jbxl::Quaternion2ExtEulerZYX().


template <typename T> void Matrix<T>::getm(int nn, int* size)
現在のバッファ部をクリアして,任意(n)次元の実数マトリックスのバッファ部をつくり出す.
要素自体は (T)0に初期化される.init() とは引数の形が違うだけ
| nn | マトリックスの次元数. |
| size | size[0]〜size[nn-1]: 各次元の要素数. |
Definition at line 157 of file Matrix++.h.
Referenced by jbxl::dup_Matrix(), jbxl::operator*(), jbxl::operator+(), and jbxl::operator-().

Definition at line 43 of file Matrix++.h.
References Matrix< T >::d, Matrix< T >::err, Matrix< T >::mx, Matrix< T >::n, Matrix< T >::r, and Matrix< T >::sz.
Referenced by Matrix< T >::free(), AffineTrans< T >::getRotationMatrix(), and Matrix< T >::Matrix().

template <typename T> void Matrix<T>::init(int nn, ...)
現在のバッファ部をクリアして,任意(n)次元の実数マトリックスのバッファ部をつくり出す.
要素自体は (T)0に初期化される.現在のバッファ部をクリアする以外は,コンストラクタと同じ.
| nn | マトリックスの次元数. |
| ... | 各次元の要素数. |
Definition at line 113 of file Matrix++.h.
Definition at line 33 of file Matrix++.h.
Referenced by jbxl::dup_Matrix(), and Matrix< T >::init().
Definition at line 36 of file Matrix++.h.
Referenced by jbxl::dup_Matrix(), and Matrix< T >::init().
Definition at line 35 of file Matrix++.h.
Referenced by Matrix< T >::clear(), jbxl::dup_Matrix(), AffineTrans< T >::execMatrixTrans(), Matrix< T >::free(), Matrix< T >::init(), jbxl::operator*(), jbxl::operator*(), jbxl::operator*(), jbxl::operator*(), jbxl::operator+(), jbxl::operator-(), jbxl::operator-(), jbxl::operator/(), jbxl::operator==(), and jbxl::print_Matrix().
Definition at line 31 of file Matrix++.h.
Referenced by jbxl::dup_Matrix(), Matrix< T >::init(), jbxl::isSameDimension(), jbxl::operator*(), jbxl::operator*(), jbxl::operator*(), jbxl::operator+(), jbxl::operator-(), jbxl::operator-(), jbxl::operator/(), and jbxl::print_Matrix().
Definition at line 32 of file Matrix++.h.
Referenced by Matrix< T >::clear(), jbxl::dup_Matrix(), Matrix< T >::init(), jbxl::isSameDimension(), jbxl::operator*(), jbxl::operator*(), jbxl::operator*(), jbxl::operator+(), jbxl::operator-(), jbxl::operator-(), jbxl::operator/(), jbxl::operator==(), and jbxl::print_Matrix().
| int* sz |
Definition at line 34 of file Matrix++.h.
Referenced by Matrix< T >::clear(), Matrix< T >::dup(), jbxl::dup_Matrix(), Matrix< T >::free(), Matrix< T >::init(), jbxl::isSameDimension(), jbxl::operator*(), jbxl::operator*(), jbxl::operator*(), jbxl::operator+(), jbxl::operator-(), jbxl::operator-(), jbxl::operator/(), and jbxl::print_Matrix().