Google OR-Tools v9.11
a fast and portable software suite for combinatorial optimization
Loading...
Searching...
No Matches
cp_model.py File Reference

Go to the source code of this file.

Classes

class  ortools.sat.python.cp_model.LinearExpr
 
class  ortools.sat.python.cp_model._Sum
 
class  ortools.sat.python.cp_model._ProductCst
 
class  ortools.sat.python.cp_model._SumArray
 
class  ortools.sat.python.cp_model._WeightedSum
 
class  ortools.sat.python.cp_model.IntVar
 
class  ortools.sat.python.cp_model._NotBooleanVariable
 
class  ortools.sat.python.cp_model.BoundedLinearExpression
 
class  ortools.sat.python.cp_model.Constraint
 
class  ortools.sat.python.cp_model.IntervalVar
 
class  ortools.sat.python.cp_model.CpModel
 
class  ortools.sat.python.cp_model.CpSolver
 
class  ortools.sat.python.cp_model.CpSolverSolutionCallback
 
class  ortools.sat.python.cp_model.ObjectiveSolutionPrinter
 
class  ortools.sat.python.cp_model.VarArrayAndObjectiveSolutionPrinter
 
class  ortools.sat.python.cp_model.VarArraySolutionPrinter
 

Namespaces

namespace  ortools
 
namespace  ortools.sat
 
namespace  ortools.sat.python
 
namespace  ortools.sat.python.cp_model
 

Functions

str ortools.sat.python.cp_model.display_bounds (Sequence[int] bounds)
 
str ortools.sat.python.cp_model.short_name (cp_model_pb2.CpModelProto model, int i)
 
str ortools.sat.python.cp_model.short_expr_name (cp_model_pb2.CpModelProto model, cp_model_pb2.LinearExpressionProto e)
 
bool ortools.sat.python.cp_model.object_is_a_true_literal (LiteralT literal)
 
bool ortools.sat.python.cp_model.object_is_a_false_literal (LiteralT literal)
 
