*** empty log message ***

This commit is contained in:
jiri 2006-08-15 20:29:01 +00:00
parent 2c99357806
commit 47a1a24807
1 changed files with 8 additions and 11 deletions

View File

@ -9,8 +9,15 @@
//MISC
export template <class T>
const NRSMat<T> twoside_transform(const NRSMat<T> &S, const NRMat<T> &C) //calculate C^dagger S C
const NRSMat<T> twoside_transform(const NRSMat<T> &S, const NRMat<T> &C, bool transp=0) //calculate C^dagger S C
{
if(transp)
{
NRMat<T> tmp = C * S;
NRMat<T> result(C.rows(),C.nrows());
result.gemm((T)0,tmp,'n',C,'t',(T)1);
return NRSMat<T>(result);
}
NRMat<T> tmp = S * C;
NRMat<T> result(C.ncols(),C.ncols());
result.gemm((T)0,C,'t',tmp,'n',(T)1);
@ -18,16 +25,6 @@ return NRSMat<T>(result);
}
export template <class T>
const NRSMat<T> twoside_transform_t(const NRSMat<T> &S, const NRMat<T> &C) //calculate C S C^dagger
{
NRMat<T> tmp = C * S;
NRMat<T> result(C.rows(),C.nrows());
result.gemm((T)0,tmp,'n',C,'t',(T)1);
return NRSMat<T>(result);
}
export template <class T>