Changeset 50ef8f6 in tol
- Timestamp:
- Oct 2, 2012, 5:53:47 PM (14 years ago)
- Branches:
- 1941-docker-image-to-test, devel, master
- Children:
- 8891b0c
- Parents:
- a623204
- Location:
- tol/bmath/blinalg
- Files:
-
- 2 edited
-
linalg.cpp (modified) (1 diff)
-
tol_blinalg.h (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
tol/bmath/blinalg/linalg.cpp
ra623204 r50ef8f6 328 328 329 329 //-------------------------------------------------------------------- 330 BMat SvdMinimumResidualsSolve(const BMat& A, const BMat& b) 331 332 /*! Solves Ax=b using SVD decomposition 333 */ 334 //-------------------------------------------------------------------- 335 { 336 BText method = BText("Golub_Reinsch_Mod"); 337 int r = A.Rows(); 338 int c = A.Columns(); 339 BMat U, V; 340 BDiagMatrix<BDat> D, Dp; 341 D.Alloc(c); 342 U.Alloc(r,c); 343 V.Alloc(c,c); 344 gsl_SingularValueDecomposition(A,U,D,V, method); 345 Dp = D.P(Sqrt(DEpsilon())); 346 return(V*Dp*((b.T()*U).T())); 347 } 348 349 //-------------------------------------------------------------------- 330 350 BMat Kernel(const BMat& A) 331 351 -
tol/bmath/blinalg/tol_blinalg.h
ra623204 r50ef8f6 69 69 const BMat& b); 70 70 71 BMat SvdMinimumResidualsSolve(const BMat& A, const BMat& b); 71 72 72 73 BDat LinearLeastSquareSolve
Note: See TracChangeset
for help on using the changeset viewer.
