[Lapackpp-devel] CVS
Status: Beta
Brought to you by:
cstim
From: Do bi <mrc...@ya...> - 2006-08-05 18:18:44
|
Please provide the updated lapackpp because it would be too much pain doing CVS. I am already familiar with how to download the library, running the proj file, and linking, so it is better for me to continue in the same way. Thanks. Christian Stimming <sti...@tu...> wrote: -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Hi Do Bi, Christian Stimming schrieb: > Please can anyone hint me how to correctly form a tridiagonal? > I wrote this and tried to print the value, but it was wrong. indeed you have found a bug in the library. Thanks for providing the testing code -- this way I could fix this in the library. Basically you need to write Mat.diag(0).inject(Diag); instead of Mat.diag(0)=Diag; but apart from this there have been various bugs in the code of the LaTridiagMatDouble class. These have been fixed in CVS now. Are you familiar with retrieving the source code from CVS, see http://sourceforge.net/cvs/?group_id=99696 ? If not, then please tell us so, and then I'll provide an updated lapackpp-2.4.12 version as soon as possible. As a hint for you: The header file with the LaTridiagMatDouble class, include/trmd.h, contained almost no documentation at all. This always means that the code has never been reviewed by me since its original lapack++-1.0 version, and it is very likely that it contains bugs and/or is incomplete. Not that I wouldn't introduce bugs myself, but when I document and review other code then it has at least been checked by more than one person. So: The class LaTridiagMatDouble contained various errors, and the missing documentation were a strong hint that this is possible. Apart from this I actually don't quite understand what you want to do with the LaTridiagMat. There aren't any useful functions available for these, except for LaTridiagMatFactorize in trfd.h ... Regards Christian Stimming > LaVectorDouble x(M), b(M), const Diag(M), DiagL(M-1), DiagU(M-1); > for (int i=0; i< M; i++) > Diag(i)=1+2*alfa*0; > for (int i=0; i< M-1; i++) > DiagL(i)=-alfa; > for (int i=0; i< M-1; i++) > DiagU(i)=-alfa; > > > for (int i=0; i< M-1; i++) > cout << DiagL(i) << endl; > LaTridiagMatDouble Mat(M); > Mat.diag(0)=Diag; > Mat.diag(-1)=DiagL; > Mat.diag(1)=DiagU; > //for (int i=0; i< M-1; i++) > //cout << Diag(i) << endl; > cout << Mat(0,0) << endl; > > > --------------------------------- > Yahoo! Music Unlimited - Access over 1 million songs.Try it free. > > ------------------------------------------------------- > -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.2.1 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iQCVAwUBRM9TaGXAi+BfhivFAQIZxgP/WDrfUSZvbi28cSxvlMuD9HdFnHnuM8H+ GweXLM6g4jCblLZZK4hUuEsvvhr9C9LROojqjnZhSpGtjxnbVRbdUruotj228FpE AK5Usws81NMAFpeWdTKBzLrM39Ript99i2tuiEADSLO8L/luq0zshb1DX2I6yxLi ae8OfNRKdt0= =bWY1 -----END PGP SIGNATURE----- --------------------------------- Talk is cheap. Use Yahoo! Messenger to make PC-to-Phone calls. Great rates starting at 1¢/min. |