Hi,
I had some emails to Mario only (unfortunately) . Here are the responses:
Eddy->Mario:
Have a look at matrix/inc/TMatrixDfwd.h and you will see that
TMatrixD
is just a typedef of the templated clas TMatrixT:
template<class Element> class TMatrixT; typedef TMatrixT<Double_t> TMatrixD;
So for complex matrices one could try
typedef TMatrixT<TComplex> TMatrixC
Mario->Eddy:
root [0] typedef TMatrixT<TComplex> TMatrixC Limitation: Can't instantiate precompiled template TMatrixT<TComplex>
(tmpfile):1:
any more ideas?
Eddy->Mario:
You have an issue here with CINT .
Have a look at matrix/inc/LinkDef.h and see what has to be done to
have CINT understand this new type . For instance for TMatrixD you
will find lines like :
#pragma link C++ class TMatrixT <Double_t>-;#pragma link C++ typedef TMatrixD;
> Hi Mario,
>
> None of the matrix classes in ROOT can be used with complex numbers.
> This could, in theory, be implemented withing TMatrix (already
> templated).
> However, the support for operations (of course what you want) would
> require a bit more work.
> May be, Eddy wants to add something to my mail ?
>
> Rene Brun
>
>
> Mario Kadastik wrote:
> > Hello,
> >
> > I have tried searching for a way to have matrices with complex
> numbers
> > in them and still have the functionality of matrices and have
> turned
> > up with a number of questions on the web however basically no
> answers.
> > Is there a way to use complex numbers in ROOT in matrices (there's
> the
> > complex class which enables one to have complex numbers and do
> > operations on them, but there seems not to be a way to have a
> matrix
> > with complex numbers in it). I have used until now TMatrixD for
> > matrices with doubles in them, but how do I extend that to include
> > complex numbers?
> >
> > Mario
>
>
Received on Tue Feb 27 2007 - 17:57:47 CET
This archive was generated by hypermail 2.2.0 : Tue Feb 27 2007 - 23:50:01 CET