CMS 3D CMS Logo

List of all members | Public Member Functions | Private Types | Private Member Functions | Private Attributes
MultiGaussianStateAssembler< N > Class Template Reference

#include <MultiGaussianStateAssembler.h>

Public Member Functions

void addState (const MultiState &state)
 
void addState (const SingleStatePtr &state)
 
MultiState combinedState ()
 
MultiState combinedState (const float weight)
 
 MultiGaussianStateAssembler ()=default
 

Private Types

typedef MultiGaussianState< NMultiState
 
typedef SingleGaussianState< NSingleState
 
typedef MultiGaussianState< N >::SingleStateContainer SingleStateContainer
 
typedef MultiGaussianState< N >::SingleStatePtr SingleStatePtr
 

Private Member Functions

void addStateVector (const SingleStateContainer &)
 
bool prepareCombinedState ()
 
void removeSmallWeights ()
 
MultiState reweightedCombinedState (const double) const
 

Private Attributes

bool combinationDone = false
 
double minFractionalWeight = 1.e-16
 
SingleStateContainer theStates
 
double theValidWeightSum = 0
 

Detailed Description

template<unsigned int N>
class MultiGaussianStateAssembler< N >

Collects gaussian states and returns a MultiGaussianState.

Definition at line 14 of file MultiGaussianStateAssembler.h.

Member Typedef Documentation

◆ MultiState

template<unsigned int N>
typedef MultiGaussianState<N> MultiGaussianStateAssembler< N >::MultiState
private

Definition at line 17 of file MultiGaussianStateAssembler.h.

◆ SingleState

template<unsigned int N>
typedef SingleGaussianState<N> MultiGaussianStateAssembler< N >::SingleState
private

Definition at line 16 of file MultiGaussianStateAssembler.h.

◆ SingleStateContainer

Definition at line 19 of file MultiGaussianStateAssembler.h.

◆ SingleStatePtr

template<unsigned int N>
typedef MultiGaussianState<N>::SingleStatePtr MultiGaussianStateAssembler< N >::SingleStatePtr
private

Definition at line 18 of file MultiGaussianStateAssembler.h.

Constructor & Destructor Documentation

◆ MultiGaussianStateAssembler()

template<unsigned int N>
MultiGaussianStateAssembler< N >::MultiGaussianStateAssembler ( )
default

Member Function Documentation

◆ addState() [1/2]

template<unsigned int N>
void MultiGaussianStateAssembler< N >::addState ( const MultiState state)

Adds a new MultiGaussianState to the list of components

◆ addState() [2/2]

template<unsigned int N>
void MultiGaussianStateAssembler< N >::addState ( const SingleStatePtr state)

◆ addStateVector()

template<unsigned int N>
void MultiGaussianStateAssembler< N >::addStateVector ( const SingleStateContainer )
private

Adds a vector of gaussian states to the list of components

◆ combinedState() [1/2]

template<unsigned int N>
MultiState MultiGaussianStateAssembler< N >::combinedState ( )

Returns the resulting MultiGaussianState with weight = sum of all valid components.

◆ combinedState() [2/2]

template<unsigned int N>
MultiState MultiGaussianStateAssembler< N >::combinedState ( const float  weight)

Returns the resulting MultiGaussianState renormalised to specified weight.

◆ prepareCombinedState()

template<unsigned int N>
bool MultiGaussianStateAssembler< N >::prepareCombinedState ( )
private

Preparation of combined state (cleaning & sorting)

◆ removeSmallWeights()

template<unsigned int N>
void MultiGaussianStateAssembler< N >::removeSmallWeights ( )
private

Removes states with negligible weight (no renormalisation of total weight!).

◆ reweightedCombinedState()

template<unsigned int N>
MultiState MultiGaussianStateAssembler< N >::reweightedCombinedState ( const double  ) const
private

Returns the resulting MultiGaussianState with user-supplied total weight.

Member Data Documentation

◆ combinationDone

template<unsigned int N>
bool MultiGaussianStateAssembler< N >::combinationDone = false
private

Definition at line 67 of file MultiGaussianStateAssembler.h.

◆ minFractionalWeight

template<unsigned int N>
double MultiGaussianStateAssembler< N >::minFractionalWeight = 1.e-16
private

Definition at line 65 of file MultiGaussianStateAssembler.h.

◆ theStates

template<unsigned int N>
SingleStateContainer MultiGaussianStateAssembler< N >::theStates
private

Definition at line 70 of file MultiGaussianStateAssembler.h.

◆ theValidWeightSum

template<unsigned int N>
double MultiGaussianStateAssembler< N >::theValidWeightSum = 0
private

Definition at line 69 of file MultiGaussianStateAssembler.h.