Google OR-Tools v9.14
a fast and portable software suite for combinatorial optimization
Loading...
Searching...
No Matches
operations_research::mb::AffineExpr Class Reference

A class to hold linear_expr * a = b. More...

Detailed Description

A class to hold linear_expr * a = b.

Definition at line 186 of file model_builder_helper.h.

#include <model_builder_helper.h>

Inheritance diagram for operations_research::mb::AffineExpr:
operations_research::mb::LinearExpr

Public Member Functions

 AffineExpr (std::shared_ptr< LinearExpr > expr, double coeff, double offset)
 ~AffineExpr () override=default
void Visit (ExprVisitor &lin, double c) override
std::string ToString () const override
std::string DebugString () const override
std::shared_ptr< LinearExprexpression () const
double coefficient () const
double offset () const
std::shared_ptr< LinearExprAddFloat (double cst) override
std::shared_ptr< LinearExprSubFloat (double cst) override
std::shared_ptr< LinearExprRSubFloat (double cst) override
std::shared_ptr< LinearExprMulFloat (double cst) override
std::shared_ptr< LinearExprNeg () override
Public Member Functions inherited from operations_research::mb::LinearExpr
virtual ~LinearExpr ()=default
std::shared_ptr< LinearExprAdd (std::shared_ptr< LinearExpr > expr)
std::shared_ptr< LinearExprSub (std::shared_ptr< LinearExpr > expr)
std::shared_ptr< BoundedLinearExpressionEq (std::shared_ptr< LinearExpr > rhs)
std::shared_ptr< BoundedLinearExpressionEqCst (double rhs)
std::shared_ptr< BoundedLinearExpressionGe (std::shared_ptr< LinearExpr > rhs)
std::shared_ptr< BoundedLinearExpressionGeCst (double rhs)
std::shared_ptr< BoundedLinearExpressionLe (std::shared_ptr< LinearExpr > rhs)
std::shared_ptr< BoundedLinearExpressionLeCst (double rhs)

Additional Inherited Members

Static Public Member Functions inherited from operations_research::mb::LinearExpr
static std::shared_ptr< LinearExprTerm (std::shared_ptr< LinearExpr > expr, double coeff)
 Expressions.
static std::shared_ptr< LinearExprAffine (std::shared_ptr< LinearExpr > expr, double coeff, double constant)
static std::shared_ptr< LinearExprAffineCst (double value, double coeff, double constant)
static std::shared_ptr< LinearExprConstant (double value)

Constructor & Destructor Documentation

◆ AffineExpr()

operations_research::mb::AffineExpr::AffineExpr ( std::shared_ptr< LinearExpr > expr,
double coeff,
double offset )

Definition at line 1137 of file model_builder_helper.cc.

◆ ~AffineExpr()

operations_research::mb::AffineExpr::~AffineExpr ( )
overridedefault

Member Function Documentation

◆ AddFloat()

std::shared_ptr< LinearExpr > operations_research::mb::AffineExpr::AddFloat ( double cst)
overridevirtual

Reimplemented from operations_research::mb::LinearExpr.

Definition at line 1146 of file model_builder_helper.cc.

◆ coefficient()

double operations_research::mb::AffineExpr::coefficient ( ) const
inline

Definition at line 197 of file model_builder_helper.h.

◆ DebugString()

std::string operations_research::mb::AffineExpr::DebugString ( ) const
overridevirtual

Implements operations_research::mb::LinearExpr.

Definition at line 1188 of file model_builder_helper.cc.

◆ expression()

std::shared_ptr< LinearExpr > operations_research::mb::AffineExpr::expression ( ) const
inline

Definition at line 196 of file model_builder_helper.h.

◆ MulFloat()

std::shared_ptr< LinearExpr > operations_research::mb::AffineExpr::MulFloat ( double cst)
overridevirtual

Reimplemented from operations_research::mb::LinearExpr.

Definition at line 1160 of file model_builder_helper.cc.

◆ Neg()

std::shared_ptr< LinearExpr > operations_research::mb::AffineExpr::Neg ( )
overridevirtual

Reimplemented from operations_research::mb::LinearExpr.

Definition at line 1166 of file model_builder_helper.cc.

◆ offset()

double operations_research::mb::AffineExpr::offset ( ) const
inline

Definition at line 198 of file model_builder_helper.h.

◆ RSubFloat()

std::shared_ptr< LinearExpr > operations_research::mb::AffineExpr::RSubFloat ( double cst)
overridevirtual

Reimplemented from operations_research::mb::LinearExpr.

Definition at line 1156 of file model_builder_helper.cc.

◆ SubFloat()

std::shared_ptr< LinearExpr > operations_research::mb::AffineExpr::SubFloat ( double cst)
overridevirtual

Reimplemented from operations_research::mb::LinearExpr.

Definition at line 1151 of file model_builder_helper.cc.

◆ ToString()

std::string operations_research::mb::AffineExpr::ToString ( ) const
overridevirtual

Implements operations_research::mb::LinearExpr.

Definition at line 1170 of file model_builder_helper.cc.

◆ Visit()

void operations_research::mb::AffineExpr::Visit ( ExprVisitor & lin,
double c )
overridevirtual

Implements operations_research::mb::LinearExpr.

Definition at line 1141 of file model_builder_helper.cc.


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