11 template<
int D>
using point_t = std::array<int, D>;
22 for(
int i=0; i<D; i++) {
34 for(
int i=0; i<D; i++) {
63 partitions.push_back(P);
65 while(sum<D>(P) <= K) {
68 for(
int i=1; i < D; i++) {
70 if(P[0] <= P[i] + 1) {
73 P[0] = p0 - i * (P[i] + 1);
74 for(
int j=1; j <= i; j++) {
77 partitions.push_back(P);
85 partitions.push_back(P);
104 for(
int n=0; n <= N; n++) {
111 for(
int i = c-1; i > 0; i--) {
121 for(
int t=0; t < c-1; t++) {
125 for(
int t=c; t < D; t++) {
146 permutations.push_back(P);
151 for(
int i=1; i < D; i++) {
158 for(
int j=0; j < u; j++) {
175 permutations.push_back(P);
std::list< point_t< D >> latticepoints_t
Definition: combinatorics.hpp:12
Definition: coefficients_file_parser.cpp:10
constexpr T pi()
Definition: pi.hpp:6
std::array< int, D > point_t
Definition: combinatorics.hpp:11
var c
Definition: jquery.js:23
partitions_t< D > partitions(const int K)
Definition: combinatorics.hpp:58
int nnz(const point_t< D > Z)
Definition: combinatorics.hpp:46
std::list< partition_t< D >> partitions_t
Definition: combinatorics.hpp:10
int nz(const point_t< D > Z)
Definition: combinatorics.hpp:32
latticepoints_t< D > lattice_points(const int N)
Definition: combinatorics.hpp:100
permutations_t< D > permutations(const permutation_t< D > permutation)
Definition: combinatorics.hpp:142
function L
Definition: jquery.js:16
std::array< int, D > permutation_t
Definition: combinatorics.hpp:13
std::list< permutation_t< D >> permutations_t
Definition: combinatorics.hpp:14
std::array< int, D > partition_t
Definition: combinatorics.hpp:9
int sum(const point_t< D > Z)
Sum of the components of the point Z.
Definition: combinatorics.hpp:20
var k
Definition: jquery.js:23
Z
Definition: jquery.js:23