Changeset 772 in Sophya for trunk/SophyaLib/TArray/tvector.h
- Timestamp:
- Mar 10, 2000, 4:13:22 PM (26 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/SophyaLib/TArray/tvector.h
r762 r772 55 55 {return TVector<T>(a * ((TMatrix<T> const&)(b)));} 56 56 57 // Resolution du systeme A*C = B58 inline r_8 LinSolveInPlace(TMatrix<r_8>& a, TVector<r_8>& b)59 {60 if(a.NCols() != b.NRows() || a.NCols() != a.NRows())61 throw(SzMismatchError("LinSolveInPlace(TMatrix<r_8>,TVector<r_8>) size mismatch"));62 return TMatrix<r_8>::GausPiv(a,b);63 }64 65 // Resolution du systeme A*C = B, avec C retourne dans B66 inline r_8 LinSolve(const TMatrix<r_8>& a, const TVector<r_8>& b, TVector<r_8>& c)67 {68 if(a.NCols() != b.NRows() || a.NCols() != a.NRows())69 throw(SzMismatchError("LinSolve(TMatrix<r_8>,TVector<r_8>) size mismatch"));70 c = b;71 TMatrix<r_8> a1(a);72 return TMatrix<r_8>::GausPiv(a1,c);73 }74 57 75 58 // Typedef pour simplifier et compatibilite Peida
Note:
See TracChangeset
for help on using the changeset viewer.