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

Detailed Description

Definition at line 345 of file model.h.

#include <model.h>

Public Member Functions

 Model (absl::string_view name)
 ~Model ()
VariableAddVariable (absl::string_view name, const Domain &domain, bool defined, bool set_is_fixed=false)
VariableAddConstant (int64_t value)
VariableAddFloatConstant (double value)
void AddConstraint (absl::string_view id, std::vector< Argument > arguments, bool is_domain, bool symmetry, bool redundant)
void AddConstraint (absl::string_view id, std::vector< Argument > arguments)
void AddOutput (SolutionOutputSpecs output)
void Satisfy (std::vector< Annotation > search_annotations)
void Minimize (Variable *obj, std::vector< Annotation > search_annotations)
void Maximize (Variable *obj, std::vector< Annotation > search_annotations)
bool IsInconsistent () const
const std::vector< Variable * > & variables () const
const std::vector< Constraint * > & constraints () const
const std::vector< Annotation > & search_annotations () const
const std::vector< SolutionOutputSpecs > & output () const
bool maximize () const
Variableobjective () const
const std::vector< Variable * > & float_objective_variables () const
const std::vector< double > & float_objective_coefficients () const
double float_objective_offset () const
void SetObjective (Variable *obj)
void ClearObjective ()
void AddFloatingPointObjectiveTerm (Variable *var, double coeff)
void SetFloatingPointObjectiveOffset (double offset)
std::string DebugString () const
const std::string & name () const

Constructor & Destructor Documentation

◆ Model()

operations_research::fz::Model::Model ( absl::string_view name)
inlineexplicit

Definition at line 347 of file model.h.

◆ ~Model()

Definition at line 1015 of file model.cc.

Member Function Documentation

◆ AddConstant()

Definition at line 1032 of file model.cc.

◆ AddConstraint() [1/2]

void operations_research::fz::Model::AddConstraint ( absl::string_view id,
std::vector< Argument > arguments )

Definition at line 1053 of file model.cc.

◆ AddConstraint() [2/2]

void operations_research::fz::Model::AddConstraint ( absl::string_view id,
std::vector< Argument > arguments,
bool is_domain,
bool symmetry,
bool redundant )

Definition at line 1046 of file model.cc.

◆ AddFloatConstant()

Definition at line 1039 of file model.cc.

◆ AddFloatingPointObjectiveTerm()

Definition at line 393 of file model.h.

◆ AddOutput()

Definition at line 1058 of file model.cc.

◆ AddVariable()

Variable * operations_research::fz::Model::AddVariable ( absl::string_view name,
const Domain & domain,
bool defined,
bool set_is_fixed = false )

Definition at line 1020 of file model.cc.

◆ ClearObjective()

Definition at line 392 of file model.h.

◆ constraints()

const std::vector< Constraint * > & operations_research::fz::Model::constraints ( ) const
inline

Definition at line 377 of file model.h.

◆ DebugString()

Definition at line 1081 of file model.cc.

◆ float_objective_coefficients()

const std::vector< double > & operations_research::fz::Model::float_objective_coefficients ( ) const
inline

Definition at line 387 of file model.h.

◆ float_objective_offset()

Definition at line 390 of file model.h.

◆ float_objective_variables()

const std::vector< Variable * > & operations_research::fz::Model::float_objective_variables ( ) const
inline

Definition at line 384 of file model.h.

◆ IsInconsistent()

Definition at line 1116 of file model.cc.

◆ Maximize()

void operations_research::fz::Model::Maximize ( Variable * obj,
std::vector< Annotation > search_annotations )

Definition at line 1074 of file model.cc.

◆ maximize()

Definition at line 382 of file model.h.

◆ Minimize()

void operations_research::fz::Model::Minimize ( Variable * obj,
std::vector< Annotation > search_annotations )

Definition at line 1067 of file model.cc.

◆ name()

const std::string & operations_research::fz::Model::name ( ) const
inline

Definition at line 404 of file model.h.

◆ objective()

Definition at line 383 of file model.h.

◆ output()

const std::vector< SolutionOutputSpecs > & operations_research::fz::Model::output ( ) const
inline

Definition at line 381 of file model.h.

◆ Satisfy()

void operations_research::fz::Model::Satisfy ( std::vector< Annotation > search_annotations)

Definition at line 1062 of file model.cc.

◆ search_annotations()

const std::vector< Annotation > & operations_research::fz::Model::search_annotations ( ) const
inline

Definition at line 378 of file model.h.

◆ SetFloatingPointObjectiveOffset()

Definition at line 397 of file model.h.

◆ SetObjective()

Definition at line 391 of file model.h.

◆ variables()

const std::vector< Variable * > & operations_research::fz::Model::variables ( ) const
inline

Definition at line 376 of file model.h.


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