PySCIPOpt  5.1.1
Python Interface for the SCIP Optimization Suite
GenExpr Class Reference

Public Member Functions

def __abs__ (self)
 
def __add__ (self, other)
 
def __init__ (self)
 
def __mul__ (self, other)
 
def __neg__ (self)
 
def __pow__ (self, other, modulo)
 
def __radd__ (self, other)
 
def __richcmp__ (self, other, op)
 
def __rmul__ (self, other)
 
def __rsub__ (self, other)
 
def __rtruediv__ (self, other)
 
def __sub__ (self, other)
 
def __truediv__ (self, other)
 
def degree (self)
 
def getOp (self)
 

Detailed Description

 General expressions of variables with operator overloading.
Note
  • these expressions are not smart enough to identify equal terms
  • in contrast to polynomial expressions, __getitem__ is not implemented so expr[x] will generate an error instead of returning the coefficient of x
See also the description in the expr.pxi.

Definition at line 395 of file expr.pxi.

Constructor & Destructor Documentation

◆ __init__()

def __init__ (   self)
 

Reimplemented in PowExpr, ProdExpr, and SumExpr.

Definition at line 400 of file expr.pxi.

Member Function Documentation

◆ __abs__()

def __abs__ (   self)

Definition at line 403 of file expr.pxi.

◆ __add__()

def __add__ (   self,
  other 
)

Definition at line 406 of file expr.pxi.

References pyscipopt.expr.buildGenExprObj().

◆ __mul__()

def __mul__ (   self,
  other 
)

Definition at line 461 of file expr.pxi.

References pyscipopt.expr.buildGenExprObj().

◆ __neg__()

def __neg__ (   self)

Definition at line 533 of file expr.pxi.

◆ __pow__()

def __pow__ (   self,
  other,
  modulo 
)

◆ __radd__()

def __radd__ (   self,
  other 
)

Definition at line 539 of file expr.pxi.

References Term.__add__(), Expr.__add__(), and GenExpr.__add__().

◆ __richcmp__()

def __richcmp__ (   self,
  other,
  op 
)
turn it into a constraint

Definition at line 548 of file expr.pxi.

◆ __rmul__()

def __rmul__ (   self,
  other 
)

Definition at line 542 of file expr.pxi.

References Expr.__mul__(), and GenExpr.__mul__().

◆ __rsub__()

def __rsub__ (   self,
  other 
)

Definition at line 545 of file expr.pxi.

◆ __rtruediv__()

def __rtruediv__ (   self,
  other 
)
other / self 

Definition at line 528 of file expr.pxi.

References pyscipopt.expr.buildGenExprObj().

◆ __sub__()

def __sub__ (   self,
  other 
)

Definition at line 536 of file expr.pxi.

◆ __truediv__()

def __truediv__ (   self,
  other 
)

Definition at line 521 of file expr.pxi.

References pyscipopt.expr.buildGenExprObj().

◆ degree()

def degree (   self)
Note: none of these expressions should be polynomial

Definition at line 552 of file expr.pxi.

◆ getOp()

def getOp (   self)
returns operator of GenExpr

Definition at line 556 of file expr.pxi.

References SumExpr._op, ProdExpr._op, VarExpr._op, PowExpr._op, UnaryExpr._op, and Constant._op.


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