#include <Combinatorics.h>
Public Member Functions | |
Combinatorics (Int_t Set, Int_t Subset) | |
Int_t | EqualPermutation (const std::vector< UInt_t > &permutation1, const std::vector< UInt_t > &permutation2) |
Int_t | EqualPermutation_2_0 (const std::vector< UInt_t > &permutation1, const std::vector< UInt_t > &permutation2) |
Int_t | EqualPermutation_2_2 (const std::vector< UInt_t > &permutation1, const std::vector< UInt_t > &permutation2) |
Int_t | EqualPermutation_N_1 (const std::vector< UInt_t > &permutation1, const std::vector< UInt_t > &permutation2) |
std::vector< std::vector < UInt_t > > | GetCombinations () |
std::vector< std::vector < UInt_t > > | GetCombinations_2_0 () |
std::vector< std::vector < UInt_t > > | GetCombinations_2_2 () |
std::vector< std::vector < UInt_t > > | GetCombinations_N_1 () |
std::vector< std::vector < UInt_t > > | GetPermutations () |
void | Print (const std::vector< UInt_t > &permutation) |
void | Print (const std::vector< std::vector< UInt_t > > &permutations) |
virtual | ~Combinatorics () |
Private Member Functions | |
Int_t | CalculatePermutations () |
void | initial_permutation (int size, int *permutation) |
void | initial_subset (int k, int *subset) |
Bool_t | next_permutation (int size, int *permutation) |
Bool_t | next_subset (int n, int k, int *subset) |
std::vector< UInt_t > | Rotate (const std::vector< UInt_t > &permutation, UInt_t digits) |
void | Skip_2_0 (const std::vector< std::vector< UInt_t > > &permutation1, std::vector< std::vector< UInt_t > > &permutation2) |
void | Skip_2_2 (const std::vector< std::vector< UInt_t > > &permutation1, std::vector< std::vector< UInt_t > > &permutation2) |
Private Attributes | |
std::vector< std::vector < UInt_t > > | m_Combinations |
std::vector< std::vector < UInt_t > > | m_Permutations |
const Int_t | m_SetQuantity |
std::vector< UInt_t > | m_Subset |
const Int_t | m_SubsetQuantity |
Definition at line 17 of file Combinatorics.h.
Combinatorics::Combinatorics | ( | Int_t | Set, |
Int_t | Subset | ||
) |
|
virtual |
Definition at line 32 of file Combinatorics.cc.
|
private |
Definition at line 47 of file Combinatorics.cc.
References i, initial_permutation(), initial_subset(), m_Permutations, m_SetQuantity, m_Subset, m_SubsetQuantity, next_permutation(), and next_subset().
Referenced by Combinatorics().
Int_t Combinatorics::EqualPermutation | ( | const std::vector< UInt_t > & | permutation1, |
const std::vector< UInt_t > & | permutation2 | ||
) |
Definition at line 214 of file Combinatorics.cc.
References i.
Referenced by EqualPermutation_N_1(), and GetCombinations().
Int_t Combinatorics::EqualPermutation_2_0 | ( | const std::vector< UInt_t > & | permutation1, |
const std::vector< UInt_t > & | permutation2 | ||
) |
Definition at line 351 of file Combinatorics.cc.
Referenced by Skip_2_0().
Int_t Combinatorics::EqualPermutation_2_2 | ( | const std::vector< UInt_t > & | permutation1, |
const std::vector< UInt_t > & | permutation2 | ||
) |
Definition at line 373 of file Combinatorics.cc.
Referenced by Skip_2_2().
Int_t Combinatorics::EqualPermutation_N_1 | ( | const std::vector< UInt_t > & | permutation1, |
const std::vector< UInt_t > & | permutation2 | ||
) |
Definition at line 398 of file Combinatorics.cc.
References EqualPermutation().
vector< vector< UInt_t > > Combinatorics::GetCombinations | ( | ) |
Definition at line 189 of file Combinatorics.cc.
References EqualPermutation(), i, LogDebug, m_Combinations, and m_Permutations.
Referenced by Tau3MuReco::findCorrectPairing(), and GetCombinations_N_1().
vector< vector< UInt_t > > Combinatorics::GetCombinations_2_0 | ( | ) |
Definition at line 270 of file Combinatorics.cc.
References LogDebug, m_Permutations, m_SubsetQuantity, and Skip_2_0().
vector< vector< UInt_t > > Combinatorics::GetCombinations_2_2 | ( | ) |
Definition at line 239 of file Combinatorics.cc.
References LogDebug, m_Permutations, m_SubsetQuantity, and Skip_2_2().
vector< vector< UInt_t > > Combinatorics::GetCombinations_N_1 | ( | ) |
Definition at line 416 of file Combinatorics.cc.
References GetCombinations(), i, j, LogDebug, m_Combinations, and Rotate().
vector< vector< UInt_t > > Combinatorics::GetPermutations | ( | ) |
Definition at line 39 of file Combinatorics.cc.
References m_Permutations.
|
private |
Definition at line 85 of file Combinatorics.cc.
References i, and findQualityFiles::size.
Referenced by CalculatePermutations().
|
private |
Definition at line 97 of file Combinatorics.cc.
References i, and roll_playback::k.
Referenced by CalculatePermutations().
|
private |
Definition at line 109 of file Combinatorics.cc.
References i, j, roll_playback::k, findQualityFiles::size, and tmp.
Referenced by CalculatePermutations().
|
private |
Definition at line 155 of file Combinatorics.cc.
References run_regression::done, i, and j.
Referenced by CalculatePermutations().
void Combinatorics::Print | ( | const std::vector< UInt_t > & | permutation | ) |
Definition at line 476 of file Combinatorics.cc.
void Combinatorics::Print | ( | const std::vector< std::vector< UInt_t > > & | permutations | ) |
Definition at line 490 of file Combinatorics.cc.
References asciidump::at, i, j, LogDebug, AlCaHLTBitMon_ParallelJobs::p, and findQualityFiles::size.
|
private |
Definition at line 448 of file Combinatorics.cc.
References i, j, roll_playback::k, AlCaHLTBitMon_ParallelJobs::p, and tmp.
Referenced by GetCombinations_N_1().
|
private |
Definition at line 298 of file Combinatorics.cc.
References EqualPermutation_2_0(), i, j, p1, and p2.
Referenced by GetCombinations_2_0().
|
private |
Definition at line 324 of file Combinatorics.cc.
References EqualPermutation_2_2(), i, j, p1, and p2.
Referenced by GetCombinations_2_2().
|
private |
Definition at line 64 of file Combinatorics.h.
Referenced by GetCombinations(), and GetCombinations_N_1().
|
private |
Definition at line 63 of file Combinatorics.h.
Referenced by CalculatePermutations(), GetCombinations(), GetCombinations_2_0(), GetCombinations_2_2(), and GetPermutations().
|
private |
Definition at line 59 of file Combinatorics.h.
Referenced by CalculatePermutations().
|
private |
Definition at line 62 of file Combinatorics.h.
Referenced by CalculatePermutations().
|
private |
Definition at line 60 of file Combinatorics.h.
Referenced by CalculatePermutations(), GetCombinations_2_0(), and GetCombinations_2_2().