CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
reco::IsoDeposit::MeanDRAlgo Class Reference

#include <IsoDeposit.h>

Public Member Functions

 MeanDRAlgo ()
 
void operator+= (DepIterator deposit)
 
double result () const
 

Private Attributes

double count_
 
double sum_
 

Detailed Description

Definition at line 223 of file IsoDeposit.h.

Constructor & Destructor Documentation

◆ MeanDRAlgo()

reco::IsoDeposit::MeanDRAlgo::MeanDRAlgo ( )
inline

Definition at line 225 of file IsoDeposit.h.

225 : sum_(0.), count_(0.) {}

Member Function Documentation

◆ operator+=()

void reco::IsoDeposit::MeanDRAlgo::operator+= ( DepIterator  deposit)
inline

Definition at line 226 of file IsoDeposit.h.

226  {
227  sum_ += deposit->first.deltaR;
228  count_ += 1.0;
229  }

References count_, and sum_.

◆ result()

double reco::IsoDeposit::MeanDRAlgo::result ( ) const
inline

Definition at line 230 of file IsoDeposit.h.

230 { return sum_ / std::max(1., count_); }

References count_, SiStripPI::max, and sum_.

Member Data Documentation

◆ count_

double reco::IsoDeposit::MeanDRAlgo::count_
private

Definition at line 234 of file IsoDeposit.h.

Referenced by operator+=(), and result().

◆ sum_

double reco::IsoDeposit::MeanDRAlgo::sum_
private

Definition at line 233 of file IsoDeposit.h.

Referenced by operator+=(), and result().

reco::IsoDeposit::MeanDRAlgo::count_
double count_
Definition: IsoDeposit.h:234
SiStripPI::max
Definition: SiStripPayloadInspectorHelper.h:169
reco::IsoDeposit::MeanDRAlgo::sum_
double sum_
Definition: IsoDeposit.h:233