Google OR-Tools v9.11
a fast and portable software suite for combinatorial optimization
|
#include "ortools/sat/util.h"
#include <algorithm>
#include <cmath>
#include <cstdint>
#include <deque>
#include <functional>
#include <limits>
#include <numeric>
#include <string>
#include <utility>
#include <vector>
#include "absl/algorithm/container.h"
#include "absl/container/btree_set.h"
#include "absl/container/flat_hash_map.h"
#include "absl/container/inlined_vector.h"
#include "absl/log/check.h"
#include "absl/numeric/int128.h"
#include "absl/random/bit_gen_ref.h"
#include "absl/random/distributions.h"
#include "absl/strings/str_cat.h"
#include "absl/types/span.h"
#include "google/protobuf/descriptor.h"
#include "ortools/base/logging.h"
#include "ortools/base/mathutil.h"
#include "ortools/base/stl_util.h"
#include "ortools/sat/sat_base.h"
#include "ortools/sat/sat_parameters.pb.h"
#include "ortools/util/saturated_arithmetic.h"
#include "ortools/util/sorted_interval_list.h"
Go to the source code of this file.
Namespaces | |
namespace | operations_research |
In SWIG mode, we don't want anything besides these top-level includes. | |
namespace | operations_research::sat |
Functions | |
std::string | operations_research::sat::FormatCounter (int64_t num) |
Prints a positive number with separators for easier reading (ex: 1'348'065). | |
std::string | operations_research::sat::FormatTable (std::vector< std::vector< std::string > > &table, int spacing) |
void | operations_research::sat::RandomizeDecisionHeuristic (absl::BitGenRef random, SatParameters *parameters) |
Randomizes the decision heuristic of the given SatParameters. | |
int64_t | operations_research::sat::ModularInverse (int64_t x, int64_t m) |
int64_t | operations_research::sat::PositiveMod (int64_t x, int64_t m) |
Just returns x % m but with a result always in [0, m). | |
int64_t | operations_research::sat::ProductWithModularInverse (int64_t coeff, int64_t mod, int64_t rhs) |
bool | operations_research::sat::SolveDiophantineEquationOfSizeTwo (int64_t &a, int64_t &b, int64_t &cte, int64_t &x0, int64_t &y0) |
int64_t | operations_research::sat::FloorSquareRoot (int64_t a) |
The argument must be non-negative. | |
int64_t | operations_research::sat::CeilSquareRoot (int64_t a) |
int64_t | operations_research::sat::ClosestMultiple (int64_t value, int64_t base) |
bool | operations_research::sat::LinearInequalityCanBeReducedWithClosestMultiple (int64_t base, absl::Span< const int64_t > coeffs, absl::Span< const int64_t > lbs, absl::Span< const int64_t > ubs, int64_t rhs, int64_t *new_rhs) |
int | operations_research::sat::MoveOneUnprocessedLiteralLast (const absl::btree_set< LiteralIndex > &processed, int relevant_prefix_size, std::vector< Literal > *literals) |
int | operations_research::sat::WeightedPick (absl::Span< const double > input, absl::BitGenRef random) |
void | operations_research::sat::CompressTuples (absl::Span< const int64_t > domain_sizes, std::vector< std::vector< int64_t > > *tuples) |
std::vector< std::vector< absl::InlinedVector< int64_t, 2 > > > | operations_research::sat::FullyCompressTuples (absl::Span< const int64_t > domain_sizes, std::vector< std::vector< int64_t > > *tuples) |
std::vector< absl::Span< int > > | operations_research::sat::AtMostOneDecomposition (const std::vector< std::vector< int > > &graph, absl::BitGenRef random, std::vector< int > *buffer) |