CMS 3D CMS Logo

List of all members | Public Member Functions | Private Member Functions | Private Attributes
LASModuleProfile Class Reference

#include <LASModuleProfile.h>

Public Member Functions

void DumpToArray (double[512])
 
double GetValue (unsigned int theStripNumber) const
 
 LASModuleProfile ()
 
 LASModuleProfile (double *)
 
 LASModuleProfile (int *)
 
LASModuleProfile operator+ (const LASModuleProfile &)
 
LASModuleProfile operator+ (const double[512])
 
LASModuleProfileoperator+= (const LASModuleProfile &)
 
LASModuleProfileoperator+= (const double[512])
 
LASModuleProfileoperator+= (const int[512])
 
LASModuleProfile operator- (const LASModuleProfile &)
 
LASModuleProfile operator- (const double[512])
 
LASModuleProfileoperator-= (const LASModuleProfile &)
 
LASModuleProfileoperator-= (const double[512])
 
LASModuleProfileoperator-= (const int[512])
 
LASModuleProfileoperator/= (const double)
 
LASModuleProfileoperator= (const LASModuleProfile &)
 
void SetAllValuesTo (const double &)
 
void SetData (double *)
 
void SetData (int *)
 
void SetValue (unsigned int theStripNumber, const double &theValue)
 

Private Member Functions

void Init (void)
 

Private Attributes

std::vector< double > data
 

Detailed Description

Definition at line 7 of file LASModuleProfile.h.

Constructor & Destructor Documentation

◆ LASModuleProfile() [1/3]

LASModuleProfile::LASModuleProfile ( )

container class for a LAS SiStrip module's 512 strip signals

def constructor

Definition at line 7 of file LASModuleProfile.cc.

References Init().

Referenced by operator+(), and operator-().

7  {
11 
12  Init();
13 }

◆ LASModuleProfile() [2/3]

LASModuleProfile::LASModuleProfile ( double *  )

◆ LASModuleProfile() [3/3]

LASModuleProfile::LASModuleProfile ( int *  )

Member Function Documentation

◆ DumpToArray()

void LASModuleProfile::DumpToArray ( double  array[512])

fill array

Definition at line 85 of file LASModuleProfile.cc.

References mps_check::array, data, and mps_fire::i.

85  {
89 
90  for (unsigned int i = 0; i < 512; ++i) {
91  array[i] = data.at(i);
92  }
93 }
std::vector< double > data

◆ GetValue()

double LASModuleProfile::GetValue ( unsigned int  theStripNumber) const
inline

◆ Init()

void LASModuleProfile::Init ( void  )
private

everything needed for initialization

Definition at line 95 of file LASModuleProfile.cc.

References data.

Referenced by LASModuleProfile().

95  {
99 
100  data.resize(512);
101 }
std::vector< double > data

◆ operator+() [1/2]

LASModuleProfile LASModuleProfile::operator+ ( const LASModuleProfile anotherProfile)

Definition at line 118 of file LASModuleProfile.cc.

References GetValue(), mps_fire::i, and LASModuleProfile().

118  {
122 
123  double theArray[512];
124  for (unsigned int i = 0; i < 512; ++i) {
125  theArray[i] = this->GetValue(i) + anotherProfile.GetValue(i);
126  }
127 
128  return (LASModuleProfile(theArray));
129 }
double GetValue(unsigned int theStripNumber) const

◆ operator+() [2/2]

LASModuleProfile LASModuleProfile::operator+ ( const double  b[512])

add a double[512]

Definition at line 144 of file LASModuleProfile.cc.

References GetValue(), mps_fire::i, and LASModuleProfile().

144  {
148 
149  double theArray[512];
150  for (unsigned int i = 0; i < 512; ++i) {
151  theArray[i] = this->GetValue(i) + b[i];
152  }
153 
154  return (LASModuleProfile(theArray));
155 }
double GetValue(unsigned int theStripNumber) const
double b
Definition: hdecay.h:118

