Line: 1 to 1 | ||||||||
---|---|---|---|---|---|---|---|---|

## LHCb Physics Event Model Comments on the MathCore Vector and the Root Linear Algebra Classes | ||||||||

Line: 20 to 20 | ||||||||

- We found an inconsistency in the behaviour of the typedefs for Vector3Ds and LorentzVectors. If Ione includes MathCore/Vector3D.h in the code, this includes MathCore/Vector3Dfwd.h, so one gets the typedefs XYZVector, XYZVectorF, etc. However, if one includes MathCore/LorentzVector.h, one does not get access to the typedefs as this file does not include MathCore/LorentzVectorfwd.h.
- A XYZTPoint is missing. That would be nice to have for MC truth.
- The Vec() method in XYZTVector is not const
| ||||||||

Changed: | ||||||||

< < | - There is an Eta() method in the LorentzVector, but no Gamma() and Beta().
| |||||||

> > | - There is an Eta() method in the LorentzVector, but no Gamma() and Beta().
| |||||||

## Root Linear Algebra Classes | ||||||||

Line: 30 to 30 | ||||||||

- We would like to be able to get a sub-matrix by reference. This is presently implemented, but the interface of the method is quite strange.
- The linear algebra classes seem not to be compatible with the mathcore classes. There is no way to multiply a matrix and a vector. (?)
| ||||||||

Added: | ||||||||

> > | ## What do we expect from a Linear Algebra package?First brain dump by PK at the LHCb Software week (slides) summarized by Juan:- Package must deal with matrixes of dimension up to 7x7
- Vanya: I would reformulate such as "package must deal efficiently with matrices of dimension upto 7x7". Also one need to indicate what operations we need. In addiiton to "obvious" and "natural" operations we definitely needs :
- efficient matrix inversion (with the proper and convinient way to indicate the inversion errors)
- efficient evaluation of eigenvalues and eigenvectors. I do not know if we needs other operations, like numerouse decomposition (e.g. LU,...etc)
- Vanya: I would reformulate such as "package must deal efficiently with matrices of dimension upto 7x7". Also one need to indicate what operations we need. In addiiton to "obvious" and "natural" operations we definitely needs :
- Package must allow for efficient retrieval of arbitrary submatrices with clear, easy to use semantics.
- Vanya's comments:
- For symmetrix matrices one needs to get access BY REFERENCE to all diagonal sub-blocks as 'diagonal' submatrices and for off-diagonal blocks BY REFERENCE as 'general' matrices. In general we do not require access to ARBITRARY subblock.
- For 'general matrix one also does not need access to ARBITRARY sub-blok. Only the diagonal and off-diagonal block are really needed for majority of applications.
- The non-diagonal blocks, which containes at least 2 diagonal elements usually are out of interest for all cases.
- Vanya's comments:
- Must have easy coupling to MathCore vector and point classes (obviously).
"Obvious requirements" by Matt for tracking: - Matrices and Symmetric matrices
- Basic matrix algebra functionality: *, + , += ,-, transpose
- Easy construction of identity and zero matrices
- CLHEP had an assign function, so you could do
tC.assign((HepDiagMatrix(tC.num_row(), 1) - (m_K * m_H.T()))*tC); - Matrix inversion (maybe copy the dsinv from cernlib as done by root and CLHEP ?). Failure of the inversion should be clearly indicated.
- Access to individual elements
- CLHEP provides a similarity function m1*s*m1.T() for symmetric matrices. We use this in the fit alot. I was once told that the reason that this is there is because this function is optimized for speed
- Access the size (number of rows and columns)
-- PatrickKoppenburg - 30 Sep 2005 | |||||||

## Links |

View topic | History: r7 < r6 < r5 < r4 | More topic actions...

Copyright &© 2008-2019 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.

Ideas, requests, problems regarding TWiki? Send feedback

Ideas, requests, problems regarding TWiki? Send feedback