Google OR-Tools v9.9
a fast and portable software suite for combinatorial optimization
Loading...
Searching...
No Matches
com.google.ortools.sat.AffineExpression Class Reference
Inheritance diagram for com.google.ortools.sat.AffineExpression:
com.google.ortools.sat.LinearExpr com.google.ortools.sat.LinearExpr com.google.ortools.sat.LinearArgument com.google.ortools.sat.LinearArgument com.google.ortools.sat.LinearArgument com.google.ortools.sat.LinearArgument

Public Member Functions

 AffineExpression (int varIndex, long coefficient, long offset)
 
LinearExpr build ()
 LinearArgument interface.
 
int numElements ()
 LinearExpr interface.
 
int getVariableIndex (int index)
 
long getCoefficient (int index)
 
long getOffset ()
 
 AffineExpression (int varIndex, long coefficient, long offset)
 
LinearExpr build ()
 LinearArgument interface.
 
int numElements ()
 LinearExpr interface.
 
int getVariableIndex (int index)
 
long getCoefficient (int index)
 
long getOffset ()
 

Additional Inherited Members

- Static Public Member Functions inherited from com.google.ortools.sat.LinearExpr
static LinearExprBuilder newBuilder ()
 
static LinearExpr constant (long value)
 
static LinearExpr term (LinearArgument expr, long coeff)
 
static LinearExpr affine (LinearArgument expr, long coeff, long offset)
 
static LinearExpr sum (LinearArgument[] exprs)
 
static LinearExpr weightedSum (LinearArgument[] exprs, long[] coeffs)
 
static LinearExpr rebuildFromLinearExpressionProto (LinearExpressionProto proto)
 
static LinearExprBuilder newBuilder ()
 
static LinearExpr constant (long value)
 
static LinearExpr term (LinearArgument expr, long coeff)
 
static LinearExpr affine (LinearArgument expr, long coeff, long offset)
 
static LinearExpr sum (LinearArgument[] exprs)
 
static LinearExpr weightedSum (LinearArgument[] exprs, long[] coeffs)
 
static LinearExpr rebuildFromLinearExpressionProto (LinearExpressionProto proto)
 

Detailed Description

A specialized linear expression: a * x + b

Definition at line 17 of file AffineExpression.java.

Constructor & Destructor Documentation

◆ AffineExpression() [1/2]

com.google.ortools.sat.AffineExpression.AffineExpression ( int varIndex,
long coefficient,
long offset )

Definition at line 22 of file AffineExpression.java.

◆ AffineExpression() [2/2]

com.google.ortools.sat.AffineExpression.AffineExpression ( int varIndex,
long coefficient,
long offset )

Definition at line 22 of file AffineExpression.java.

Member Function Documentation

◆ build() [1/2]

LinearExpr com.google.ortools.sat.AffineExpression.build ( )

LinearArgument interface.

Implements com.google.ortools.sat.LinearArgument.

Definition at line 30 of file AffineExpression.java.

◆ build() [2/2]

LinearExpr com.google.ortools.sat.AffineExpression.build ( )

LinearArgument interface.

Implements com.google.ortools.sat.LinearArgument.

Definition at line 30 of file AffineExpression.java.

◆ getCoefficient() [1/2]

long com.google.ortools.sat.AffineExpression.getCoefficient ( int index)

Returns the ith coefficient.

Implements com.google.ortools.sat.LinearExpr.

Definition at line 49 of file AffineExpression.java.

◆ getCoefficient() [2/2]

long com.google.ortools.sat.AffineExpression.getCoefficient ( int index)

Returns the ith coefficient.

Implements com.google.ortools.sat.LinearExpr.

Definition at line 49 of file AffineExpression.java.

◆ getOffset() [1/2]

long com.google.ortools.sat.AffineExpression.getOffset ( )

Returns the constant part of the expression.

Implements com.google.ortools.sat.LinearExpr.

Definition at line 57 of file AffineExpression.java.

◆ getOffset() [2/2]

long com.google.ortools.sat.AffineExpression.getOffset ( )

Returns the constant part of the expression.

Implements com.google.ortools.sat.LinearExpr.

Definition at line 57 of file AffineExpression.java.

◆ getVariableIndex() [1/2]

int com.google.ortools.sat.AffineExpression.getVariableIndex ( int index)

Returns the index of the ith variable.

Implements com.google.ortools.sat.LinearExpr.

Definition at line 41 of file AffineExpression.java.

◆ getVariableIndex() [2/2]

int com.google.ortools.sat.AffineExpression.getVariableIndex ( int index)

Returns the index of the ith variable.

Implements com.google.ortools.sat.LinearExpr.

Definition at line 41 of file AffineExpression.java.

◆ numElements() [1/2]

int com.google.ortools.sat.AffineExpression.numElements ( )

LinearExpr interface.

Implements com.google.ortools.sat.LinearExpr.

Definition at line 36 of file AffineExpression.java.

◆ numElements() [2/2]

int com.google.ortools.sat.AffineExpression.numElements ( )

LinearExpr interface.

Implements com.google.ortools.sat.LinearExpr.

Definition at line 36 of file AffineExpression.java.


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