@@ -60,15 +60,15 @@ function MOI.get(
60
60
expr_ref = SCIPgetExprNonlinear (c)
61
61
# This call is required to get quaddata computed in the expression
62
62
isq = Ref {UInt32} (100 )
63
- @SCIP_CALL LibSCIP . SCIPcheckExprQuadratic (o, expr_ref, isq)
63
+ @SCIP_CALL SCIPcheckExprQuadratic (o, expr_ref, isq)
64
64
@assert isq[] == 1
65
65
constant_ref = Ref {Cdouble} (- 1.0 )
66
66
n_linear_terms_ref = Ref {Cint} (- 1 )
67
- linear_exprs = Ref {Ptr{Ptr{LibSCIP. SCIP_EXPR}}} ()
67
+ linear_exprs = Ref {Ptr{Ptr{SCIP_EXPR}}} ()
68
68
lincoefs = Ref {Ptr{Cdouble}} ()
69
69
n_quad_terms_ref = Ref {Cint} (- 1 )
70
70
n_bilinear_terms_ref = Ref {Cint} (- 1 )
71
- LibSCIP . SCIPexprGetQuadraticData (
71
+ SCIPexprGetQuadraticData (
72
72
expr_ref,
73
73
constant_ref,
74
74
n_linear_terms_ref,
@@ -83,16 +83,16 @@ function MOI.get(
83
83
unsafe_wrap (Vector{Ptr{Cvoid}}, linear_exprs[], n_linear_terms_ref[])
84
84
lin_coeff_vec =
85
85
unsafe_wrap (Vector{Cdouble}, lincoefs[], n_linear_terms_ref[])
86
- func = SCIP . MOI. ScalarQuadraticFunction {Float64} ([], [], constant_ref[])
86
+ func = MOI. ScalarQuadraticFunction {Float64} ([], [], constant_ref[])
87
87
for idx in 1 : n_linear_terms_ref[]
88
- var_ptr = LibSCIP . SCIPgetVarExprVar (lin_expr_vec[idx])
88
+ var_ptr = SCIPgetVarExprVar (lin_expr_vec[idx])
89
89
func += lin_coeff_vec[idx] * MOI. VariableIndex (o. reference[var_ptr]. val)
90
90
end
91
91
for term_idx in 1 : n_quad_terms_ref[]
92
92
var_expr = Ref {Ptr{Cvoid}} ()
93
93
lin_coef_ref = Ref {Cdouble} ()
94
94
sqr_coef_ref = Ref {Cdouble} ()
95
- LibSCIP . SCIPexprGetQuadraticQuadTerm (
95
+ SCIPexprGetQuadraticQuadTerm (
96
96
expr_ref,
97
97
term_idx - 1 , # 0-indexed terms
98
98
var_expr,
@@ -104,7 +104,7 @@ function MOI.get(
104
104
)
105
105
@assert lin_coef_ref[] == 0.0
106
106
if sqr_coef_ref[] != 0.0
107
- var_ptr = LibSCIP . SCIPgetVarExprVar (var_expr[])
107
+ var_ptr = SCIPgetVarExprVar (var_expr[])
108
108
var_idx = MOI. VariableIndex (o. reference[var_ptr]. val)
109
109
MOI. Utilities. operate! (
110
110
+ ,
@@ -118,7 +118,7 @@ function MOI.get(
118
118
var_expr1 = Ref {Ptr{Cvoid}} ()
119
119
var_expr2 = Ref {Ptr{Cvoid}} ()
120
120
coef_ref = Ref {Cdouble} ()
121
- LibSCIP . SCIPexprGetQuadraticBilinTerm (
121
+ SCIPexprGetQuadraticBilinTerm (
122
122
expr_ref,
123
123
term_idx - 1 ,
124
124
var_expr1,
@@ -128,9 +128,9 @@ function MOI.get(
128
128
C_NULL ,
129
129
)
130
130
if coef_ref[] != 0.0
131
- var_ptr1 = LibSCIP . SCIPgetVarExprVar (var_expr1[])
131
+ var_ptr1 = SCIPgetVarExprVar (var_expr1[])
132
132
var_idx1 = MOI. VariableIndex (o. reference[var_ptr1]. val)
133
- var_ptr2 = LibSCIP . SCIPgetVarExprVar (var_expr2[])
133
+ var_ptr2 = SCIPgetVarExprVar (var_expr2[])
134
134
var_idx2 = MOI. VariableIndex (o. reference[var_ptr2]. val)
135
135
MOI. Utilities. operate! (
136
136
+ ,
@@ -164,7 +164,7 @@ function MOI.get(
164
164
c = cons (o, ci)
165
165
expr_ref = SCIPgetExprNonlinear (c)
166
166
isq = Ref {UInt32} (100 )
167
- @SCIP_CALL LibSCIP . SCIPcheckExprQuadratic (o, expr_ref, isq)
167
+ @SCIP_CALL SCIPcheckExprQuadratic (o, expr_ref, isq)
168
168
@assert isq[] == 1
169
169
sol = SCIPgetBestSol (o)
170
170
@SCIP_CALL SCIPevalExpr (o, expr_ref, sol, Clonglong (0 ))
0 commit comments