split "cosets" and "solver" data. "solver.cpp" now only for solution logic.

This commit is contained in:
2019-12-27 17:06:25 -05:00
parent c489d530a9
commit 96b27cd642
5 changed files with 78 additions and 74 deletions

33
include/cosets.h Normal file
View File

@@ -0,0 +1,33 @@
#pragma once
#include "groups.h"
#include <vector>
struct Cosets {
int ngens;
std::vector<int> data;
int len;
Cosets(int ngens, const std::vector<int> &data);
void add_row();
void put(int coset, int gen, int target);
void put(int idx, int target);
[[nodiscard]] int get(int coset, int gen) const;
[[nodiscard]] int get(int idx) const;
};
struct RelTable {
int gens[2]{};
int mult;
std::vector<int *> lst_ptr;
std::vector<int> gen;
explicit RelTable(tc::Mult m);
int add_row();
};