◆ operator+=() [1/3]

LASModuleProfile & LASModuleProfile::operator+= ( const LASModuleProfile anotherProfile)

Definition at line 170 of file LASModuleProfile.cc.

References data, GetValue(), and mps_fire::i.

170  {
174 
175  for (unsigned int i = 0; i < 512; ++i) {
176  data.at(i) += anotherProfile.GetValue(i);
177  }
178 
179  return *this;
180 }
double GetValue(unsigned int theStripNumber) const
std::vector< double > data

◆ operator+=() [2/3]

LASModuleProfile & LASModuleProfile::operator+= ( const double  b[512])

Definition at line 194 of file LASModuleProfile.cc.

References b, data, and mps_fire::i.

194  {
198 
199  for (unsigned int i = 0; i < 512; ++i) {
200  data.at(i) += b[i];
201  }
202 
203  return *this;
204 }
std::vector< double > data
double b
Definition: hdecay.h:118

◆ operator+=() [3/3]

LASModuleProfile & LASModuleProfile::operator+= ( const int  b[512])

temporary workaround as long as data is provided in int arrays

Definition at line 218 of file LASModuleProfile.cc.

References b, data, and mps_fire::i.

218  {
223 
224  for (unsigned int i = 0; i < 512; ++i) {
225  data.at(i) += b[i];
226  }
227 
228  return *this;
229 }
std::vector< double > data
double b
Definition: hdecay.h:118

◆ operator-() [1/2]

LASModuleProfile LASModuleProfile::operator- ( const LASModuleProfile anotherProfile)

Definition at line 131 of file LASModuleProfile.cc.

References GetValue(), mps_fire::i, and LASModuleProfile().

131  {
135 
136  double theArray[512];
137  for (unsigned int i = 0; i < 512; ++i) {
138  theArray[i] = this->GetValue(i) - anotherProfile.GetValue(i);
139  }
140 
141  return (LASModuleProfile(theArray));
142 }
double GetValue(unsigned int theStripNumber) const

◆ operator-() [2/2]

LASModuleProfile LASModuleProfile::operator- ( const double  b[512])

subtract a double[512]

Definition at line 157 of file LASModuleProfile.cc.

References GetValue(), mps_fire::i, and LASModuleProfile().

157  {
161 
162  double theArray[512];
163  for (unsigned int i = 0; i < 512; ++i) {
164  theArray[i] = this->GetValue(i) - b[i];
165  }
166 
167  return (LASModuleProfile(theArray));
168 }
double GetValue(unsigned int theStripNumber) const
double b
Definition: hdecay.h:118

◆ operator-=() [1/3]

LASModuleProfile & LASModuleProfile::operator-= ( const LASModuleProfile anotherProfile)

Definition at line 182 of file LASModuleProfile.cc.

References data, GetValue(), and mps_fire::i.

182  {
186 
187  for (unsigned int i = 0; i < 512; ++i) {
188  data.at(i) -= anotherProfile.GetValue(i);
189  }
190 
191  return *this;
192 }
double GetValue(unsigned int theStripNumber) const
std::vector< double > data

◆ operator-=() [2/3]

LASModuleProfile & LASModuleProfile::operator-= ( const double  b[512])

Definition at line 206 of file LASModuleProfile.cc.

References b, data, and mps_fire::i.

206  {
210 
211  for (unsigned int i = 0; i < 512; ++i) {
212  data.at(i) -= b[i];
213  }
214 
215  return *this;
216 }
std::vector< double > data
double b
Definition: hdecay.h:118

◆ operator-=() [3/3]

LASModuleProfile & LASModuleProfile::operator-= ( const int  b[512])

temporary workaround as long as data is provided in int arrays

Definition at line 231 of file LASModuleProfile.cc.

References b, data, and mps_fire::i.

231  {
236 
237  for (unsigned int i = 0; i < 512; ++i) {
238  data.at(i) -= b[i];
239  }
240 
241  return *this;
242 }
std::vector< double > data
double b
Definition: hdecay.h:118

