Logo ROOT   6.16/01
Reference Guide
Classes | Functions
TVectorT.h File Reference
#include "TMatrixT.h"
#include "TMatrixTSym.h"
#include "TMatrixTSparse.h"
Include dependency graph for TVectorT.h:
This graph shows which files directly or indirectly include this file:

Classes

class  TVectorT< Element >
 TVectorT. More...
 

Functions

template<class Element >
TVectorT< Element > & Add (TVectorT< Element > &target, Element scalar, const TMatrixT< Element > &a, const TVectorT< Element > &source)
 Modify addition: target += scalar * A * source. More...
 
template<class Element >
TVectorT< Element > & Add (TVectorT< Element > &target, Element scalar, const TMatrixTSparse< Element > &a, const TVectorT< Element > &source)
 Modify addition: target += A * source. More...
 
template<class Element >
TVectorT< Element > & Add (TVectorT< Element > &target, Element scalar, const TMatrixTSym< Element > &a, const TVectorT< Element > &source)
 Modify addition: target += A * source. More...
 
template<class Element >
TVectorT< Element > & Add (TVectorT< Element > &target, Element scalar, const TVectorT< Element > &source)
 Modify addition: target += scalar * source. More...
 
template<class Element >
TVectorT< Element > & AddElemDiv (TVectorT< Element > &target, Element scalar, const TVectorT< Element > &source1, const TVectorT< Element > &source2)
 Modify addition: target += scalar * ElementDiv(source1,source2) . More...
 
template<class Element >
TVectorT< Element > & AddElemDiv (TVectorT< Element > &target, Element scalar, const TVectorT< Element > &source1, const TVectorT< Element > &source2, const TVectorT< Element > &select)
 Modify addition: target += scalar * ElementDiv(source1,source2) only for those elements where select[i] != 0.0. More...
 
template<class Element >
TVectorT< Element > & AddElemMult (TVectorT< Element > &target, Element scalar, const TVectorT< Element > &source1, const TVectorT< Element > &source2)
 Modify addition: target += scalar * ElementMult(source1,source2) . More...
 
template<class Element >
TVectorT< Element > & AddElemMult (TVectorT< Element > &target, Element scalar, const TVectorT< Element > &source1, const TVectorT< Element > &source2, const TVectorT< Element > &select)
 Modify addition: target += scalar * ElementMult(source1,source2) only for those elements where select[i] != 0.0. More...
 
template<class Element1 , class Element2 >
Bool_t AreCompatible (const TMatrixT< Element1 > &m, const TVectorT< Element2 > &v, Int_t verbose=0)
 Check if m and v are both valid and have compatible shapes for M * v. More...
 
template<class Element1 , class Element2 >
Bool_t AreCompatible (const TVectorT< Element1 > &v, const TMatrixT< Element2 > &m, Int_t verbose=0)
 Check if m and v are both valid and have compatible shapes for v * M. More...
 
template<class Element1 , class Element2 >
Bool_t AreCompatible (const TVectorT< Element1 > &v1, const TVectorT< Element2 > &v2, Int_t verbose=0)
 Check if v1 and v2 are both valid and have the same shape. More...
 
template<class Element >
void Compare (const TVectorT< Element > &source1, const TVectorT< Element > &source2)
 Compare two vectors and print out the result of the comparison. More...
 
template<class Element >
Element Dot (const TVectorT< Element > &source1, const TVectorT< Element > &source2)
 return inner-produvt v1 . v2 More...
 
template<class Element >
TVectorT< Element > & ElementDiv (TVectorT< Element > &target, const TVectorT< Element > &source)
 Divide target by the source, element-by-element. More...
 
template<class Element >
TVectorT< Element > & ElementDiv (TVectorT< Element > &target, const TVectorT< Element > &source, const TVectorT< Element > &select)
 Divide target by the source, element-by-element only where select[i] != 0.0. More...
 
template<class Element >
TVectorT< Element > & ElementMult (TVectorT< Element > &target, const TVectorT< Element > &source)
 Multiply target by the source, element-by-element. More...
 
template<class Element >
TVectorT< Element > & ElementMult (TVectorT< Element > &target, const TVectorT< Element > &source, const TVectorT< Element > &select)
 Multiply target by the source, element-by-element only where select[i] != 0.0. More...
 
template<class Element1 , class Element2 , class Element3 >
Element1 Mult (const TVectorT< Element1 > &v1, const TMatrixT< Element2 > &m, const TVectorT< Element3 > &v2)
 Perform v1 * M * v2, a scalar result. More...
 