Union[Iterable[LiteralT], LiteralTortools.sat.python.cp_model.expand_generator_or_tuple (Union[Tuple[LiteralT,...], Iterable[LiteralT]] args)
 
Union[Iterable[LinearExprT], LinearExprTortools.sat.python.cp_model.expand_generator_or_tuple (Union[Tuple[LinearExprT,...], Iterable[LinearExprT]] args)
 
 ortools.sat.python.cp_model.expand_generator_or_tuple (args)
 
int ortools.sat.python.cp_model.evaluate_linear_expr (LinearExprT expression, cp_model_pb2.CpSolverResponse solution)
 
bool ortools.sat.python.cp_model.evaluate_boolean_expression (LiteralT literal, cp_model_pb2.CpSolverResponse solution)
 
pd.Index ortools.sat.python.cp_model._get_index (_IndexOrSeries obj)
 
pd.Series ortools.sat.python.cp_model._attribute_series (*, Callable[[IntVar], IntegralT] func, _IndexOrSeries values)
 
pd.Series ortools.sat.python.cp_model._convert_to_integral_series_and_validate_index (Union[IntegralT, pd.Series] value_or_series, pd.Index index)
 
pd.Series ortools.sat.python.cp_model._convert_to_linear_expr_series_and_validate_index (Union[LinearExprT, pd.Series] value_or_series, pd.Index index)
 
pd.Series ortools.sat.python.cp_model._convert_to_literal_series_and_validate_index (Union[LiteralT, pd.Series] value_or_series, pd.Index index)
 

Variables

 ortools.sat.python.cp_model.Domain = sorted_interval_list.Domain
 
 ortools.sat.python.cp_model.INT_MIN = -(2**63)
 
int ortools.sat.python.cp_model.INT_MAX = 2**63 - 1
 
 ortools.sat.python.cp_model.INT32_MIN = -(2**31)
 
int ortools.sat.python.cp_model.INT32_MAX = 2**31 - 1
 
 ortools.sat.python.cp_model.UNKNOWN = cp_model_pb2.UNKNOWN
 
 ortools.sat.python.cp_model.MODEL_INVALID = cp_model_pb2.MODEL_INVALID
 
 ortools.sat.python.cp_model.FEASIBLE = cp_model_pb2.FEASIBLE
 
 ortools.sat.python.cp_model.INFEASIBLE = cp_model_pb2.INFEASIBLE
 
 ortools.sat.python.cp_model.OPTIMAL = cp_model_pb2.OPTIMAL
 
 ortools.sat.python.cp_model.CHOOSE_FIRST = cp_model_pb2.DecisionStrategyProto.CHOOSE_FIRST
 
 ortools.sat.python.cp_model.CHOOSE_LOWEST_MIN = cp_model_pb2.DecisionStrategyProto.CHOOSE_LOWEST_MIN
 
 ortools.sat.python.cp_model.CHOOSE_HIGHEST_MAX = cp_model_pb2.DecisionStrategyProto.CHOOSE_HIGHEST_MAX
 
 ortools.sat.python.cp_model.CHOOSE_MIN_DOMAIN_SIZE = cp_model_pb2.DecisionStrategyProto.CHOOSE_MIN_DOMAIN_SIZE
 
 ortools.sat.python.cp_model.CHOOSE_MAX_DOMAIN_SIZE = cp_model_pb2.DecisionStrategyProto.CHOOSE_MAX_DOMAIN_SIZE
 
 ortools.sat.python.cp_model.SELECT_MIN_VALUE = cp_model_pb2.DecisionStrategyProto.SELECT_MIN_VALUE
 
 ortools.sat.python.cp_model.SELECT_MAX_VALUE = cp_model_pb2.DecisionStrategyProto.SELECT_MAX_VALUE
 
 ortools.sat.python.cp_model.SELECT_LOWER_HALF = cp_model_pb2.DecisionStrategyProto.SELECT_LOWER_HALF
 
 ortools.sat.python.cp_model.SELECT_UPPER_HALF = cp_model_pb2.DecisionStrategyProto.SELECT_UPPER_HALF
 
 ortools.sat.python.cp_model.AUTOMATIC_SEARCH = sat_parameters_pb2.SatParameters.AUTOMATIC_SEARCH
 
 ortools.sat.python.cp_model.FIXED_SEARCH = sat_parameters_pb2.SatParameters.FIXED_SEARCH
 
 ortools.sat.python.cp_model.PORTFOLIO_SEARCH = sat_parameters_pb2.SatParameters.PORTFOLIO_SEARCH
 
 ortools.sat.python.cp_model.LP_SEARCH = sat_parameters_pb2.SatParameters.LP_SEARCH
 
 ortools.sat.python.cp_model.PSEUDO_COST_SEARCH = sat_parameters_pb2.SatParameters.PSEUDO_COST_SEARCH
 
tuple ortools.sat.python.cp_model.PORTFOLIO_WITH_QUICK_RESTART_SEARCH
 
 ortools.sat.python.cp_model.HINT_SEARCH = sat_parameters_pb2.SatParameters.HINT_SEARCH
 
 ortools.sat.python.cp_model.PARTIAL_FIXED_SEARCH = sat_parameters_pb2.SatParameters.PARTIAL_FIXED_SEARCH
 
 ortools.sat.python.cp_model.RANDOMIZED_SEARCH = sat_parameters_pb2.SatParameters.RANDOMIZED_SEARCH
 
 ortools.sat.python.cp_model.IntegralT = Union[int, np.int8, np.uint8, np.int32, np.uint32, np.int64, np.uint64]
 
tuple ortools.sat.python.cp_model.IntegralTypes
 
 ortools.sat.python.cp_model.NumberT
 
tuple ortools.sat.python.cp_model.NumberTypes
 
 ortools.sat.python.cp_model.LiteralT = Union["IntVar", "_NotBooleanVariable", IntegralT, bool]
 
 ortools.sat.python.cp_model.BoolVarT = Union["IntVar", "_NotBooleanVariable"]
 
 ortools.sat.python.cp_model.VariableT = Union["IntVar", IntegralT]
 
 ortools.sat.python.cp_model.LinearExprT = Union["LinearExpr", "IntVar", IntegralT]
 
 ortools.sat.python.cp_model.ObjLinearExprT = Union["LinearExpr", NumberT]
 
 ortools.sat.python.cp_model.BoundedLinearExprT = Union["BoundedLinearExpression", bool]
 
 ortools.sat.python.cp_model.ArcT = Tuple[IntegralT, IntegralT, LiteralT]
 
 ortools.sat.python.cp_model._IndexOrSeries = Union[pd.Index, pd.Series]