SUNphi
1.0
|
Factorizes numbers into partitions. More...
Go to the source code of this file.
Functions | |
template<typename I , typename Fun > | |
I | SUNphi::Impl::loopOnAllFactorizingPartitioning (Vector< I > &partition, const I &n, const Fun &fun, const int &pos=0) |
template<typename I , typename Fun > | |
I | SUNphi::loopOnAllFactorizingPartitioning (const I &n, const Fun &fun, const int &nFacts) |
template<typename I > | |
Vector< Vector< I > > | SUNphi::listAllFactorizingPartitioning (const I &n, const int &nFacts) |
Gets the list of all factorizing partition of n. More... | |
Factorizes numbers into partitions.
Definition in file Partition.hpp.
Vector<Vector<I> > SUNphi::listAllFactorizingPartitioning | ( | const I & | n, |
const int & | nFacts | ||
) |
Gets the list of all factorizing partition of n.
n | Number to factorize |
nFacts | Size of the partition |
Definition at line 75 of file Partition.hpp.
I SUNphi::Impl::loopOnAllFactorizingPartitioning | ( | Vector< I > & | partition, |
const I & | n, | ||
const Fun & | fun, | ||
const int & | pos = 0 |
||
) |
Loop on all factorizing partition of n
Internal implementation, proceeds recursively calling the function until the position is the end
Number of partition found
partition | Progressively built partition |
n | Numbr to factorize |
fun | Function to be called |
pos | Position filled at this iteration |
Definition at line 23 of file Partition.hpp.
I SUNphi::loopOnAllFactorizingPartitioning | ( | const I & | n, |
const Fun & | fun, | ||
const int & | nFacts | ||
) |
Loop on all factorizing partition of n
Returns the number of partitions obtained
Built partition
n | Number to factorize |
fun | Function to be invocated at each turn |
nFacts | Size of the partition |
Definition at line 62 of file Partition.hpp.