template<class Element >
TVectorT< Element > operator* (const TMatrixT< Element > &a, const TVectorT< Element > &source)
 return A * source More...
 
template<class Element >
TVectorT< Element > operator* (const TMatrixTSparse< Element > &a, const TVectorT< Element > &source)
 return A * source More...
 
template<class Element >
TVectorT< Element > operator* (const TMatrixTSym< Element > &a, const TVectorT< Element > &source)
 return A * source More...
 
template<class Element >
TVectorT< Element > operator* (const TVectorT< Element > &source, Element val)
 
template<class Element >
Element operator* (const TVectorT< Element > &source1, const TVectorT< Element > &source2)
 Compute the scalar product. More...
 
template<class Element >
TVectorT< Element > operator* (Element val, const TVectorT< Element > &source)
 return val * source More...
 
template<class Element >
TVectorT< Element > operator+ (const TVectorT< Element > &source1, const TVectorT< Element > &source2)
 Return source1+source2. More...
 
template<class Element >
TVectorT< Element > operator- (const TVectorT< Element > &source1, const TVectorT< Element > &source2)
 Return source1-source2. More...
 
template<class Element >
Bool_t operator== (const TVectorT< Element > &source1, const TVectorT< Element > &source2)
 Check to see if two vectors are identical. More...
 
template<class Element1 , class Element2 >
TMatrixT< Element1 > OuterProduct (const TVectorT< Element1 > &v1, const TVectorT< Element2 > &v2)
 Return the matrix M = v1 * v2'. More...
 
template<class Element1 , class Element2 , class Element3 >
TMatrixT< Element1 > & OuterProduct (TMatrixT< Element1 > &target, const TVectorT< Element2 > &v1, const TVectorT< Element3 > &v2)
 Return the matrix M = v1 * v2'. More...
 
template<class Element >
Bool_t VerifyVectorIdentity (const TVectorT< Element > &m1, const TVectorT< Element > &m2)
 
template<class Element >
Bool_t VerifyVectorIdentity (const TVectorT< Element > &m1, const TVectorT< Element > &m2, Int_t verbose)
 
template<class Element >
Bool_t VerifyVectorIdentity (const TVectorT< Element > &m1, const TVectorT< Element > &m2, Int_t verbose, Element maxDevAllow)
 Verify that elements of the two vectors are equal within maxDevAllow . More...
 
template<class Element >
Bool_t VerifyVectorValue (const TVectorT< Element > &m, Element val)
 
template<class Element >
Bool_t VerifyVectorValue (const TVectorT< Element > &m, Element val, Int_t verbose)
 
template<class Element >
Bool_t VerifyVectorValue (const TVectorT< Element > &m, Element val, Int_t verbose, Element maxDevAllow)
 Validate that all elements of vector have value val within maxDevAllow . More...
 

Function Documentation

◆ Add() [1/4]

template<class Element >
TVectorT< Element > & Add ( TVectorT< Element > &  target,
Element  scalar,
const TMatrixT< Element > &  a,
const TVectorT< Element > &  source 
)

Modify addition: target += scalar * A * source.

NOTE: in case scalar=0, do target = A * source.

Definition at line 1614 of file TVectorT.cxx.

◆ Add() [2/4]

template<class Element >
TVectorT< Element > & Add ( TVectorT< Element > &  target,
Element  scalar,
const TMatrixTSparse< Element > &  a,
const TVectorT< Element > &  source 
)

Modify addition: target += A * source.

NOTE: in case scalar=0, do target = A * source.

Definition at line 1764 of file TVectorT.cxx.

◆ Add() [3/4]

template<class Element >
TVectorT< Element > & Add ( TVectorT< Element > &  target,
Element  scalar,
const TMatrixTSym< Element > &  a,
const TVectorT< Element > &  source 
)

Modify addition: target += A * source.

NOTE: in case scalar=0, do target = A * source.

Definition at line 1692 of file TVectorT.cxx.

◆ Add() [4/4]

template<class Element >
TVectorT< Element > & Add ( TVectorT< Element > &  target,
Element  scalar,
const TVectorT< Element > &  source 
)

Modify addition: target += scalar * source.

Definition at line 1585 of file TVectorT.cxx.

◆ AddElemDiv() [1/2]

template<class Element >
TVectorT< Element > & AddElemDiv ( TVectorT< Element > &  target,
Element  scalar,
const TVectorT< Element > &  source1,
const TVectorT< Element > &  source2 
)

