35 #include <Base/Image/Image.hh>
36 #include <Base/Math/Matrix.hh>
37 #include <Base/Math/Vector.hh>
38 #include <MathAlgo/SVD.hh>
55 int main(
int argc,
char *argv[]) {
89 const int n =
sizeof(
unsigned char);
102 for (
int i = 0; i < Z.
num_rows(); i++) {
103 for (
int j = 0; j < Z.
num_cols(); j++) {
104 wij = w[Z[i][j] + 1];
105 A[k][Z[i][j] + 1] = wij;
117 for (
int i = 0; i < n - 2; i++) {
118 A[k][i] = l * w[i+1];
119 A[k][i+1] = -2 * l * w[i+1];
120 A[k][i+2] = l * w[i+1];
133 for (
int i = 0; i < n; i++) {
137 for (
int i = n; i < x.
size(); i++) {
computes and holds the singular value decomposition of a rectangular (not necessarily quadratic) Matr...
Subscript num_cols() const
Vector< double > Solve(const Vector< double > &y) const
matrix class with arbitrary size, indexing is row major.
Subscript num_rows() const