comparison liboctave/CSparse.cc @ 7802:1a446f28ce68

implement optimized sparse-dense transposed multiplication
author Jaroslav Hajek <highegg@gmail.com>
date Sun, 18 May 2008 20:23:31 +0200
parents 36594d5bbe13
children 935be827eaf8
comparison
equal deleted inserted replaced
7801:776791438957 7802:1a446f28ce68
7483 { 7483 {
7484 FULL_SPARSE_MUL (ComplexMatrix, Complex, Complex (0.,0.)); 7484 FULL_SPARSE_MUL (ComplexMatrix, Complex, Complex (0.,0.));
7485 } 7485 }
7486 7486
7487 ComplexMatrix 7487 ComplexMatrix
7488 mul_trans (const ComplexMatrix& m, const SparseComplexMatrix& a)
7489 {
7490 FULL_SPARSE_MUL_TRANS (ComplexMatrix, Complex, Complex (0.,0.), );
7491 }
7492
7493 ComplexMatrix
7494 mul_herm (const ComplexMatrix& m, const SparseComplexMatrix& a)
7495 {
7496 FULL_SPARSE_MUL_TRANS (ComplexMatrix, Complex, Complex (0.,0.), conj);
7497 }
7498
7499 ComplexMatrix
7488 operator * (const SparseComplexMatrix& m, const Matrix& a) 7500 operator * (const SparseComplexMatrix& m, const Matrix& a)
7489 { 7501 {
7490 SPARSE_FULL_MUL (ComplexMatrix, double, Complex (0.,0.)); 7502 SPARSE_FULL_MUL (ComplexMatrix, double, Complex (0.,0.));
7491 } 7503 }
7492 7504
7498 7510
7499 ComplexMatrix 7511 ComplexMatrix
7500 operator * (const SparseComplexMatrix& m, const ComplexMatrix& a) 7512 operator * (const SparseComplexMatrix& m, const ComplexMatrix& a)
7501 { 7513 {
7502 SPARSE_FULL_MUL (ComplexMatrix, Complex, Complex (0.,0.)); 7514 SPARSE_FULL_MUL (ComplexMatrix, Complex, Complex (0.,0.));
7515 }
7516
7517 ComplexMatrix
7518 trans_mul (const SparseComplexMatrix& m, const ComplexMatrix& a)
7519 {
7520 SPARSE_FULL_TRANS_MUL (ComplexMatrix, Complex, Complex (0.,0.), );
7521 }
7522
7523 ComplexMatrix
7524 herm_mul (const SparseComplexMatrix& m, const ComplexMatrix& a)
7525 {
7526 SPARSE_FULL_TRANS_MUL (ComplexMatrix, Complex, Complex (0.,0.), conj);
7503 } 7527 }
7504 7528
7505 // FIXME -- it would be nice to share code among the min/max 7529 // FIXME -- it would be nice to share code among the min/max
7506 // functions below. 7530 // functions below.
7507 7531