InterviewSolution
| 1. |
Are The Variables And Rows Sorted In Any Particular Order? |
|
Answer» The variable array which you get by SCIPgetVarSol () is internally sorted by variable types. The ordering is binary, INTEGER, implicit integer and continuous variables, i.e., the binary variables are stored at POSITION [0... nbinvars-1], the GENERAL integers at [nbinvars... nbinvars+nintvars-1], and so on. It holds that nvars = nbinvars + ninitvars + nimplvars + ncontvars. There is no further sorting within these sections, as WELL as there is no sorting for the rows. But each column and each row has a unique index, which can be obtained by SCIPcolGetIndex () and SCIPcolGetIndex (), RESPECTIVELY. The variable array which you get by SCIPgetVarSol () is internally sorted by variable types. The ordering is binary, integer, implicit integer and continuous variables, i.e., the binary variables are stored at position [0... nbinvars-1], the general integers at [nbinvars... nbinvars+nintvars-1], and so on. It holds that nvars = nbinvars + ninitvars + nimplvars + ncontvars. There is no further sorting within these sections, as well as there is no sorting for the rows. But each column and each row has a unique index, which can be obtained by SCIPcolGetIndex () and SCIPcolGetIndex (), respectively. |
|