The cmat use double as default. However, I want to use float, so I want to knwo is there anyway to restrict the type to float. It seems the cvec also cannot support float.
Is there anyway to solve the problem?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Have you tried to use Mat<complex<float> > and Vec<complex<float >? You can typedef them if you want to something shorter, e.g.:
typedef Mat<complex<float> > cfmat;
typedef Vec<complex<float> > cfvec;
BR,
/ediap
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
> Why the itpp didn't have built-in support to float version routines?
Because, IT++ developers have not envisioned the need for supporting the float type. Now it is very difficult to change this, because all routines that use complex-based types would have to be implemented as templated routines. The same situation is for double -> float conversion.
BTW, why complex<double> is not acceptable for you and you need complex<float>?
BR,
/ediap
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
The cmat use double as default. However, I want to use float, so I want to knwo is there anyway to restrict the type to float. It seems the cvec also cannot support float.
Is there anyway to solve the problem?
Have you tried to use Mat<complex<float> > and Vec<complex<float >? You can typedef them if you want to something shorter, e.g.:
typedef Mat<complex<float> > cfmat;
typedef Vec<complex<float> > cfvec;
BR,
/ediap
I know this, but all routines in itpp seems only support the double version of cmat and cvec.
By useing typedef means I have to make those functions support the float version also.
Why the itpp didn't have built-in support to float version routines?
> Why the itpp didn't have built-in support to float version routines?
Because, IT++ developers have not envisioned the need for supporting the float type. Now it is very difficult to change this, because all routines that use complex-based types would have to be implemented as templated routines. The same situation is for double -> float conversion.
BTW, why complex<double> is not acceptable for you and you need complex<float>?
BR,
/ediap