laura is hosted by Hepforge, IPPP Durham
Laura++  v3r5
A maximum likelihood fitting package for performing Dalitz-plot analysis.

Class for blinding and unblinding a number based on a blinding string. More...

#include <LauBlind.hh>

Public Member Functions

 LauBlind (const TString &blindingStr, const Double_t width)
 Constructor. More...
 
 LauBlind (const LauBlind &rhs)
 Copy constructor. More...
 
virtual ~LauBlind ()
 Destructor. More...
 
Double_t blind (const Double_t val) const
 Obtain the blinded value. More...
 
Double_t unblind (const Double_t val) const
 Obtain the unblinded value. More...
 
const TString & blindingString () const
 Obtain the blinding string. More...
 
Double_t blindingWidth () const
 Obtain the Gaussian width. More...
 
 LauBlind ()
 Default constructor. More...
 

Private Member Functions

LauBlindoperator= (const LauBlind &rhs)
 Copy assignment operator (not implemented) More...
 
void calcOffset ()
 Calculate the offset. More...
 

Private Attributes

const TString blindingString_
 The blinding string. More...
 
const Double_t blindingWidth_
 The Gaussian width. More...
 
Double_t offset_
 The offset used to blind the value. More...
 

Detailed Description

Class for blinding and unblinding a number based on a blinding string.

Numbers are blinded by applying an offset. The blinding string is converted to an integer using TMath::Hash and this integer is used to seed a TRandom3. The offset is sampled from a Gaussian of defined width using the seeded TRandom3.

Definition at line 42 of file LauBlind.hh.

Constructor & Destructor Documentation

LauBlind::LauBlind ( const TString &  blindingStr,
const Double_t  width 
)

Constructor.

Parameters
[in]blindingStrthe blinding string
[in]widththe width of the Gaussian for sampling the offset

Definition at line 44 of file LauBlind.cc.

LauBlind::LauBlind ( const LauBlind rhs)

Copy constructor.

Definition at line 52 of file LauBlind.cc.

LauBlind::~LauBlind ( )
virtual

Destructor.

Definition at line 59 of file LauBlind.cc.

LauBlind::LauBlind ( )

Default constructor.

This is purely to allow I/O to succeed, should not generally be used

Definition at line 37 of file LauBlind.cc.

Member Function Documentation

Double_t LauBlind::blind ( const Double_t  val) const
inline

Obtain the blinded value.

Parameters
[in]valthe unblinded value
Returns
the blinded value

Definition at line 63 of file LauBlind.hh.

const TString& LauBlind::blindingString ( ) const
inline

Obtain the blinding string.

Returns
the blinding string

Definition at line 76 of file LauBlind.hh.

Double_t LauBlind::blindingWidth ( ) const
inline

Obtain the Gaussian width.

Returns
the Gaussian width

Definition at line 82 of file LauBlind.hh.

void LauBlind::calcOffset ( )
private

Calculate the offset.

Definition at line 63 of file LauBlind.cc.

LauBlind& LauBlind::operator= ( const LauBlind rhs)
private

Copy assignment operator (not implemented)

Double_t LauBlind::unblind ( const Double_t  val) const
inline

Obtain the unblinded value.

Parameters
[in]valthe blinded value
Returns
the unblinded value

Definition at line 70 of file LauBlind.hh.

Member Data Documentation

const TString LauBlind::blindingString_
private

The blinding string.

Definition at line 92 of file LauBlind.hh.

const Double_t LauBlind::blindingWidth_
private

The Gaussian width.

Definition at line 95 of file LauBlind.hh.

Double_t LauBlind::offset_
private

The offset used to blind the value.

Definition at line 98 of file LauBlind.hh.


The documentation for this class was generated from the following files: