//-------------------------------------------------------------------------- // // Environment: // This software is part of the EvtGen package developed jointly // for the BaBar and CLEO collaborations. If you use all or part // of it, please give an appropriate acknowledgement. // // Copyright Information: See EvtGen/COPYRIGHT // Copyright (C) 1998 Caltech, UCSB // // Module: EvtSpinDensity.cc // // Description: Class to reperesent spindensity matrices. // // Modification history: // // RYD May 29,1997 Module created // //------------------------------------------------------------------------ // #include "EvtGenBase/EvtPatches.hh" #include #include #include #include #include "EvtGenBase/EvtComplex.hh" #include "EvtGenBase/EvtSpinDensity.hh" #include "EvtGenBase/EvtReport.hh" using std::endl; using std::ostream; EvtSpinDensity::EvtSpinDensity(const EvtSpinDensity& density){ dim=0; rho=0; int i,j; setDim(density.dim); for(i=0;i0.00000001*real(prob)) { report(ERROR,"EvtGen")<<"Imaginary probability:"<abs(rho[i][i])) { report(INFO,"EvtGen") << "Failing 1"< 0.00000001*(abs(rho[i][i])+abs(rho[j][j]))) { report(INFO,"EvtGen") << "Failing 2"< 0.00000001*(abs(rho[i][i])+abs(rho[j][j]))) { report(INFO,"EvtGen") << "Failing 3"<