SMT-RAT  24.02
Toolbox for Strategic and Parallel Satisfiability-Modulo-Theories Solving
CNFerModuleStatistics.h
Go to the documentation of this file.
1 /**
2  * @file CNFerModuleStatistics.h
3  * @author: Florian Corzilius
4  *
5  *
6  */
7 
8 #pragma once
9 
11 #ifdef SMTRAT_DEVOPTION_Statistics
13 
14 namespace smtrat
15 {
16  class CNFerModuleStatistics : public Statistics
17  {
18  private:
19  // Members.
20  size_t mBooleanComplexity = 1;
21  size_t mNrOfArithVariables = 0;
22  size_t mNrOfBoolVariables = 0;
23 
24  public:
25 
26  void collect()
27  {
28  Statistics::addKeyValuePair( "boolean_complexity", mBooleanComplexity );
29  Statistics::addKeyValuePair( "nr_of_arith_variables", mNrOfArithVariables );
30  Statistics::addKeyValuePair( "nr_of_bool_variables", mNrOfBoolVariables );
31  }
32 
33  void addClauseOfSize(size_t _clauseSize)
34  {
35  unsigned targetlevel = 0;
36  while (_clauseSize >>= 1) ++targetlevel;
37  mBooleanComplexity += targetlevel;
38  }
39 
40  size_t& nrOfArithVariables()
41  {
42  return mNrOfArithVariables;
43  }
44 
45  size_t& nrOfBoolVariables()
46  {
47  return mNrOfBoolVariables;
48  }
49 
50  };
51 
52 }
53 #endif
Class to create the formulas for axioms.
carl::statistics::Statistics Statistics
Definition: Statistics.h:7