Go to the documentation of this file.
15 #ifndef _DIAGMatrix_H_
16 #define _DIAGMatrix_H_
24 #include "CLHEP/Matrix/defs.h"
25 #include "CLHEP/Matrix/GenMatrix.h"
39 class HepDiagMatrix:
public HepGenMatrix {
64 const double &
operator()(
int row,
int col)
const;
68 double &
fast(
int row,
int col);
69 const double &
fast(
int row,
int col)
const;
142 double trace()
const;
190 std::vector<double > m;
192 std::vector<double,Alloc<double,25> >
m;
195 #if defined(__sun) || !defined(__GNUG__)
201 static const double zero;
205 std::ostream&
operator<<(std::ostream &s,
const HepDiagMatrix &q);
208 HepMatrix
operator*(
const HepMatrix &hm1,
const HepDiagMatrix &hm2);
209 HepMatrix
operator*(
const HepDiagMatrix &hm1,
const HepMatrix &hm2);
210 HepDiagMatrix
operator*(
double t,
const HepDiagMatrix &d1);
211 HepDiagMatrix
operator*(
const HepDiagMatrix &d1,
double t);
215 HepDiagMatrix
operator/(
const HepDiagMatrix &hm1,
double t);
218 HepMatrix
operator+(
const HepMatrix &hm1,
const HepDiagMatrix &d2);
219 HepMatrix
operator+(
const HepDiagMatrix &d1,
const HepMatrix &hm2);
220 HepDiagMatrix
operator+(
const HepDiagMatrix &hm1,
const HepDiagMatrix &d2);
221 HepSymMatrix
operator+(
const HepSymMatrix &s1,
const HepDiagMatrix &d2);
222 HepSymMatrix
operator+(
const HepDiagMatrix &d1,
const HepSymMatrix &s2);
225 HepMatrix
operator-(
const HepMatrix &hm1,
const HepDiagMatrix &d2);
226 HepMatrix
operator-(
const HepDiagMatrix &d1,
const HepMatrix &hm2);
227 HepDiagMatrix
operator-(
const HepDiagMatrix &d1,
const HepDiagMatrix &d2);
228 HepSymMatrix
operator-(
const HepSymMatrix &s1,
const HepDiagMatrix &d2);
229 HepSymMatrix
operator-(
const HepDiagMatrix &d1,
const HepSymMatrix &s2);
232 HepDiagMatrix
dsum(
const HepDiagMatrix &s1,
const HepDiagMatrix &s2);
237 #ifdef ENABLE_BACKWARDS_COMPATIBILITY
239 using namespace CLHEP;
242 #ifndef HEP_DEBUG_INLINE
243 #include "CLHEP/Matrix/DiagMatrix.icc"
const double & operator[](int) const
void assign(const HepMatrix &hm2)
HepDiagMatrix & operator-=(const HepDiagMatrix &hm2)
HepSymMatrix similarity(const HepMatrix &hm1) const
HepDiagMatrix_row(HepDiagMatrix &, int)
friend class HepDiagMatrix_row_const
HepDiagMatrix & operator+=(const HepDiagMatrix &hm2)
double determinant() const
double & fast(int row, int col)
HepDiagMatrix operator-() const
double & operator()(int row, int col)
HepDiagMatrix apply(double(*f)(double, int, int)) const
HepDiagMatrix inverse() const
friend HepDiagMatrix operator*(const HepDiagMatrix &hm1, const HepDiagMatrix &hm2)
HepDiagMatrix & operator*=(double t)
HepLorentzVector operator/(const HepLorentzVector &, double a)
friend class HepDiagMatrix_row
Hep3Vector operator-(const Hep3Vector &, const Hep3Vector &)
HepDiagMatrix_row_const(const HepDiagMatrix &, int)
HepDiagMatrix_row operator[](int)
HepDiagMatrix & operator=(const HepDiagMatrix &hm2)
HepSymMatrix similarityT(const HepMatrix &hm1) const
friend class HepSymMatrix
Hep3Vector operator+(const Hep3Vector &, const Hep3Vector &)
HepDiagMatrix sub(int min_row, int max_row) const
HepDiagMatrix & operator/=(double t)
std::ostream & operator<<(std::ostream &os, const HepAxisAngle &aa)
HepLorentzRotation operator*(const HepRotation &r, const HepLorentzRotation <)
HepDiagMatrix dsum(const HepDiagMatrix &s1, const HepDiagMatrix &s2)
friend HepDiagMatrix operator+(const HepDiagMatrix &hm1, const HepDiagMatrix &hm2)