Scippy

SCIP

Solving Constraint Integer Programs

Detailed Description

some API functions of removed constraint handler for second order cone constraints \(\sqrt{\gamma + \sum_{i=1}^{n} (\alpha_i\, (x_i + \beta_i))^2} \leq \alpha_{n+1}\, (x_{n+1}+\beta_{n+1})\)

Author
Stefan Vigerske

Definition in file cons_soc.c.

#include "scip/cons_soc.h"
#include "scip/cons_nonlinear.h"
#include "scip/expr_var.h"
#include "scip/expr_pow.h"
#include "scip/expr_sum.h"

Go to the source code of this file.

Functions

static SCIP_RETCODE createSOCExpression (SCIP *scip, SCIP_EXPR **expr, int nvars, SCIP_VAR **vars, SCIP_Real *coefs, SCIP_Real *offsets, SCIP_Real constant, SCIP_VAR *rhsvar, SCIP_Real rhscoeff)
 
SCIP_RETCODE SCIPcreateConsSOC (SCIP *scip, SCIP_CONS **cons, const char *name, int nvars, SCIP_VAR **vars, SCIP_Real *coefs, SCIP_Real *offsets, SCIP_Real constant, SCIP_VAR *rhsvar, SCIP_Real rhscoeff, SCIP_Real rhsoffset, SCIP_Bool initial, SCIP_Bool separate, SCIP_Bool enforce, SCIP_Bool check, SCIP_Bool propagate, SCIP_Bool local, SCIP_Bool modifiable, SCIP_Bool dynamic, SCIP_Bool removable)
 
SCIP_RETCODE SCIPcreateConsBasicSOC (SCIP *scip, SCIP_CONS **cons, const char *name, int nvars, SCIP_VAR **vars, SCIP_Real *coefs, SCIP_Real *offsets, SCIP_Real constant, SCIP_VAR *rhsvar, SCIP_Real rhscoeff, SCIP_Real rhsoffset)
 
SCIP_RETCODE SCIPgetNlRowSOC (SCIP *scip, SCIP_CONS *cons, SCIP_NLROW **nlrow)
 

Function Documentation

◆ createSOCExpression()

static SCIP_RETCODE createSOCExpression ( SCIP scip,
SCIP_EXPR **  expr,
int  nvars,
SCIP_VAR **  vars,
SCIP_Real coefs,
SCIP_Real offsets,
SCIP_Real  constant,
SCIP_VAR rhsvar,
SCIP_Real  rhscoeff 
)
static

creates expression for \(\sqrt{\gamma + \sum_{i=1}^{n} (\alpha_i\, (x_i + \beta_i))^2} - \alpha_{n+1} x_{n+1}\)

Parameters
scipSCIP data structure
exprbuffer to store expression
nvarsnumber of variables on left hand side of constraint (n)
varsarray with variables on left hand side (x_i)
coefsarray with coefficients of left hand side variables (alpha_i), or NULL if all 1.0
offsetsarray with offsets of variables (beta_i), or NULL if all 0.0
constantconstant on left hand side (gamma)
rhsvarvariable on right hand side of constraint (x_{n+1})
rhscoeffcoefficient of variable on right hand side (alpha_{n+1})

Definition at line 32 of file cons_soc.c.

References NULL, SCIP_CALL, SCIP_OKAY, SCIP_Real, SCIPappendExprSumExpr(), SCIPcreateExprPow(), SCIPcreateExprSum(), SCIPcreateExprVar(), and SCIPreleaseExpr().

Referenced by SCIPcreateConsBasicSOC(), and SCIPcreateConsSOC().