00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00024
00025 #ifndef QMATRIXALGEBRA_H
00026 #define QMATRIXALGEBRA_H
00027
00028 #include <QVector>
00029 #include <QVMatrix>
00030
00043 void singularValueDecomposition(const QVMatrix &M, QVMatrix &U, QVMatrix &V, QVMatrix &S);
00044
00061 void SingularValueDecomposition(const QVMatrix &A, QVMatrix &U, QVMatrix &S, QVMatrix &V);
00062
00080 void LUDecomposition(const QVMatrix &A, QVMatrix &L, QVMatrix &U, QVMatrix &P);
00081
00095 void CholeskyDecomposition(const QVMatrix &A, QVMatrix &L);
00096
00110 void QRDecomposition(const QVMatrix &A, QVMatrix &Q, QVMatrix &R);
00111
00125 QVMatrix pseudoInverse(const QVMatrix &A);
00126
00149 void eigenDecomposition(const QVMatrix &A, QVVector &l, QVMatrix &Q);
00150
00157 double determinant(const QVMatrix &A);
00158
00176 void solveLinear(const QVMatrix &A, QVVector &x, const QVVector &b);
00177
00201 void solveLinear(const QVMatrix &A, QVMatrix &X, const QVMatrix &B);
00202
00219 void solveOverDetermined(const QVMatrix &A, QVMatrix &X, const QVMatrix &B);
00220
00234 void solveHomogeneousLinear(const QVMatrix &A, QVector<double> &x);
00235
00236 #ifndef DOXYGEN_IGNORE_THIS
00238 void solveHomogeneousLinear2(const QVMatrix &A, QVector<double> &x);
00239
00241 double homogLineFromMoments(double x,double y,double xx,double xy,double yy,double &a,double &b,double &c);
00242
00244 QVVector regressionLine(const QVMatrix &points);
00245 #endif
00246
00247 #endif