Log of /trunk/math/matrix/src/TVectorT.cxx
Parent Directory
Revision
30125 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Mon Sep 14 05:03:58 2009 UTC (5 years, 4 months ago) by
brun
File length: 82692 byte(s)
Diff to
previous 22885
From Eddy Offermann:
- added a Streamer function to TMatrixTSparse to remove a memory leak.
Updated LinkDef.h accordingly.
- added vector functionality as proposed by Peter D Barnes from LNL
(http://root.cern.ch/phpBB2/viewtopic.php?t=8351).
Mult function: double s = v1 * M * v2; // e.g., physics matrix element
OuterProduct : TMatrixD M = v1' * v2 // outer product of v1 and v2
Revision
22885 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Fri Mar 28 13:57:25 2008 UTC (6 years, 9 months ago) by
rdm
File length: 77209 byte(s)
Diff to
previous 21231
move the following directories under the new "math" meta directory:
mathcore
mathmore
fftw
foam
fumili
genvector
matrix
minuit
minuit2
mlp
physics
smatrix
splot
unuran
quadp
Revision
17734 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Tue Feb 6 15:47:59 2007 UTC (7 years, 11 months ago) by
brun
Original Path:
trunk/matrix/src/TVectorT.cxx
File length: 75459 byte(s)
Diff to
previous 17648
In the Streamer functions replace the lines like
TPad::Class()->ReadBuffer(b, this, v, R__s, R__c);
TPad::Class()->WriteBuffer(b,this);
by
b.ReadClassBuffer(TPad::Class(), this, v, R__s, R__c);
b.WriteClassBuffer(TPad::Class(),this);
Revision
17561 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Mon Jan 29 15:10:49 2007 UTC (7 years, 11 months ago) by
brun
Original Path:
trunk/matrix/src/TVectorT.cxx
File length: 75432 byte(s)
Diff to
previous 17412
-Add include "TROOT.h" in all implementation files that were assuming
that TROOT was included via TClass.h
-In TClass.h:
--Remove the include of TROOT.h
--add the following static member
static IdMap_t *fgIdMap; //Map from typeid to TClass pointer
--add the following functions:
static void AddClass(TClass *cl);
static void RemoveClass(TClass *cl);
--Replace the inline definitions of GetClass functions by
template <typename T> TClass* GetClass( T** /* dummy */) { return GetClass((T*)0); }
template <typename T> TClass* GetClass(const T** /* dummy */) { return GetClass((T*)0); }
-In TClass.cxx:
--Instead of forwarding the calls to gROOT->GetClass, move the code
originally in TROOT in the TClass::GetClass functions
--Move class TMapTypeToTClass from TROOT to TClass.
Revision
17412 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Sat Jan 20 19:29:35 2007 UTC (8 years ago) by
brun
Original Path:
trunk/matrix/src/TVectorT.cxx
File length: 75413 byte(s)
Diff to
previous 16943
-Remove Varargs.h from TString.h and TObject.h and add this include
in the few files that need it.
-Move the following enums from TBuffer.h to TBufferFile.h
enum { kMapSize = 503 };
enum { kStreamedMemberWise = BIT(14) }; //added to version number to know if a collection has been stored member-wise
enum { kNotDecompressed = BIT(15) }; //indicates a weird buffer, used by TBasket
enum { kCannotHandleMemberWiseStreaming = BIT(17), //if set TClonesArray should not use memeber wise streaming
kTextBasedStreaming = BIT(18) }; // indicates if buffer used for XML/SQL object streaming
Revision
16458 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Fri Oct 6 06:52:34 2006 UTC (8 years, 3 months ago) by
brun
Original Path:
trunk/matrix/src/TVectorT.cxx
File length: 75828 byte(s)
Diff to
previous 16161
From Eddy Offermann:
Previously, the matrix package contained a large amount of ASSERT
statements which are a nuisance for programs analyzing a series of
independent events like in high-energy physics .
Assert's were issued when for instance a division by zero was requested
or a matrix was invalid . Most algorithms made matrices/vectors invalid
after an error occured in an operation , like inversion of a singular matrix .
Unfortunately, not all assert's were accompanied by error messages .
This situation has been completely overhauled :
- All error conditions in the algorithms are now accompanied by error
messages .
- In all algorithms it is still asserted that vectors/matrices are
valid BUT only in very few cases is a matrix/vector made invalid :
for instance if memory is allocated with incorrect parameters .
- In case of division by zero, the division is skipped . In case of a
singular matrix, the inversion routine returns the original matrix .
In the past the result of an inversion could be checked through the
value of the returned determinant or checking whether the inverted matrix
was valid .
Since from now on, we never make the matrix invalid in this operation, the
latter check will not indicate a singular matrix anymore .
The decompostion classes TDecomp... have a backward-compatible
change in the interface which makes detection of singularity easier :
old interface :
void Invert (TMatrixD &inv);
TMatrixD Invert ();
new interface :
Bool_t Invert (TMatrixD &inv);
TMatrixD Invert (Bool_t &status);
TMatrixD Invert () { Bool_t status; return Invert(status);
}
The returned status is kFALSE in case of singularity .
The old situation is easily reproduced by setting the ROOT variable
gErrorAbortLevel to kError . This cause an exception when there is an error
message (Error...) ., In the past the matrix would be made invalid which
would cause the next operation to throw an exception .
Revision
16161 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Wed Aug 30 12:54:13 2006 UTC (8 years, 4 months ago) by
brun
Original Path:
trunk/matrix/src/TVectorT.cxx
File length: 76258 byte(s)
Diff to
previous 15814
From Eddy:
the promised update/patch for
TMatrixD A; ......
B.Use(A);
C.Use(A);
C += B;
Currently, It is checked in these kinds of operation whether the
objects
are the same . Obviously, that is not enough because objects could be
using the same data location . So I have to check if the data location
is identical .
Revision
14745 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Wed Apr 19 08:22:26 2006 UTC (8 years, 9 months ago) by
rdm
Original Path:
trunk/matrix/src/TVectorT.cxx
File length: 73177 byte(s)
Diff to
previous 14537
Change the TError.h macros:
Assert -> R__ASSERT
Check -> R__CHECK
Change the TCollection.h macro:
ForEach -> R__FOR_EACH
This to avoid potential problems due too trivial macro names.
The old macros will be removed in the next release. Currently
they will print out warning messages with the advice to move
to the new macro names.
Revision
14537 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Tue Apr 4 05:51:06 2006 UTC (8 years, 9 months ago) by
brun
Original Path:
trunk/matrix/src/TVectorT.cxx
File length: 73206 byte(s)
Diff to
previous 14524
From Eddy:
- 2 weeks ago AMultB.. functions were made public . However, unlike any
other
public function except for the *= calls, it could allocate an object
. In addition
already Mult function existed (which called AMultB with constr=0) .
This situation is rectified in the following way :
The public Mult, MultT and TMult are introduced .
AMultB , AtMultB and AMultBt are now functions that do not belong
to the
TMatrixT class anymore, they accept now pointers as arguments .
None of these functions will create a new object . In internal
calls to AMultB family ,
first a call to Allocate is made (if necessary) .
AMultB is used in one of the TMatrixTSym::Similarity calls,
removing the creation of a
TMatrixT object .
- smatrix/test function reflect the changes above
Revision
14436 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Tue Mar 28 10:00:17 2006 UTC (8 years, 9 months ago) by
brun
Original Path:
trunk/matrix/src/TVectorT.cxx
File length: 71803 byte(s)
Diff to
previous 14387
Add two new functions
void Add(const TVectorT<Element> &v);
void Add(const TVectorT<Element> &v1, const TVectorT<Element> &v2);
The first function adds vector v to this.
The second function adds the 2 vectors v1 and v2 and store the result into this.
Revision
14336 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Mon Mar 20 21:43:44 2006 UTC (8 years, 10 months ago) by
pcanal
Original Path:
trunk/matrix/src/TVectorT.cxx
File length: 69734 byte(s)
Diff to
previous 13939
Reduce direct dependencies on TClass.h, TROOT.h and TStreamerInfo.h.
Warning: This means that some file that relied on the indirect
inclusion of these header file might now fail to compile with
an error message mention that gROOT is no known or that TClass,
TROOT or TStreamerInfo is incompletely defined. Simply add the
proper include directive.
Revision
13939 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Thu Jan 26 16:31:01 2006 UTC (8 years, 11 months ago) by
brun
Original Path:
trunk/matrix/src/TVectorT.cxx
File length: 69714 byte(s)
Diff to
previous 13770
From Eddy:
a patch that will hopefully resolve the Solaris issue .
From the error messages I deduce that the compiler does not like to
instantiate
a default templated argument in the function header . Therefore, I
replaced the default
value by the value 0.0 (which is an unusual value , the user would use
here "==")
and check in the routine and replace it with the appropriate epsilon.
This form allows you to request diffs between any two revisions of this file.
For each of the two "sides" of the diff,
enter a numeric revision.