Logo ROOT  
Reference Guide
MnEigen.cxx
Go to the documentation of this file.
1 // @(#)root/minuit2:$Id$
2 // Authors: M. Winkler, F. James, L. Moneta, A. Zsenei 2003-2005
3 
4 /**********************************************************************
5  * *
6  * Copyright (c) 2005 LCG ROOT Math team, CERN/PH-SFT *
7  * *
8  **********************************************************************/
9 
10 #include "Minuit2/MnEigen.h"
12 #include "Minuit2/MnMatrix.h"
13 
14 namespace ROOT {
15 
16 namespace Minuit2 {
17 
18 LAVector eigenvalues(const LASymMatrix &);
19 
20 std::vector<double> MnEigen::operator()(const MnUserCovariance &covar) const
21 {
22  // wrapper to calculate eigenvalues of the covariance matrix using mneigen function
23 
24  LASymMatrix cov(covar.Nrow());
25  for (unsigned int i = 0; i < covar.Nrow(); i++)
26  for (unsigned int j = i; j < covar.Nrow(); j++)
27  cov(i, j) = covar(i, j);
28 
29  LAVector eigen = eigenvalues(cov);
30 
31  std::vector<double> result(eigen.Data(), eigen.Data() + covar.Nrow());
32  return result;
33 }
34 
35 } // namespace Minuit2
36 
37 } // namespace ROOT
ROOT::Minuit2::LAVector
Definition: LAVector.h:32
ROOT::Minuit2::eigenvalues
LAVector eigenvalues(const LASymMatrix &mat)
Definition: LaEigenValues.cxx:19
ROOT::Minuit2::LAVector::Data
const double * Data() const
Definition: LAVector.h:223
ROOT::Minuit2::LASymMatrix
Class describing a symmetric matrix of size n.
Definition: LASymMatrix.h:45
MnMatrix.h
MnEigen.h
ROOT::Minuit2::MnEigen::operator()
std::vector< double > operator()(const MnUserCovariance &) const
calculate the eigenvalues
Definition: MnEigen.cxx:20
ROOT::Minuit2::MnUserCovariance
Class containing the covariance matrix data represented as a vector of size n*(n+1)/2 Used to hide in...
Definition: MnUserCovariance.h:26
ROOT::Minuit2::MnUserCovariance::Nrow
unsigned int Nrow() const
Definition: MnUserCovariance.h:84
MnUserCovariance.h
ROOT
tbb::task_arena is an alias of tbb::interface7::task_arena, which doesn't allow to forward declare tb...
Definition: EExecutionPolicy.hxx:4