Public Types | |
typedef boost::shared_ptr < BeamSpotObjects > | ReturnType |
Public Member Functions | |
BeamSpotFakeConditions (const edm::ParameterSet ¶ms) | |
ReturnType | produce (const BeamSpotObjectsRcd &record) |
virtual | ~BeamSpotFakeConditions () |
Private Member Functions | |
void | setIntervalFor (const edm::eventsetup::EventSetupRecordKey &key, const edm::IOVSyncValue &syncValue, edm::ValidityInterval &oValidity) |
Private Attributes | |
std::string | BeamType |
bool | usedummy |
edm::FileInPath | xmlCalibration |
Definition at line 27 of file BeamSpotFakeConditions.cc.
typedef boost::shared_ptr<BeamSpotObjects> BeamSpotFakeConditions::ReturnType |
Definition at line 29 of file BeamSpotFakeConditions.cc.
BeamSpotFakeConditions::BeamSpotFakeConditions | ( | const edm::ParameterSet & | params | ) |
Definition at line 41 of file BeamSpotFakeConditions.cc.
References edm::ESProducer::setWhatProduced().
00041 : 00042 00043 //xmlCalibration(params.getParameter<edm::FileInPath>("xmlCalibration") ), //disable until xml writer is fixed 00044 usedummy(params.getParameter<bool>("UseDummy") ), 00045 BeamType(params.getParameter<std::string>("BeamType") ) { 00046 00047 setWhatProduced(this); 00048 findingRecord<BeamSpotObjectsRcd>(); 00049 }
BeamSpotFakeConditions::~BeamSpotFakeConditions | ( | ) | [virtual] |
BeamSpotFakeConditions::ReturnType BeamSpotFakeConditions::produce | ( | const BeamSpotObjectsRcd & | record | ) |
Definition at line 54 of file BeamSpotFakeConditions.cc.
References BeamType, e, funct::pow(), BeamSpotObjects::SetBeamWidth(), BeamSpotObjects::SetCovariance(), BeamSpotObjects::Setdxdz(), BeamSpotObjects::Setdydz(), BeamSpotObjects::SetPosition(), BeamSpotObjects::SetSigmaZ(), and usedummy.
00054 { 00055 00056 00057 if ( ! usedummy ) { 00058 //TBufferXML code removed from here... 00059 } 00060 else { 00061 00062 BeamSpotObjects *adummy = new BeamSpotObjects(); 00063 00064 // we are going to use the truth values defined at the generator stage, 00065 // see IOMC/EventVertexGenerators/data 00066 00068 // FOR THE MOMENT, FAKE CONDITIONS ARE A HARD WIRED COPY OF THE DB CONDITIONS 00070 00071 if ( BeamType == "SimpleGaussian" || BeamType == "DummySigmaZ_5p3cm") { 00072 adummy->SetPosition(0.,0.,0.); 00073 adummy->SetSigmaZ(5.3); 00074 adummy->Setdxdz(0.); 00075 adummy->Setdydz(0.); 00076 adummy->SetBeamWidth(15.e-4); 00077 } 00078 00079 else if ( BeamType == "Early10TeVCollision" ) { 00080 adummy->SetPosition(0.0325127,0.000505765,0.0795808); 00081 adummy->SetSigmaZ(3.79659); 00082 adummy->Setdxdz(4.58986e-05); 00083 adummy->Setdydz(-0.000112271); 00084 adummy->SetBeamWidth(46.0e-4); 00085 adummy->SetCovariance(0,0,pow(5.17247e-05,2)); 00086 adummy->SetCovariance(1,1,pow(5.01696e-05,2)); 00087 adummy->SetCovariance(2,2,pow(0.467712,2)); 00088 adummy->SetCovariance(3,3,pow(0.400947,2)); 00089 adummy->SetCovariance(4,4,pow(1.39248e-05,2)); 00090 adummy->SetCovariance(5,5,pow(1.31797e-05,2)); 00091 adummy->SetCovariance(6,6,pow(2.0e-4,2)); 00092 } 00093 00094 else if ( BeamType == "EarlyCollision" ) { 00095 adummy->SetPosition(0.032206,-1.97386e-05,-0.282702); 00096 adummy->SetSigmaZ(5.3); // temporal 00097 adummy->Setdxdz(1.76367e-06); 00098 adummy->Setdydz(-2.58129e-05); 00099 adummy->SetBeamWidth(31.7e-4); 00100 adummy->SetCovariance(0,0,pow(6.96e-05,2)); 00101 adummy->SetCovariance(1,1,pow(6.74e-5,2)); 00102 adummy->SetCovariance(2,2,pow(0.70,2)); 00103 adummy->SetCovariance(3,3,pow(0.1,2));// temporal 00104 adummy->SetCovariance(4,4,pow(9.74e-6,2)); 00105 adummy->SetCovariance(5,5,pow(9.64e-6,2)); 00106 adummy->SetCovariance(6,6,pow(2.0e-4,2)); 00107 } 00108 00109 else if ( BeamType == "NominalCollision" ) { 00110 adummy->SetPosition(0.05,0.,0.); 00111 adummy->SetSigmaZ(5.3); 00112 adummy->Setdxdz(140.e-6); 00113 adummy->Setdydz(0.); 00114 adummy->SetBeamWidth(16.6e-4); 00115 } 00116 // extreme cases 00117 else if ( BeamType == "NominalCollision1" ) { 00118 adummy->SetPosition(0.05,0.025,0.); 00119 adummy->SetSigmaZ(5.3); 00120 adummy->Setdxdz(0.); 00121 adummy->Setdydz(0.); 00122 adummy->SetBeamWidth(16.6e-4); 00123 } 00124 00125 else if ( BeamType == "NominalCollision2" ) { 00126 adummy->SetPosition(0.05,0.025,0.); 00127 adummy->SetSigmaZ(5.3); 00128 adummy->Setdxdz(140.e-6); 00129 adummy->Setdydz(0.); 00130 adummy->SetBeamWidth(16.6e-4); 00131 } 00132 00133 else if ( BeamType == "NominalCollision3" ) { 00134 adummy->SetPosition(0.1,0.025,0.); 00135 adummy->SetSigmaZ(5.3); 00136 adummy->Setdxdz(0.); 00137 adummy->Setdydz(0.); 00138 adummy->SetBeamWidth(16.6e-4); 00139 } 00140 00141 else if ( BeamType == "NominalCollision4" ) { 00142 adummy->SetPosition(0.2,0.025,0.); 00143 adummy->SetSigmaZ(5.3); 00144 adummy->Setdxdz(0.); 00145 adummy->Setdydz(0.); 00146 adummy->SetBeamWidth(16.6e-4); 00147 } 00148 00149 00150 return ReturnType(adummy); 00151 } 00152 00153 00154 }
void BeamSpotFakeConditions::setIntervalFor | ( | const edm::eventsetup::EventSetupRecordKey & | key, | |
const edm::IOVSyncValue & | syncValue, | |||
edm::ValidityInterval & | oValidity | |||
) | [private, virtual] |
Implements edm::EventSetupRecordIntervalFinder.
Definition at line 156 of file BeamSpotFakeConditions.cc.
References edm::IOVSyncValue::beginOfTime(), and edm::IOVSyncValue::endOfTime().
00158 { 00159 oValidity = edm::ValidityInterval(edm::IOVSyncValue::beginOfTime(), 00160 edm::IOVSyncValue::endOfTime()); 00161 }
std::string BeamSpotFakeConditions::BeamType [private] |
bool BeamSpotFakeConditions::usedummy [private] |
Definition at line 35 of file BeamSpotFakeConditions.cc.