56 fout.open(
"fittedEntries.out" );
57 fout2.open(
"longFittedEntries.out" );
65 std::vector< FittedEntriesSet* >::const_iterator vfescite;
66 std::vector< FittedEntry* >::const_iterator vfecite;
74 for( vfecite = ((*vfescite)->FittedEntries()).
begin(); vfecite != ((*vfescite)->FittedEntries()).
end(); ++vfecite) {
76 fout << ii <<
": " << std::setw(13) << filename <<
" ";;
77 if(
ALIUtils::debug >= 3)
std::cout << ii <<
": " << std::setw(13) << filename <<
" = " << (*vfecite)->getName() << std::endl;
91 if( gomgr->
GlobalOptions()[
"DumpDateInFittedEntries"] >= 1 ) {
92 fout << (*vfescite)->getDate() <<
" " << (*vfescite)->getTime() <<
" ";
93 fout2 << (*vfescite)->getDate() <<
" " << (*vfescite)->getTime() <<
" ";
97 for( vfecite = ((*vfescite)->FittedEntries()).
begin(); vfecite != ((*vfescite)->FittedEntries()).
end(); ++vfecite) {
100 fout << std::setprecision(8) << std::setw(10) << (*vfecite)->getValue() <<
" " << (*vfecite)->getSigma() <<
" ";
103 if(
ALIUtils::debug >= 3)
std::cout <<
" FITTEDENTRY:" << std::setprecision(5) << std::setw(8) << (*vfecite)->getValue() <<
" +- " << (*vfecite)->getSigma() << std::endl;
106 fout2 << std::setprecision(8) << std::setw(10) << filename<<
" " << (*vfecite)->getValue() <<
" " << (*vfecite)->getSigma() <<
" ";
130 std::vector< OpticalObject* >::const_iterator ite;
131 std::map< ALIstring, LightRay* > lrays;
133 for( ite = optoList.begin(); ite != optoList.end(); ++ite ){
134 if( (*ite)->type() ==
"laser" ){
137 lrays[(*ite)->parent()->name()] = lightray;
141 std::map< ALIstring, LightRay* >::const_iterator lite1, lite2;
142 for( lite1 = lrays.begin(); lite1 != lrays.end(); ++lite1 ){
143 lite2 = lite1; ++lite2;
144 for( ; lite2 != lrays.end(); ++lite2 ){
145 if( lite1 == lite2 )
continue;
146 CLHEP::Hep3Vector dirdiff = ((*lite1).second->direction() - (*lite2).second->direction());
148 std::cout <<
"LASER DIFF " << (*lite1).first <<
" & " << (*lite2).first <<
" " << dirdiff.mag()*180./
M_PI <<
"o " << dirdiff.mag() <<
" rad " << dirdiff << std::endl;
150 (*lite1).second->dumpData(
ALIstring(
" laser ") + (*lite1).first );
151 (*lite2).second->dumpData(
ALIstring(
" laser ") + (*lite2).first );
175 filename = optoName.substr( 2, optoName.size() );
178 slash = filename.find(
'/', slash+1);
179 if( slash == -1 )
break;
180 filename[
slash] =
'.';
184 ALIint space = entryName.rfind(
' ');
185 filename.append(
".");
187 if( space != -1) en[space] =
'_';
191 filename.append( en);
231 fout << std::setprecision(6) <<std::setw(8) << val <<
" +- " << sig <<
" ";
232 if(
ALIUtils::debug >= 3)
std::cout <<
" FITTEDENTRY:" << std::setprecision(5) << std::setw(8) << val <<
" +- " << sig << std::endl;
void AddFittedEntriesSet(FittedEntriesSet *fents)
void dumpEntriesSubstraction(std::ofstream &fout, FittedEntriesSet &fes, ALIint order1, ALIint order2)
ALIstring createFileName(const ALIstring &optoName, const ALIstring &entryName)
static GlobalOptionMgr * getInstance()
void GetDifferentBetweenLasers()
ALIdouble getSigma() const
std::vector< FittedEntry * > & FittedEntries()
static FittedEntriesManager * getInstance()
static FittedEntriesManager * instance
static std::vector< OpticalObject * > & OptOList()
std::vector< FittedEntriesSet * > theFittedEntriesSets
void startLightRay(OpticalObject *opto)
ALIdouble getValue() const
std::map< ALIstring, ALIdouble, std::less< ALIstring > > & GlobalOptions()
static void dumpDimensions(std::ofstream &fout)