Modify addition: target += scalar * ElementDiv(source1,source2) .

Definition at line 1915 of file TVectorT.cxx.

◆ AddElemDiv() [2/2]

template<class Element >
TVectorT< Element > & AddElemDiv ( TVectorT< Element > &  target,
Element  scalar,
const TVectorT< Element > &  source1,
const TVectorT< Element > &  source2,
const TVectorT< Element > &  select 
)

Modify addition: target += scalar * ElementDiv(source1,source2) only for those elements where select[i] != 0.0.

Definition at line 1969 of file TVectorT.cxx.

◆ AddElemMult() [1/2]

template<class Element >
TVectorT< Element > & AddElemMult ( TVectorT< Element > &  target,
Element  scalar,
const TVectorT< Element > &  source1,
const TVectorT< Element > &  source2 
)

Modify addition: target += scalar * ElementMult(source1,source2) .

Definition at line 1842 of file TVectorT.cxx.

◆ AddElemMult() [2/2]

template<class Element >
TVectorT< Element > & AddElemMult ( TVectorT< Element > &  target,
Element  scalar,
const TVectorT< Element > &  source1,
const TVectorT< Element > &  source2,
const TVectorT< Element > &  select 
)

Modify addition: target += scalar * ElementMult(source1,source2) only for those elements where select[i] != 0.0.

Definition at line 1875 of file TVectorT.cxx.

◆ AreCompatible() [1/3]

template<class Element1 , class Element2 >
Bool_t AreCompatible ( const TMatrixT< Element1 > &  m,
const TVectorT< Element2 > &  v,
Int_t  verbose = 0 
)

Check if m and v are both valid and have compatible shapes for M * v.

Definition at line 2155 of file TVectorT.cxx.

◆ AreCompatible() [2/3]

template<class Element1 , class Element2 >
Bool_t AreCompatible ( const TVectorT< Element1 > &  v,
const TMatrixT< Element2 > &  m,
Int_t  verbose = 0 
)

Check if m and v are both valid and have compatible shapes for v * M.

Definition at line 2181 of file TVectorT.cxx.

◆ AreCompatible() [3/3]

template<class Element1 , class Element2 >
Bool_t AreCompatible ( const TVectorT< Element1 > &  v1,
const TVectorT< Element2 > &  v2,
Int_t  verbose = 0 
)

Check if v1 and v2 are both valid and have the same shape.

Definition at line 2129 of file TVectorT.cxx.

◆ Compare()

template<class Element >
void Compare ( const TVectorT< Element > &  source1,
const TVectorT< Element > &  source2 
)

Compare two vectors and print out the result of the comparison.

Definition at line 2207 of file TVectorT.cxx.

◆ Dot()

template<class Element >
Element Dot ( const TVectorT< Element > &  source1,
const TVectorT< Element > &  source2 
)

return inner-produvt v1 . v2

Definition at line 1476 of file TVectorT.cxx.

◆ ElementDiv() [1/2]

template<class Element >
TVectorT< Element > & ElementDiv ( TVectorT< Element > &  target,
const TVectorT< Element > &  source 
)

Divide target by the source, element-by-element.

Definition at line 2073 of file TVectorT.cxx.

◆ ElementDiv() [2/2]

template<class Element >
TVectorT< Element > & ElementDiv ( TVectorT< Element > &  target,
const TVectorT< Element > &  source,
const TVectorT< Element > &  select 
)

Divide target by the source, element-by-element only where select[i] != 0.0.

Definition at line 2099 of file TVectorT.cxx.

◆ ElementMult() [1/2]

template<class Element >
TVectorT< Element > & ElementMult ( TVectorT< Element > &  target,
const TVectorT< Element > &  source 
)

Multiply target by the source, element-by-element.

Definition at line 2030 of file TVectorT.cxx.

◆ ElementMult() [2/2]

template<class Element >
TVectorT< Element > & ElementMult ( TVectorT< Element > &  target,
const TVectorT< Element > &  source,
const TVectorT< Element > &  select 
)

Multiply target by the source, element-by-element only where select[i] != 0.0.

Definition at line 2050 of file TVectorT.cxx.

◆ Mult()

template<class Element1 , class Element2 , class Element3 >
Element1 Mult ( const TVectorT< Element1 > &  v1,
const TMatrixT< Element2 > &  m,
const TVectorT< Element3 > &  v2 
)

Perform v1 * M * v2, a scalar result.

Definition at line 1540 of file TVectorT.cxx.

