Mercurial > hg > octave-lyh
comparison liboctave/fMatrix.h @ 9661:afcf852256d2
optimize / and '\ for triangular matrices
author | Jaroslav Hajek <highegg@gmail.com> |
---|---|
date | Wed, 23 Sep 2009 10:00:16 +0200 |
parents | b29504415a2e |
children | 1dba57e9d08d |
comparison
equal
deleted
inserted
replaced
9660:0256e187d13b | 9661:afcf852256d2 |
---|---|
161 | 161 |
162 private: | 162 private: |
163 // Upper triangular matrix solvers | 163 // Upper triangular matrix solvers |
164 FloatMatrix utsolve (MatrixType &typ, const FloatMatrix& b, octave_idx_type& info, | 164 FloatMatrix utsolve (MatrixType &typ, const FloatMatrix& b, octave_idx_type& info, |
165 float& rcon, solve_singularity_handler sing_handler, | 165 float& rcon, solve_singularity_handler sing_handler, |
166 bool calc_cond = false) const; | 166 bool calc_cond = false, blas_trans_type transt = blas_no_trans) const; |
167 | 167 |
168 // Lower triangular matrix solvers | 168 // Lower triangular matrix solvers |
169 FloatMatrix ltsolve (MatrixType &typ, const FloatMatrix& b, octave_idx_type& info, | 169 FloatMatrix ltsolve (MatrixType &typ, const FloatMatrix& b, octave_idx_type& info, |
170 float& rcon, solve_singularity_handler sing_handler, | 170 float& rcon, solve_singularity_handler sing_handler, |
171 bool calc_cond = false) const; | 171 bool calc_cond = false, blas_trans_type transt = blas_no_trans) const; |
172 | 172 |
173 // Full matrix solvers (lu/cholesky) | 173 // Full matrix solvers (lu/cholesky) |
174 FloatMatrix fsolve (MatrixType &typ, const FloatMatrix& b, octave_idx_type& info, | 174 FloatMatrix fsolve (MatrixType &typ, const FloatMatrix& b, octave_idx_type& info, |
175 float& rcon, solve_singularity_handler sing_handler, | 175 float& rcon, solve_singularity_handler sing_handler, |
176 bool calc_cond = false) const; | 176 bool calc_cond = false) const; |
181 FloatMatrix solve (MatrixType &typ, const FloatMatrix& b, octave_idx_type& info) const; | 181 FloatMatrix solve (MatrixType &typ, const FloatMatrix& b, octave_idx_type& info) const; |
182 FloatMatrix solve (MatrixType &typ, const FloatMatrix& b, octave_idx_type& info, | 182 FloatMatrix solve (MatrixType &typ, const FloatMatrix& b, octave_idx_type& info, |
183 float& rcon) const; | 183 float& rcon) const; |
184 FloatMatrix solve (MatrixType &typ, const FloatMatrix& b, octave_idx_type& info, | 184 FloatMatrix solve (MatrixType &typ, const FloatMatrix& b, octave_idx_type& info, |
185 float& rcon, solve_singularity_handler sing_handler, | 185 float& rcon, solve_singularity_handler sing_handler, |
186 bool singular_fallback = true) const; | 186 bool singular_fallback = true, blas_trans_type transt = blas_no_trans) const; |
187 | 187 |
188 FloatComplexMatrix solve (MatrixType &typ, const FloatComplexMatrix& b) const; | 188 FloatComplexMatrix solve (MatrixType &typ, const FloatComplexMatrix& b) const; |
189 FloatComplexMatrix solve (MatrixType &typ, const FloatComplexMatrix& b, | 189 FloatComplexMatrix solve (MatrixType &typ, const FloatComplexMatrix& b, |
190 octave_idx_type& info) const; | 190 octave_idx_type& info) const; |
191 FloatComplexMatrix solve (MatrixType &typ, const FloatComplexMatrix& b, | 191 FloatComplexMatrix solve (MatrixType &typ, const FloatComplexMatrix& b, |
192 octave_idx_type& info, float& rcon) const; | 192 octave_idx_type& info, float& rcon) const; |
193 FloatComplexMatrix solve (MatrixType &typ, const FloatComplexMatrix& b, | 193 FloatComplexMatrix solve (MatrixType &typ, const FloatComplexMatrix& b, |
194 octave_idx_type& info, float& rcon, | 194 octave_idx_type& info, float& rcon, |
195 solve_singularity_handler sing_handler, | 195 solve_singularity_handler sing_handler, |
196 bool singular_fallback = true) const; | 196 bool singular_fallback = true, |
197 blas_trans_type transt = blas_no_trans) const; | |
197 | 198 |
198 FloatColumnVector solve (MatrixType &typ, const FloatColumnVector& b) const; | 199 FloatColumnVector solve (MatrixType &typ, const FloatColumnVector& b) const; |
199 FloatColumnVector solve (MatrixType &typ, const FloatColumnVector& b, | 200 FloatColumnVector solve (MatrixType &typ, const FloatColumnVector& b, |
200 octave_idx_type& info) const; | 201 octave_idx_type& info) const; |
201 FloatColumnVector solve (MatrixType &typ, const FloatColumnVector& b, | 202 FloatColumnVector solve (MatrixType &typ, const FloatColumnVector& b, |
202 octave_idx_type& info, float& rcon) const; | 203 octave_idx_type& info, float& rcon) const; |
203 FloatColumnVector solve (MatrixType &typ, const FloatColumnVector& b, | 204 FloatColumnVector solve (MatrixType &typ, const FloatColumnVector& b, |
204 octave_idx_type& info, float& rcon, | 205 octave_idx_type& info, float& rcon, |
205 solve_singularity_handler sing_handler) const; | 206 solve_singularity_handler sing_handler, |
207 blas_trans_type transt = blas_no_trans) const; | |
206 | 208 |
207 FloatComplexColumnVector solve (MatrixType &typ, | 209 FloatComplexColumnVector solve (MatrixType &typ, |
208 const FloatComplexColumnVector& b) const; | 210 const FloatComplexColumnVector& b) const; |
209 FloatComplexColumnVector solve (MatrixType &typ, const FloatComplexColumnVector& b, | 211 FloatComplexColumnVector solve (MatrixType &typ, const FloatComplexColumnVector& b, |
210 octave_idx_type& info) const; | 212 octave_idx_type& info) const; |
211 FloatComplexColumnVector solve (MatrixType &typ, const FloatComplexColumnVector& b, | 213 FloatComplexColumnVector solve (MatrixType &typ, const FloatComplexColumnVector& b, |
212 octave_idx_type& info, float& rcon) const; | 214 octave_idx_type& info, float& rcon) const; |
213 FloatComplexColumnVector solve (MatrixType &typ, const FloatComplexColumnVector& b, | 215 FloatComplexColumnVector solve (MatrixType &typ, const FloatComplexColumnVector& b, |
214 octave_idx_type& info, float& rcon, | 216 octave_idx_type& info, float& rcon, |
215 solve_singularity_handler sing_handler) const; | 217 solve_singularity_handler sing_handler, blas_trans_type transt = blas_no_trans) const; |
216 | 218 |
217 // Generic interface to solver with probing of type | 219 // Generic interface to solver with probing of type |
218 FloatMatrix solve (const FloatMatrix& b) const; | 220 FloatMatrix solve (const FloatMatrix& b) const; |
219 FloatMatrix solve (const FloatMatrix& b, octave_idx_type& info) const; | 221 FloatMatrix solve (const FloatMatrix& b, octave_idx_type& info) const; |
220 FloatMatrix solve (const FloatMatrix& b, octave_idx_type& info, float& rcon) const; | 222 FloatMatrix solve (const FloatMatrix& b, octave_idx_type& info, float& rcon) const; |
221 FloatMatrix solve (const FloatMatrix& b, octave_idx_type& info, float& rcon, | 223 FloatMatrix solve (const FloatMatrix& b, octave_idx_type& info, float& rcon, |
222 solve_singularity_handler sing_handler) const; | 224 solve_singularity_handler sing_handler, |
225 blas_trans_type transt = blas_no_trans) const; | |
223 | 226 |
224 FloatComplexMatrix solve (const FloatComplexMatrix& b) const; | 227 FloatComplexMatrix solve (const FloatComplexMatrix& b) const; |
225 FloatComplexMatrix solve (const FloatComplexMatrix& b, octave_idx_type& info) const; | 228 FloatComplexMatrix solve (const FloatComplexMatrix& b, octave_idx_type& info) const; |
226 FloatComplexMatrix solve (const FloatComplexMatrix& b, octave_idx_type& info, float& rcon) const; | 229 FloatComplexMatrix solve (const FloatComplexMatrix& b, octave_idx_type& info, float& rcon) const; |
227 FloatComplexMatrix solve (const FloatComplexMatrix& b, octave_idx_type& info, float& rcon, | 230 FloatComplexMatrix solve (const FloatComplexMatrix& b, octave_idx_type& info, float& rcon, |
228 solve_singularity_handler sing_handler) const; | 231 solve_singularity_handler sing_handler, |
232 blas_trans_type transt = blas_no_trans) const; | |
229 | 233 |
230 FloatColumnVector solve (const FloatColumnVector& b) const; | 234 FloatColumnVector solve (const FloatColumnVector& b) const; |
231 FloatColumnVector solve (const FloatColumnVector& b, octave_idx_type& info) const; | 235 FloatColumnVector solve (const FloatColumnVector& b, octave_idx_type& info) const; |
232 FloatColumnVector solve (const FloatColumnVector& b, octave_idx_type& info, float& rcon) const; | 236 FloatColumnVector solve (const FloatColumnVector& b, octave_idx_type& info, float& rcon) const; |
233 FloatColumnVector solve (const FloatColumnVector& b, octave_idx_type& info, float& rcon, | 237 FloatColumnVector solve (const FloatColumnVector& b, octave_idx_type& info, float& rcon, |
234 solve_singularity_handler sing_handler) const; | 238 solve_singularity_handler sing_handler, |
239 blas_trans_type transt = blas_no_trans) const; | |
235 | 240 |
236 FloatComplexColumnVector solve (const FloatComplexColumnVector& b) const; | 241 FloatComplexColumnVector solve (const FloatComplexColumnVector& b) const; |
237 FloatComplexColumnVector solve (const FloatComplexColumnVector& b, octave_idx_type& info) const; | 242 FloatComplexColumnVector solve (const FloatComplexColumnVector& b, octave_idx_type& info) const; |
238 FloatComplexColumnVector solve (const FloatComplexColumnVector& b, octave_idx_type& info, | 243 FloatComplexColumnVector solve (const FloatComplexColumnVector& b, octave_idx_type& info, |
239 float& rcon) const; | 244 float& rcon) const; |
240 FloatComplexColumnVector solve (const FloatComplexColumnVector& b, octave_idx_type& info, | 245 FloatComplexColumnVector solve (const FloatComplexColumnVector& b, octave_idx_type& info, |
241 float& rcon, | 246 float& rcon, solve_singularity_handler sing_handler, |
242 solve_singularity_handler sing_handler) const; | 247 blas_trans_type transt = blas_no_trans) const; |
243 | 248 |
244 // Singular solvers | 249 // Singular solvers |
245 FloatMatrix lssolve (const FloatMatrix& b) const; | 250 FloatMatrix lssolve (const FloatMatrix& b) const; |
246 FloatMatrix lssolve (const FloatMatrix& b, octave_idx_type& info) const; | 251 FloatMatrix lssolve (const FloatMatrix& b, octave_idx_type& info) const; |
247 FloatMatrix lssolve (const FloatMatrix& b, octave_idx_type& info, | 252 FloatMatrix lssolve (const FloatMatrix& b, octave_idx_type& info, |