Frobby 0.10.0
Loading...
Searching...
No Matches
IndependenceSplitter.h
1/* Frobby: Software for monomial ideal computations.
2 Copyright (C) 2007 Bjarke Hammersholt Roune (www.broune.com)
3
4 This program is free software; you can redistribute it and/or modify
5 it under the terms of the GNU General Public License as published by
6 the Free Software Foundation; either version 2 of the License, or
7 (at your option) any later version.
8
9 This program is distributed in the hope that it will be useful,
10 but WITHOUT ANY WARRANTY; without even the implied warranty of
11 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 GNU General Public License for more details.
13
14 You should have received a copy of the GNU General Public License
15 along with this program. If not, see http://www.gnu.org/licenses/.
16*/
17#ifndef INDEPENDENCE_SPLITTER_GUARD
18#define INDEPENDENCE_SPLITTER_GUARD
19
20#include "Partition.h"
21#include "Projection.h"
22#include "Ideal.h"
23#include <vector>
24#include "MsmSlice.h"
25
26class Ideal;
27class Term;
28
30 public:
31 // Returns true if there are independent subsets of variables. The
32 // other methods should only be called when the most recent call to
33 // analyze returned true.
34 bool analyze(const Slice& slice);
35
36 size_t getVarCount() const;
37
38 size_t getOneVarCount() const {return _oneVarCount;}
39 size_t getTwoVarCount() const {return _twoVarCount;}
40 size_t getMoreThanTwoCount() const {return _moreThanTwoVarCount;}
41
42 // Get the projection to the biggest independent subset of variables.
43 void getBigProjection(Projection& projection) const;
44
45 // Get the projection to the rest of the variables.
46 void getRestProjection(Projection& projection) const;
47
48 private:
49 Partition _partition;
50
51 size_t _oneVarCount;
52 size_t _twoVarCount;
53 size_t _moreThanTwoVarCount;
54
55 size_t _bigSet;
56};
57
58#endif
Represents a monomial ideal with int exponents.
Definition Ideal.h:27
Definition IndependenceSplitter.h:29
Definition Partition.h:20
Definition Projection.h:29
Definition Slice.h:77
Definition Term.h:49