◆ operator*() [1/6]

template<class Element >
TVectorT< Element > operator* ( const TMatrixT< Element > &  a,
const TVectorT< Element > &  source 
)

return A * source

Definition at line 1432 of file TVectorT.cxx.

◆ operator*() [2/6]

template<class Element >
TVectorT< Element > operator* ( const TMatrixTSparse< Element > &  a,
const TVectorT< Element > &  source 
)

return A * source

Definition at line 1454 of file TVectorT.cxx.

◆ operator*() [3/6]

template<class Element >
TVectorT< Element > operator* ( const TMatrixTSym< Element > &  a,
const TVectorT< Element > &  source 
)

return A * source

Definition at line 1443 of file TVectorT.cxx.

◆ operator*() [4/6]

template<class Element >
TVectorT< Element > operator* ( const TVectorT< Element > &  source,
Element  val 
)
inline

Definition at line 250 of file TVectorT.h.

◆ operator*() [5/6]

template<class Element >
Element operator* ( const TVectorT< Element > &  source1,
const TVectorT< Element > &  source2 
)

Compute the scalar product.

Definition at line 1394 of file TVectorT.cxx.

◆ operator*() [6/6]

template<class Element >
TVectorT< Element > operator* ( Element  val,
const TVectorT< Element > &  source 
)

return val * source

Definition at line 1465 of file TVectorT.cxx.

◆ operator+()

template<class Element >
TVectorT< Element > operator+ ( const TVectorT< Element > &  source1,
const TVectorT< Element > &  source2 
)

Return source1+source2.

Definition at line 1410 of file TVectorT.cxx.

◆ operator-()

template<class Element >
TVectorT< Element > operator- ( const TVectorT< Element > &  source1,
const TVectorT< Element > &  source2 
)

Return source1-source2.

Definition at line 1421 of file TVectorT.cxx.

◆ operator==()

template<class Element >
Bool_t operator== ( const TVectorT< Element > &  source1,
const TVectorT< Element > &  source2 
)

Check to see if two vectors are identical.

Definition at line 1384 of file TVectorT.cxx.

◆ OuterProduct() [1/2]

template<class Element1 , class Element2 >
TMatrixT< Element1 > OuterProduct ( const TVectorT< Element1 > &  v1,
const TVectorT< Element2 > &  v2 
)

Return the matrix M = v1 * v2'.

Definition at line 1493 of file TVectorT.cxx.

◆ OuterProduct() [2/2]

template<class Element1 , class Element2 , class Element3 >
TMatrixT< Element1 > & OuterProduct ( TMatrixT< Element1 > &  target,
const TVectorT< Element2 > &  v1,
const TVectorT< Element3 > &  v2 
)

Return the matrix M = v1 * v2'.

Definition at line 1509 of file TVectorT.cxx.

◆ VerifyVectorIdentity() [1/3]

template<class Element >
Bool_t VerifyVectorIdentity ( const TVectorT< Element > &  m1,
const TVectorT< Element > &  m2 
)

Definition at line 294 of file TVectorT.h.

◆ VerifyVectorIdentity() [2/3]

template<class Element >
Bool_t VerifyVectorIdentity ( const TVectorT< Element > &  m1,
const TVectorT< Element > &  m2,
Int_t  verbose 
)

Definition at line 292 of file TVectorT.h.

◆ VerifyVectorIdentity() [3/3]

template<class Element >
Bool_t VerifyVectorIdentity ( const TVectorT< Element > &  m1,
const TVectorT< Element > &  m2,
Int_t  verbose,
Element  maxDevAllow 
)

Verify that elements of the two vectors are equal within maxDevAllow .

Definition at line 2295 of file TVectorT.cxx.

◆ VerifyVectorValue() [1/3]

template<class Element >
Bool_t VerifyVectorValue ( const TVectorT< Element > &  m,
Element  val 
)

Definition at line 289 of file TVectorT.h.

◆ VerifyVectorValue() [2/3]

template<class Element >
Bool_t VerifyVectorValue ( const TVectorT< Element > &  m,
Element  val,
Int_t  verbose 
)

Definition at line 287 of file TVectorT.h.

◆ VerifyVectorValue() [3/3]

template<class Element >
Bool_t VerifyVectorValue ( const TVectorT< Element > &  m,
Element  val,
Int_t  verbose,
Element  maxDevAllow 
)

Validate that all elements of vector have value val within maxDevAllow .

Definition at line 2260 of file TVectorT.cxx.