Mentions légales du service

Skip to content
Snippets Groups Projects
Commit faaf8b20 authored by hhakim's avatar hhakim
Browse files

Add missing prototypes and fix constness in multiply(Vect) of MatButterfly.

parent 756540a9
No related branches found
No related tags found
No related merge requests found
......@@ -60,6 +60,7 @@ namespace Faust
MatGeneric<FPP,Cpu>* Clone(const bool isOptimize=false) const;
void multiply(Vect<FPP,Cpu> & vec, char opThis='N') const;
Vect<FPP,Cpu> multiply(const Vect<FPP,Cpu> &v) const; // from LinearOperator
void multiply(MatDense<FPP,Cpu> & M, char opThis) const;
void multiply(MatSparse<FPP, Cpu>& M, char opThis) const;
void multiplyRight(MatSparse<FPP, Cpu> const& M) ;
......@@ -83,6 +84,8 @@ namespace Faust
void setZeros();
bool containsNaN()const;
const FPP& operator()(faust_unsigned_int i, faust_unsigned_int j)const ;
void faust_gemm(const MatDense<FPP,Cpu> & B, MatDense<FPP,Cpu> & C,const FPP & alpha, const FPP & beta, char typeA, char typeB)const; //from LinearOperator
};
}
......
......@@ -98,13 +98,22 @@ namespace Faust
}
template<typename FPP>
void MatButterfly<FPP, Cpu>::multiply(Vect<FPP,Cpu> & x, char opThis) const
Vect<FPP, Cpu> MatButterfly<FPP, Cpu>::multiply(const Vect<FPP,Cpu> & x) const
{
Vect<FPP, Cpu> z(x.size());
multiply(x.getData(), z.getData(), x.size(), opThis != 'N'); //TODO: conjugate
const_cast<MatButterfly<FPP, Cpu>*>(this)->multiply(x.getData(), z.getData(), x.size(), false); //TODO: conjugate
return z;
}
template<typename FPP>
void MatButterfly<FPP, Cpu>::multiply(Vect<FPP,Cpu> & x, char opThis) const
{
Vect<FPP, Cpu> z(x.size());
const_cast<MatButterfly<FPP, Cpu>*>(this)->multiply(x.getData(), z.getData(), x.size(), opThis != 'N'); //TODO: conjugate
x = z;
}
template<typename FPP>
void MatButterfly<FPP, Cpu>::multiply(MatDense<FPP,Cpu> & M, char opThis) const
{
......@@ -190,6 +199,14 @@ namespace Faust
#endif
}
template<typename FPP>
void MatButterfly<FPP, Cpu>::faust_gemm(const MatDense<FPP,Cpu> & B, MatDense<FPP,Cpu> & C,const FPP & alpha, const FPP & beta, char typeA, char typeB)const
{
//TODO
}
template<typename FPP>
void MatButterfly<FPP, Cpu>::transpose()
{
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment