Google OR-Tools v9.15
a fast and portable software suite for combinatorial optimization
Loading...
Searching...
No Matches
operations_research::sat::EncodingNode Class Reference

Detailed Description

Definition at line 61 of file encoding.h.

#include <encoding.h>

Public Member Functions

 EncodingNode ()=default
void InitializeFullNode (int n, EncodingNode *a, EncodingNode *b, SatSolver *solver)
void InitializeLazyNode (EncodingNode *a, EncodingNode *b, SatSolver *solver)
void InitializeLazyCoreNode (Coefficient weight, EncodingNode *a, EncodingNode *b)
void InitializeAmoNode (absl::Span< EncodingNode *const > nodes, SatSolver *solver)
Literal GreaterThan (int i) const
int size () const
Literal literal (int i) const
bool operator< (const EncodingNode &other) const
bool IncreaseCurrentUB (SatSolver *solver)
void TransformToBoolean (SatSolver *solver)
Coefficient Reduce (const SatSolver &solver)
bool AssumptionIs (Literal other) const
Literal GetAssumption (SatSolver *solver)
bool HasNoWeight () const
void IncreaseWeightLb ()
void ApplyWeightUpperBound (Coefficient gap, SatSolver *solver)
void set_weight (Coefficient w)
Coefficient weight () const
void set_depth (int depth)
int depth () const
int lb () const
int weight_lb () const
int current_ub () const
int ub () const
EncodingNodechild_a () const
EncodingNodechild_b () const
std::string DebugString (const VariablesAssignment &assignment) const

Static Public Member Functions

static EncodingNode ConstantNode (Coefficient weight)
static EncodingNode LiteralNode (Literal l, Coefficient weight)
static EncodingNode GenericNode (int lb, int ub, std::function< Literal(int x)> create_lit, Coefficient weight)

Constructor & Destructor Documentation

◆ EncodingNode()

operations_research::sat::EncodingNode::EncodingNode ( )
default

Member Function Documentation

◆ ApplyWeightUpperBound()

void operations_research::sat::EncodingNode::ApplyWeightUpperBound ( Coefficient gap,
SatSolver * solver )

Definition at line 197 of file encoding.cc.

◆ AssumptionIs()

bool operations_research::sat::EncodingNode::AssumptionIs ( Literal other) const

Definition at line 231 of file encoding.cc.

◆ child_a()

EncodingNode * operations_research::sat::EncodingNode::child_a ( ) const
inline

Definition at line 153 of file encoding.h.

◆ child_b()

EncodingNode * operations_research::sat::EncodingNode::child_b ( ) const
inline

Definition at line 154 of file encoding.h.

◆ ConstantNode()

EncodingNode operations_research::sat::EncodingNode::ConstantNode ( Coefficient weight)
static

Definition at line 43 of file encoding.cc.

◆ current_ub()

int operations_research::sat::EncodingNode::current_ub ( ) const
inline

Definition at line 151 of file encoding.h.

◆ DebugString()

std::string operations_research::sat::EncodingNode::DebugString ( const VariablesAssignment & assignment) const

Definition at line 256 of file encoding.cc.

◆ depth()

int operations_research::sat::EncodingNode::depth ( ) const
inline

Definition at line 147 of file encoding.h.

◆ GenericNode()

EncodingNode operations_research::sat::EncodingNode::GenericNode ( int lb,
int ub,
std::function< Literal(int x)> create_lit,
Coefficient weight )
static

Definition at line 63 of file encoding.cc.

◆ GetAssumption()

Literal operations_research::sat::EncodingNode::GetAssumption ( SatSolver * solver)

Definition at line 237 of file encoding.cc.

◆ GreaterThan()

Literal operations_research::sat::EncodingNode::GreaterThan ( int i) const
inline

Definition at line 97 of file encoding.h.

◆ HasNoWeight()

bool operations_research::sat::EncodingNode::HasNoWeight ( ) const

Definition at line 252 of file encoding.cc.

◆ IncreaseCurrentUB()

bool operations_research::sat::EncodingNode::IncreaseCurrentUB ( SatSolver * solver)

Definition at line 159 of file encoding.cc.

◆ IncreaseWeightLb()

void operations_research::sat::EncodingNode::IncreaseWeightLb ( )

Definition at line 247 of file encoding.cc.

◆ InitializeAmoNode()

void operations_research::sat::EncodingNode::InitializeAmoNode ( absl::Span< EncodingNode *const > nodes,
SatSolver * solver )

Definition at line 101 of file encoding.cc.

◆ InitializeFullNode()

void operations_research::sat::EncodingNode::InitializeFullNode ( int n,
EncodingNode * a,
EncodingNode * b,
SatSolver * solver )

Definition at line 81 of file encoding.cc.

◆ InitializeLazyCoreNode()

void operations_research::sat::EncodingNode::InitializeLazyCoreNode ( Coefficient weight,
EncodingNode * a,
EncodingNode * b )

Definition at line 144 of file encoding.cc.

◆ InitializeLazyNode()

void operations_research::sat::EncodingNode::InitializeLazyNode ( EncodingNode * a,
EncodingNode * b,
SatSolver * solver )

Definition at line 128 of file encoding.cc.

◆ lb()

int operations_research::sat::EncodingNode::lb ( ) const
inline

Definition at line 149 of file encoding.h.

◆ literal()

Literal operations_research::sat::EncodingNode::literal ( int i) const
inline

Definition at line 101 of file encoding.h.

◆ LiteralNode()

EncodingNode operations_research::sat::EncodingNode::LiteralNode ( Literal l,
Coefficient weight )
static

Definition at line 52 of file encoding.cc.

◆ operator<()

bool operations_research::sat::EncodingNode::operator< ( const EncodingNode & other) const
inline

Definition at line 109 of file encoding.h.

◆ Reduce()

Coefficient operations_research::sat::EncodingNode::Reduce ( const SatSolver & solver)

Definition at line 175 of file encoding.cc.

◆ set_depth()

void operations_research::sat::EncodingNode::set_depth ( int depth)
inline

Definition at line 146 of file encoding.h.

◆ set_weight()

void operations_research::sat::EncodingNode::set_weight ( Coefficient w)
inline

Definition at line 138 of file encoding.h.

◆ size()

int operations_research::sat::EncodingNode::size ( ) const
inline

Definition at line 100 of file encoding.h.

◆ TransformToBoolean()

void operations_research::sat::EncodingNode::TransformToBoolean ( SatSolver * solver)

Definition at line 211 of file encoding.cc.

◆ ub()

int operations_research::sat::EncodingNode::ub ( ) const
inline

Definition at line 152 of file encoding.h.

◆ weight()

Coefficient operations_research::sat::EncodingNode::weight ( ) const
inline

Definition at line 142 of file encoding.h.

◆ weight_lb()

int operations_research::sat::EncodingNode::weight_lb ( ) const
inline

Definition at line 150 of file encoding.h.


The documentation for this class was generated from the following files: