babymaker  e95a6a9342d4604277fe7cc6149b6b5b24447d89
Namespaces | Macros | Typedefs | Enumerations | Functions
utilities.hh File Reference
#include <vector>
#include <string>
#include <iostream>
#include <stdexcept>
#include "DataFormats/PatCandidates/interface/Electron.h"
#include "FWCore/MessageLogger/interface/MessageLogger.h"
#include <fastjet/PseudoJet.hh>
#include "TString.h"

Go to the source code of this file.

Namespaces

 utilities
 

Macros

#define ERROR(x)   do{throw cms::Exception("babymaker") << "In " << __FILE__ << " at line " << __LINE__ << " (in function " << __func__ << "): " << x << std::endl;}while(false)
 
#define DBG(x)   do{edm::LogError("babymaker") << "In " << __FILE__ << " at line " << __LINE__ << " (in function " << __func__ << "): " << x << std::endl;}while(false)
 

Typedefs

typedef std::vector< const reco::Candidate * > vCands
 
typedef reco::Candidate::LorentzVector LVector
 

Enumerations

enum  utilities::SysEnum { utilities::kSysJER, utilities::kSysJECUp, utilities::kSysJECDn, utilities::kSysLast }
 

Functions

bool utilities::contains (const std::string &s, const std::string &pat)
 
float utilities::sumMass (const LVector &a, const LVector &b)
 
float utilities::sumPt (const LVector &a, const LVector &b)
 
float utilities::dPhi (float phi1, float phi2)
 
float utilities::dR (float phi1, float phi2, float eta1, float eta2)
 
bool utilities::greaterPt (const reco::Candidate *a, const reco::Candidate *b)
 
bool utilities::greaterM (const fastjet::PseudoJet &a, const fastjet::PseudoJet &b)
 
float utilities::getMT (float pt1, float phi1, float pt2, float phi2)
 
float utilities::getMT (float m1, float pt1, float phi1, float m2, float pt2, float phi2)
 
float utilities::getMT2 (float pt1, float phi1, float pt2, float phi2, float met, float met_phi)
 
float utilities::getMT2 (float m1, float pt1, float phi1, float m2, float pt2, float phi2, float met, float met_phi)
 
std::string utilities::execute (const std::string &cmd)
 
TString utilities::roundNumber (double num, int decimals, double denom=1.)
 
TString utilities::addCommas (double num)
 

Macro Definition Documentation

#define DBG (   x)    do{edm::LogError("babymaker") << "In " << __FILE__ << " at line " << __LINE__ << " (in function " << __func__ << "): " << x << std::endl;}while(false)

Definition at line 19 of file utilities.hh.

Referenced by event_tools::type().

#define ERROR (   x)    do{throw cms::Exception("babymaker") << "In " << __FILE__ << " at line " << __LINE__ << " (in function " << __func__ << "): " << x << std::endl;}while(false)

Typedef Documentation

typedef reco::Candidate::LorentzVector LVector

Definition at line 16 of file utilities.hh.

typedef std::vector<const reco::Candidate*> vCands

Definition at line 15 of file utilities.hh.