214 using namespace reco;
224 vs_sell = vertices3->size();
226 vzr_sell = vertices3->begin()->z();
234 double tower_eta, tower_phi;
235 double tower_energyet, tower_energyet_e, tower_energyet_h;
236 double s1,
s2, s13,s23,s14,s24,s15,s25,s16,s26;
243 tower_eta =
j->eta();
244 tower_phi =
j->phi();
245 tower_energyet_e =
j->emEt();
246 tower_energyet_h =
j->hadEt();
247 tower_energyet = tower_energyet_e + tower_energyet_h;
249 s1 =
sin(2.*tower_phi);
250 s2 =
cos(2.*tower_phi);
251 s13 =
sin(3.*tower_phi);
252 s23 =
cos(3.*tower_phi);
253 s14 =
sin(4.*tower_phi);
254 s24 =
cos(4.*tower_phi);
255 s15 =
sin(5.*tower_phi);
256 s25 =
cos(5.*tower_phi);
257 s16 =
sin(6.*tower_phi);
258 s26 =
cos(6.*tower_phi);
260 if(tower_energyet<
minet_)
continue;
261 if(tower_energyet>
maxet_)
continue;;
297 #ifdef TRACKCOLLECTION
302 for(reco::TrackCollection::const_iterator
j = tracks->begin();
j != tracks->end();
j++){
306 #ifdef RECOCHARGEDCANDIDATECOLLECTION
308 iEvent.
getByLabel(
"allMergedPtSplit12Tracks",trackCollection);
313 for(reco::RecoChargedCandidateCollection::const_iterator
j = tracks->begin();
j != tracks->end();
j++){
321 double vzErr =0.0, vxErr=0.0, vyErr=0.0;
322 if(vertex->size()>0) {
323 vtxPoint=vertex->begin()->position();
324 vzErr=vertex->begin()->zError();
325 vxErr=vertex->begin()->xError();
326 vyErr=vertex->begin()->yError();
328 bool accepted =
true;
329 bool isPixel =
false;
331 if (
j->numberOfValidHits() < 7 ) isPixel =
true;
334 double d0=0.0, dz=0.0, d0sigma=0.0, dzsigma=0.0;
335 d0 = -1.*
j->dxy(vtxPoint);
336 dz =
j->dz(vtxPoint);
337 d0sigma =
sqrt(
j->d0Error()*
j->d0Error()+vxErr*vyErr);
338 dzsigma =
sqrt(
j->dzError()*
j->dzError()+vzErr*vzErr);
344 if ( fabs(dz/dzsigma) >
dzerr_ ) accepted =
false;
347 if (
j->normalizedChi2() >
chi2_ ) accepted =
false;
354 if ( fabs(dz/dzsigma) > 3 ) accepted =
false;
355 if ( fabs(d0/d0sigma) > 3 ) accepted =
false;
358 if (
j->ptError()/
j->pt() > 0.05 ) accepted =
false;
361 if (
j->numberOfValidHits() < 12 ) accepted =
false;
364 track_eta =
j->eta();
365 track_phi =
j->phi();
367 double s =
sin(2*track_phi);
368 double c =
cos(2*track_phi);
369 double s3 =
sin(3*track_phi);
370 double c3 =
cos(3*track_phi);
371 double s4 =
sin(4*track_phi);
372 double c4 =
cos(4*track_phi);
373 double s5 =
sin(5*track_phi);
374 double c5 =
cos(5*track_phi);
375 double s6 =
sin(6*track_phi);
376 double c6 =
cos(6*track_phi);
382 if(track_pt<
minpt_)
continue;
383 if(track_pt>
maxpt_)
continue;
419 for(
int i = 0;
i<9;
i++) {
420 evtplaneOutput->push_back(*ep[
i]);
425 if(
EPNames[
i].rfind(
"Ecal")!=string::npos) {
426 evtplaneOutput->push_back(*ep[
i]);
429 if(
EPNames[
i].rfind(
"Hcal")!=string::npos) {
430 evtplaneOutput->push_back(*ep[
i]);
433 evtplaneOutput->push_back(*ep[
i]);
437 iEvent.
put(evtplaneOutput,
"recoLevel");
double getAngle(double &ang, double &sv, double &cv)
Sin< T >::type sin(const T &t)
std::vector< CaloTower >::const_iterator const_iterator
std::vector< Vertex > VertexCollection
collection of Vertex objects
const std::string EPNames[]
GenPlane * rp[NumEPNames]
OrphanHandle< PROD > put(std::auto_ptr< PROD > product)
Put a new product.
Cos< T >::type cos(const T &t)
std::vector< EvtPlane > EvtPlaneCollection
bool getByLabel(InputTag const &tag, Handle< PROD > &result) const
std::vector< RecoChargedCandidate > RecoChargedCandidateCollection
collectin of RecoChargedCandidate objects
void addParticle(double w, double s, double c, double eta)
XYZPointD XYZPoint
point in space with cartesian internal representation
T const * product() const
edm::InputTag caloCollection_
edm::InputTag vtxCollection_
static const int NumEPNames
edm::InputTag trackCollection_
void reset(double vett[256])