◆ operator/=()

LASModuleProfile & LASModuleProfile::operator/= ( const double  divisor)

handle with care!!

Definition at line 244 of file LASModuleProfile.cc.

References data, and mps_fire::i.

244  {
248 
249  for (unsigned int i = 0; i < 512; ++i) {
250  data.at(i) /= divisor;
251  }
252 
253  return *this;
254 }
std::vector< double > data

◆ operator=()

LASModuleProfile & LASModuleProfile::operator= ( const LASModuleProfile anotherProfile)

Definition at line 103 of file LASModuleProfile.cc.

References data, GetValue(), and mps_fire::i.

103  {
107 
108  // check for self-assignment
109  if (this != &anotherProfile) {
110  for (unsigned int i = 0; i < 512; ++i) {
111  data.at(i) = anotherProfile.GetValue(i);
112  }
113  }
114 
115  return *this;
116 }
double GetValue(unsigned int theStripNumber) const
std::vector< double > data

◆ SetAllValuesTo()

void LASModuleProfile::SetAllValuesTo ( const double &  theValue)

Definition at line 76 of file LASModuleProfile.cc.

References data, and mps_fire::i.

Referenced by LaserAlignment::beginJob(), and LaserAlignment::fillDataProfiles().

76  {
80 
81  for (unsigned int i = 0; i < data.size(); ++i)
82  data.at(i) = theValue;
83 }
std::vector< double > data

◆ SetData() [1/2]

void LASModuleProfile::SetData ( double *  )

◆ SetData() [2/2]

void LASModuleProfile::SetData ( int *  )

◆ SetValue()

void LASModuleProfile::SetValue ( unsigned int  theStripNumber,
const double &  theValue 
)
inline

Definition at line 20 of file LASModuleProfile.h.

References data.

Referenced by LaserAlignment::fillDataProfiles(), and LaserAlignment::fillPedestalProfiles().

20 { data.at(theStripNumber) = theValue; }
std::vector< double > data

Member Data Documentation

◆ data

std::vector<double> LASModuleProfile::data
private

Definition at line 38 of file LASModuleProfile.h.

Referenced by MainPageGenerator.MainPageGenerator::__NewTreePage(), data_sources.node::__str__(), confdb.HLTProcess::_fix_parameter(), confdb.HLTProcess::addEras(), confdb.HLTProcess::addGlobalOptions(), confdb.HLTProcess::append_filenames(), data_sources.json_list::as_dicts(), data_sources.json_list::as_table(), confdb.HLTProcess::build_source(), MainPageGenerator.MainPageGenerator::CreateNewMainPage(), confdb.HLTProcess::customize(), confdb.HLTProcess::dump(), DumpToArray(), MainPageGenerator.MainPageGenerator::ExportJSON(), confdb.HLTProcess::fixPrescales(), data_sources.json_list::get_members(), confdb.HLTProcess::getRawConfigurationFromDB(), GetValue(), Init(), confdb.HLTProcess::instrumentDQM(), confdb.HLTProcess::instrumentOpenMode(), confdb.HLTProcess::instrumentTiming(), data_sources.json_list::last(), confdb.HLTProcess::loadAdditionalConditions(), confdb.HLTProcess::loadCff(), confdb.HLTProcess::loadSetupCff(), operator+=(), operator-=(), operator/=(), operator=(), confdb.HLTProcess::overrideGlobalTag(), confdb.HLTProcess::overrideL1MenuXml(), confdb.HLTProcess::overrideOutput(), confdb.HLTProcess::overrideParameters(), confdb.HLTProcess::overrideProcessName(), confdb.HLTProcess::removeElementFromSequencesTasksAndPaths(), confdb.HLTProcess::runL1Emulator(), SetAllValuesTo(), SetValue(), confdb.HLTProcess::specificCustomize(), cuy.FindIssue::startElement(), edmStreamStallGrapher.Stack::update(), and confdb.HLTProcess::updateMessageLogger().