ruby-cbc 0.1.9
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.gitignore +9 -0
- data/.rspec +2 -0
- data/.travis.yml +4 -0
- data/Gemfile +4 -0
- data/README.md +203 -0
- data/Rakefile +40 -0
- data/bin/console +14 -0
- data/bin/setup +7 -0
- data/ext/ruby-cbc/cbc.i +15 -0
- data/ext/ruby-cbc/cbc_wrap.c +4618 -0
- data/ext/ruby-cbc/extconf.rb +60 -0
- data/ext/ruby-cbc/install/bin/cbc +0 -0
- data/ext/ruby-cbc/install/bin/clp +0 -0
- data/ext/ruby-cbc/install/include/coin/CbcBranchActual.hpp +24 -0
- data/ext/ruby-cbc/install/include/coin/CbcBranchAllDifferent.hpp +62 -0
- data/ext/ruby-cbc/install/include/coin/CbcBranchBase.hpp +78 -0
- data/ext/ruby-cbc/install/include/coin/CbcBranchCut.hpp +183 -0
- data/ext/ruby-cbc/install/include/coin/CbcBranchDecision.hpp +129 -0
- data/ext/ruby-cbc/install/include/coin/CbcBranchDefaultDecision.hpp +100 -0
- data/ext/ruby-cbc/install/include/coin/CbcBranchDynamic.hpp +206 -0
- data/ext/ruby-cbc/install/include/coin/CbcBranchLotsize.hpp +242 -0
- data/ext/ruby-cbc/install/include/coin/CbcBranchToFixLots.hpp +94 -0
- data/ext/ruby-cbc/install/include/coin/CbcBranchingObject.hpp +236 -0
- data/ext/ruby-cbc/install/include/coin/CbcClique.hpp +303 -0
- data/ext/ruby-cbc/install/include/coin/CbcCompare.hpp +39 -0
- data/ext/ruby-cbc/install/include/coin/CbcCompareActual.hpp +14 -0
- data/ext/ruby-cbc/install/include/coin/CbcCompareBase.hpp +142 -0
- data/ext/ruby-cbc/install/include/coin/CbcCompareDefault.hpp +120 -0
- data/ext/ruby-cbc/install/include/coin/CbcCompareDepth.hpp +47 -0
- data/ext/ruby-cbc/install/include/coin/CbcCompareEstimate.hpp +48 -0
- data/ext/ruby-cbc/install/include/coin/CbcCompareObjective.hpp +49 -0
- data/ext/ruby-cbc/install/include/coin/CbcConfig.h +14 -0
- data/ext/ruby-cbc/install/include/coin/CbcConsequence.hpp +49 -0
- data/ext/ruby-cbc/install/include/coin/CbcCountRowCut.hpp +168 -0
- data/ext/ruby-cbc/install/include/coin/CbcCutGenerator.hpp +482 -0
- data/ext/ruby-cbc/install/include/coin/CbcCutModifier.hpp +57 -0
- data/ext/ruby-cbc/install/include/coin/CbcCutSubsetModifier.hpp +66 -0
- data/ext/ruby-cbc/install/include/coin/CbcDummyBranchingObject.hpp +83 -0
- data/ext/ruby-cbc/install/include/coin/CbcEventHandler.hpp +245 -0
- data/ext/ruby-cbc/install/include/coin/CbcFathom.hpp +137 -0
- data/ext/ruby-cbc/install/include/coin/CbcFathomDynamicProgramming.hpp +169 -0
- data/ext/ruby-cbc/install/include/coin/CbcFeasibilityBase.hpp +56 -0
- data/ext/ruby-cbc/install/include/coin/CbcFixVariable.hpp +67 -0
- data/ext/ruby-cbc/install/include/coin/CbcFollowOn.hpp +207 -0
- data/ext/ruby-cbc/install/include/coin/CbcFullNodeInfo.hpp +161 -0
- data/ext/ruby-cbc/install/include/coin/CbcGeneral.hpp +60 -0
- data/ext/ruby-cbc/install/include/coin/CbcGeneralDepth.hpp +279 -0
- data/ext/ruby-cbc/install/include/coin/CbcHeuristic.hpp +682 -0
- data/ext/ruby-cbc/install/include/coin/CbcHeuristicDINS.hpp +96 -0
- data/ext/ruby-cbc/install/include/coin/CbcHeuristicDW.hpp +309 -0
- data/ext/ruby-cbc/install/include/coin/CbcHeuristicDive.hpp +192 -0
- data/ext/ruby-cbc/install/include/coin/CbcHeuristicDiveCoefficient.hpp +52 -0
- data/ext/ruby-cbc/install/include/coin/CbcHeuristicDiveFractional.hpp +52 -0
- data/ext/ruby-cbc/install/include/coin/CbcHeuristicDiveGuided.hpp +55 -0
- data/ext/ruby-cbc/install/include/coin/CbcHeuristicDiveLineSearch.hpp +52 -0
- data/ext/ruby-cbc/install/include/coin/CbcHeuristicDivePseudoCost.hpp +60 -0
- data/ext/ruby-cbc/install/include/coin/CbcHeuristicDiveVectorLength.hpp +52 -0
- data/ext/ruby-cbc/install/include/coin/CbcHeuristicFPump.hpp +340 -0
- data/ext/ruby-cbc/install/include/coin/CbcHeuristicGreedy.hpp +280 -0
- data/ext/ruby-cbc/install/include/coin/CbcHeuristicLocal.hpp +271 -0
- data/ext/ruby-cbc/install/include/coin/CbcHeuristicPivotAndFix.hpp +58 -0
- data/ext/ruby-cbc/install/include/coin/CbcHeuristicRENS.hpp +77 -0
- data/ext/ruby-cbc/install/include/coin/CbcHeuristicRINS.hpp +102 -0
- data/ext/ruby-cbc/install/include/coin/CbcHeuristicRandRound.hpp +58 -0
- data/ext/ruby-cbc/install/include/coin/CbcHeuristicVND.hpp +94 -0
- data/ext/ruby-cbc/install/include/coin/CbcLinked.hpp +1406 -0
- data/ext/ruby-cbc/install/include/coin/CbcMessage.hpp +94 -0
- data/ext/ruby-cbc/install/include/coin/CbcMipStartIO.hpp +26 -0
- data/ext/ruby-cbc/install/include/coin/CbcModel.hpp +2952 -0
- data/ext/ruby-cbc/install/include/coin/CbcNWay.hpp +166 -0
- data/ext/ruby-cbc/install/include/coin/CbcNode.hpp +351 -0
- data/ext/ruby-cbc/install/include/coin/CbcNodeInfo.hpp +349 -0
- data/ext/ruby-cbc/install/include/coin/CbcObject.hpp +272 -0
- data/ext/ruby-cbc/install/include/coin/CbcObjectUpdateData.hpp +64 -0
- data/ext/ruby-cbc/install/include/coin/CbcOrClpParam.cpp +4134 -0
- data/ext/ruby-cbc/install/include/coin/CbcOrClpParam.hpp +532 -0
- data/ext/ruby-cbc/install/include/coin/CbcParam.hpp +324 -0
- data/ext/ruby-cbc/install/include/coin/CbcPartialNodeInfo.hpp +110 -0
- data/ext/ruby-cbc/install/include/coin/CbcSOS.hpp +279 -0
- data/ext/ruby-cbc/install/include/coin/CbcSimpleInteger.hpp +286 -0
- data/ext/ruby-cbc/install/include/coin/CbcSimpleIntegerDynamicPseudoCost.hpp +564 -0
- data/ext/ruby-cbc/install/include/coin/CbcSimpleIntegerPseudoCost.hpp +114 -0
- data/ext/ruby-cbc/install/include/coin/CbcSolver.hpp +447 -0
- data/ext/ruby-cbc/install/include/coin/CbcStrategy.hpp +258 -0
- data/ext/ruby-cbc/install/include/coin/CbcSubProblem.hpp +83 -0
- data/ext/ruby-cbc/install/include/coin/CbcTree.hpp +490 -0
- data/ext/ruby-cbc/install/include/coin/CbcTreeLocal.hpp +372 -0
- data/ext/ruby-cbc/install/include/coin/Cbc_C_Interface.h +381 -0
- data/ext/ruby-cbc/install/include/coin/Cgl012cut.hpp +464 -0
- data/ext/ruby-cbc/install/include/coin/CglAllDifferent.hpp +115 -0
- data/ext/ruby-cbc/install/include/coin/CglClique.hpp +308 -0
- data/ext/ruby-cbc/install/include/coin/CglConfig.h +19 -0
- data/ext/ruby-cbc/install/include/coin/CglCutGenerator.hpp +121 -0
- data/ext/ruby-cbc/install/include/coin/CglDuplicateRow.hpp +189 -0
- data/ext/ruby-cbc/install/include/coin/CglFlowCover.hpp +371 -0
- data/ext/ruby-cbc/install/include/coin/CglGMI.hpp +364 -0
- data/ext/ruby-cbc/install/include/coin/CglGMIParam.hpp +313 -0
- data/ext/ruby-cbc/install/include/coin/CglGomory.hpp +204 -0
- data/ext/ruby-cbc/install/include/coin/CglKnapsackCover.hpp +310 -0
- data/ext/ruby-cbc/install/include/coin/CglLandP.hpp +306 -0
- data/ext/ruby-cbc/install/include/coin/CglLandPValidator.hpp +130 -0
- data/ext/ruby-cbc/install/include/coin/CglLiftAndProject.hpp +104 -0
- data/ext/ruby-cbc/install/include/coin/CglMessage.hpp +50 -0
- data/ext/ruby-cbc/install/include/coin/CglMixedIntegerRounding.hpp +429 -0
- data/ext/ruby-cbc/install/include/coin/CglMixedIntegerRounding2.hpp +427 -0
- data/ext/ruby-cbc/install/include/coin/CglOddHole.hpp +160 -0
- data/ext/ruby-cbc/install/include/coin/CglParam.hpp +93 -0
- data/ext/ruby-cbc/install/include/coin/CglPreProcess.hpp +492 -0
- data/ext/ruby-cbc/install/include/coin/CglProbing.hpp +543 -0
- data/ext/ruby-cbc/install/include/coin/CglRedSplit.hpp +448 -0
- data/ext/ruby-cbc/install/include/coin/CglRedSplit2.hpp +494 -0
- data/ext/ruby-cbc/install/include/coin/CglRedSplit2Param.hpp +495 -0
- data/ext/ruby-cbc/install/include/coin/CglRedSplitParam.hpp +272 -0
- data/ext/ruby-cbc/install/include/coin/CglResidualCapacity.hpp +240 -0
- data/ext/ruby-cbc/install/include/coin/CglSimpleRounding.hpp +174 -0
- data/ext/ruby-cbc/install/include/coin/CglStored.hpp +125 -0
- data/ext/ruby-cbc/install/include/coin/CglTreeInfo.hpp +180 -0
- data/ext/ruby-cbc/install/include/coin/CglTwomir.hpp +565 -0
- data/ext/ruby-cbc/install/include/coin/CglZeroHalf.hpp +133 -0
- data/ext/ruby-cbc/install/include/coin/ClpAmplObjective.hpp +113 -0
- data/ext/ruby-cbc/install/include/coin/ClpCholeskyBase.hpp +294 -0
- data/ext/ruby-cbc/install/include/coin/ClpCholeskyDense.hpp +162 -0
- data/ext/ruby-cbc/install/include/coin/ClpConfig.h +17 -0
- data/ext/ruby-cbc/install/include/coin/ClpConstraint.hpp +125 -0
- data/ext/ruby-cbc/install/include/coin/ClpConstraintAmpl.hpp +108 -0
- data/ext/ruby-cbc/install/include/coin/ClpConstraintLinear.hpp +110 -0
- data/ext/ruby-cbc/install/include/coin/ClpConstraintQuadratic.hpp +119 -0
- data/ext/ruby-cbc/install/include/coin/ClpDualRowDantzig.hpp +71 -0
- data/ext/ruby-cbc/install/include/coin/ClpDualRowPivot.hpp +129 -0
- data/ext/ruby-cbc/install/include/coin/ClpDualRowSteepest.hpp +153 -0
- data/ext/ruby-cbc/install/include/coin/ClpDummyMatrix.hpp +183 -0
- data/ext/ruby-cbc/install/include/coin/ClpDynamicExampleMatrix.hpp +186 -0
- data/ext/ruby-cbc/install/include/coin/ClpDynamicMatrix.hpp +381 -0
- data/ext/ruby-cbc/install/include/coin/ClpEventHandler.hpp +187 -0
- data/ext/ruby-cbc/install/include/coin/ClpFactorization.hpp +432 -0
- data/ext/ruby-cbc/install/include/coin/ClpGubDynamicMatrix.hpp +247 -0
- data/ext/ruby-cbc/install/include/coin/ClpGubMatrix.hpp +358 -0
- data/ext/ruby-cbc/install/include/coin/ClpInterior.hpp +570 -0
- data/ext/ruby-cbc/install/include/coin/ClpLinearObjective.hpp +103 -0
- data/ext/ruby-cbc/install/include/coin/ClpMatrixBase.hpp +524 -0
- data/ext/ruby-cbc/install/include/coin/ClpMessage.hpp +131 -0
- data/ext/ruby-cbc/install/include/coin/ClpModel.hpp +1307 -0
- data/ext/ruby-cbc/install/include/coin/ClpNetworkMatrix.hpp +229 -0
- data/ext/ruby-cbc/install/include/coin/ClpNode.hpp +349 -0
- data/ext/ruby-cbc/install/include/coin/ClpNonLinearCost.hpp +401 -0
- data/ext/ruby-cbc/install/include/coin/ClpObjective.hpp +134 -0
- data/ext/ruby-cbc/install/include/coin/ClpPackedMatrix.hpp +638 -0
- data/ext/ruby-cbc/install/include/coin/ClpParameters.hpp +126 -0
- data/ext/ruby-cbc/install/include/coin/ClpPdcoBase.hpp +103 -0
- data/ext/ruby-cbc/install/include/coin/ClpPlusMinusOneMatrix.hpp +290 -0
- data/ext/ruby-cbc/install/include/coin/ClpPresolve.hpp +299 -0
- data/ext/ruby-cbc/install/include/coin/ClpPrimalColumnDantzig.hpp +72 -0
- data/ext/ruby-cbc/install/include/coin/ClpPrimalColumnPivot.hpp +155 -0
- data/ext/ruby-cbc/install/include/coin/ClpPrimalColumnSteepest.hpp +247 -0
- data/ext/ruby-cbc/install/include/coin/ClpQuadraticObjective.hpp +155 -0
- data/ext/ruby-cbc/install/include/coin/ClpSimplex.hpp +1797 -0
- data/ext/ruby-cbc/install/include/coin/ClpSimplexDual.hpp +300 -0
- data/ext/ruby-cbc/install/include/coin/ClpSimplexNonlinear.hpp +117 -0
- data/ext/ruby-cbc/install/include/coin/ClpSimplexOther.hpp +277 -0
- data/ext/ruby-cbc/install/include/coin/ClpSimplexPrimal.hpp +244 -0
- data/ext/ruby-cbc/install/include/coin/ClpSolve.hpp +446 -0
- data/ext/ruby-cbc/install/include/coin/Clp_C_Interface.h +525 -0
- data/ext/ruby-cbc/install/include/coin/CoinAlloc.hpp +176 -0
- data/ext/ruby-cbc/install/include/coin/CoinBuild.hpp +149 -0
- data/ext/ruby-cbc/install/include/coin/CoinDenseFactorization.hpp +419 -0
- data/ext/ruby-cbc/install/include/coin/CoinDenseVector.hpp +383 -0
- data/ext/ruby-cbc/install/include/coin/CoinDistance.hpp +48 -0
- data/ext/ruby-cbc/install/include/coin/CoinError.hpp +257 -0
- data/ext/ruby-cbc/install/include/coin/CoinFactorization.hpp +2044 -0
- data/ext/ruby-cbc/install/include/coin/CoinFileIO.hpp +166 -0
- data/ext/ruby-cbc/install/include/coin/CoinFinite.hpp +34 -0
- data/ext/ruby-cbc/install/include/coin/CoinFloatEqual.hpp +177 -0
- data/ext/ruby-cbc/install/include/coin/CoinHelperFunctions.hpp +1111 -0
- data/ext/ruby-cbc/install/include/coin/CoinIndexedVector.hpp +1164 -0
- data/ext/ruby-cbc/install/include/coin/CoinLpIO.hpp +805 -0
- data/ext/ruby-cbc/install/include/coin/CoinMessage.hpp +96 -0
- data/ext/ruby-cbc/install/include/coin/CoinMessageHandler.hpp +666 -0
- data/ext/ruby-cbc/install/include/coin/CoinModel.hpp +1054 -0
- data/ext/ruby-cbc/install/include/coin/CoinModelUseful.hpp +441 -0
- data/ext/ruby-cbc/install/include/coin/CoinMpsIO.hpp +1056 -0
- data/ext/ruby-cbc/install/include/coin/CoinOslFactorization.hpp +280 -0
- data/ext/ruby-cbc/install/include/coin/CoinPackedMatrix.hpp +947 -0
- data/ext/ruby-cbc/install/include/coin/CoinPackedVector.hpp +657 -0
- data/ext/ruby-cbc/install/include/coin/CoinPackedVectorBase.hpp +269 -0
- data/ext/ruby-cbc/install/include/coin/CoinParam.hpp +644 -0
- data/ext/ruby-cbc/install/include/coin/CoinPragma.hpp +26 -0
- data/ext/ruby-cbc/install/include/coin/CoinPresolveDoubleton.hpp +73 -0
- data/ext/ruby-cbc/install/include/coin/CoinPresolveDual.hpp +85 -0
- data/ext/ruby-cbc/install/include/coin/CoinPresolveDupcol.hpp +226 -0
- data/ext/ruby-cbc/install/include/coin/CoinPresolveEmpty.hpp +116 -0
- data/ext/ruby-cbc/install/include/coin/CoinPresolveFixed.hpp +181 -0
- data/ext/ruby-cbc/install/include/coin/CoinPresolveForcing.hpp +61 -0
- data/ext/ruby-cbc/install/include/coin/CoinPresolveImpliedFree.hpp +60 -0
- data/ext/ruby-cbc/install/include/coin/CoinPresolveIsolated.hpp +51 -0
- data/ext/ruby-cbc/install/include/coin/CoinPresolveMatrix.hpp +1842 -0
- data/ext/ruby-cbc/install/include/coin/CoinPresolveMonitor.hpp +105 -0
- data/ext/ruby-cbc/install/include/coin/CoinPresolvePsdebug.hpp +166 -0
- data/ext/ruby-cbc/install/include/coin/CoinPresolveSingleton.hpp +112 -0
- data/ext/ruby-cbc/install/include/coin/CoinPresolveSubst.hpp +101 -0
- data/ext/ruby-cbc/install/include/coin/CoinPresolveTighten.hpp +55 -0
- data/ext/ruby-cbc/install/include/coin/CoinPresolveTripleton.hpp +66 -0
- data/ext/ruby-cbc/install/include/coin/CoinPresolveUseless.hpp +63 -0
- data/ext/ruby-cbc/install/include/coin/CoinPresolveZeros.hpp +60 -0
- data/ext/ruby-cbc/install/include/coin/CoinRational.hpp +44 -0
- data/ext/ruby-cbc/install/include/coin/CoinSearchTree.hpp +465 -0
- data/ext/ruby-cbc/install/include/coin/CoinShallowPackedVector.hpp +148 -0
- data/ext/ruby-cbc/install/include/coin/CoinSignal.hpp +117 -0
- data/ext/ruby-cbc/install/include/coin/CoinSimpFactorization.hpp +431 -0
- data/ext/ruby-cbc/install/include/coin/CoinSmartPtr.hpp +528 -0
- data/ext/ruby-cbc/install/include/coin/CoinSnapshot.hpp +476 -0
- data/ext/ruby-cbc/install/include/coin/CoinSort.hpp +678 -0
- data/ext/ruby-cbc/install/include/coin/CoinStructuredModel.hpp +247 -0
- data/ext/ruby-cbc/install/include/coin/CoinTime.hpp +310 -0
- data/ext/ruby-cbc/install/include/coin/CoinTypes.hpp +64 -0
- data/ext/ruby-cbc/install/include/coin/CoinUtility.hpp +19 -0
- data/ext/ruby-cbc/install/include/coin/CoinUtilsConfig.h +34 -0
- data/ext/ruby-cbc/install/include/coin/CoinWarmStart.hpp +58 -0
- data/ext/ruby-cbc/install/include/coin/CoinWarmStartBasis.hpp +456 -0
- data/ext/ruby-cbc/install/include/coin/CoinWarmStartDual.hpp +166 -0
- data/ext/ruby-cbc/install/include/coin/CoinWarmStartPrimalDual.hpp +211 -0
- data/ext/ruby-cbc/install/include/coin/CoinWarmStartVector.hpp +488 -0
- data/ext/ruby-cbc/install/include/coin/Coin_C_defines.h +115 -0
- data/ext/ruby-cbc/install/include/coin/Idiot.hpp +298 -0
- data/ext/ruby-cbc/install/include/coin/OsiAuxInfo.hpp +206 -0
- data/ext/ruby-cbc/install/include/coin/OsiBranchingObject.hpp +1005 -0
- data/ext/ruby-cbc/install/include/coin/OsiCbcSolverInterface.hpp +764 -0
- data/ext/ruby-cbc/install/include/coin/OsiChooseVariable.hpp +534 -0
- data/ext/ruby-cbc/install/include/coin/OsiClpSolverInterface.hpp +1509 -0
- data/ext/ruby-cbc/install/include/coin/OsiColCut.hpp +324 -0
- data/ext/ruby-cbc/install/include/coin/OsiCollections.hpp +35 -0
- data/ext/ruby-cbc/install/include/coin/OsiConfig.h +19 -0
- data/ext/ruby-cbc/install/include/coin/OsiCut.hpp +245 -0
- data/ext/ruby-cbc/install/include/coin/OsiCuts.hpp +474 -0
- data/ext/ruby-cbc/install/include/coin/OsiPresolve.hpp +252 -0
- data/ext/ruby-cbc/install/include/coin/OsiRowCut.hpp +331 -0
- data/ext/ruby-cbc/install/include/coin/OsiRowCutDebugger.hpp +187 -0
- data/ext/ruby-cbc/install/include/coin/OsiSolverBranch.hpp +152 -0
- data/ext/ruby-cbc/install/include/coin/OsiSolverInterface.hpp +2143 -0
- data/ext/ruby-cbc/install/include/coin/OsiSolverParameters.hpp +142 -0
- data/ext/ruby-cbc/install/include/coin/OsiUnitTests.hpp +374 -0
- data/ext/ruby-cbc/install/lib/libCbc.la +35 -0
- data/ext/ruby-cbc/install/lib/libCbc.so +0 -0
- data/ext/ruby-cbc/install/lib/libCbc.so.3 +0 -0
- data/ext/ruby-cbc/install/lib/libCbc.so.3.9.7 +0 -0
- data/ext/ruby-cbc/install/lib/libCbcSolver.la +35 -0
- data/ext/ruby-cbc/install/lib/libCbcSolver.so +0 -0
- data/ext/ruby-cbc/install/lib/libCbcSolver.so.3 +0 -0
- data/ext/ruby-cbc/install/lib/libCbcSolver.so.3.9.7 +0 -0
- data/ext/ruby-cbc/install/lib/libCgl.la +35 -0
- data/ext/ruby-cbc/install/lib/libCgl.so +0 -0
- data/ext/ruby-cbc/install/lib/libCgl.so.1 +0 -0
- data/ext/ruby-cbc/install/lib/libCgl.so.1.9.7 +0 -0
- data/ext/ruby-cbc/install/lib/libClp.la +35 -0
- data/ext/ruby-cbc/install/lib/libClp.so +0 -0
- data/ext/ruby-cbc/install/lib/libClp.so.1 +0 -0
- data/ext/ruby-cbc/install/lib/libClp.so.1.13.9 +0 -0
- data/ext/ruby-cbc/install/lib/libClpSolver.la +35 -0
- data/ext/ruby-cbc/install/lib/libClpSolver.so +0 -0
- data/ext/ruby-cbc/install/lib/libClpSolver.so.1 +0 -0
- data/ext/ruby-cbc/install/lib/libClpSolver.so.1.13.9 +0 -0
- data/ext/ruby-cbc/install/lib/libCoinUtils.la +35 -0
- data/ext/ruby-cbc/install/lib/libCoinUtils.so +0 -0
- data/ext/ruby-cbc/install/lib/libCoinUtils.so.3 +0 -0
- data/ext/ruby-cbc/install/lib/libCoinUtils.so.3.10.11 +0 -0
- data/ext/ruby-cbc/install/lib/libOsi.la +35 -0
- data/ext/ruby-cbc/install/lib/libOsi.so +0 -0
- data/ext/ruby-cbc/install/lib/libOsi.so.1 +0 -0
- data/ext/ruby-cbc/install/lib/libOsi.so.1.12.6 +0 -0
- data/ext/ruby-cbc/install/lib/libOsiCbc.la +35 -0
- data/ext/ruby-cbc/install/lib/libOsiCbc.so +0 -0
- data/ext/ruby-cbc/install/lib/libOsiCbc.so.3 +0 -0
- data/ext/ruby-cbc/install/lib/libOsiCbc.so.3.9.7 +0 -0
- data/ext/ruby-cbc/install/lib/libOsiClp.la +35 -0
- data/ext/ruby-cbc/install/lib/libOsiClp.so +0 -0
- data/ext/ruby-cbc/install/lib/libOsiClp.so.1 +0 -0
- data/ext/ruby-cbc/install/lib/libOsiClp.so.1.13.9 +0 -0
- data/ext/ruby-cbc/install/lib/libOsiCommonTests.la +35 -0
- data/ext/ruby-cbc/install/lib/libOsiCommonTests.so +0 -0
- data/ext/ruby-cbc/install/lib/libOsiCommonTests.so.1 +0 -0
- data/ext/ruby-cbc/install/lib/libOsiCommonTests.so.1.12.6 +0 -0
- data/ext/ruby-cbc/install/lib/pkgconfig/cbc.pc +12 -0
- data/ext/ruby-cbc/install/lib/pkgconfig/cgl.pc +12 -0
- data/ext/ruby-cbc/install/lib/pkgconfig/clp.pc +12 -0
- data/ext/ruby-cbc/install/lib/pkgconfig/coindatamiplib3.pc +9 -0
- data/ext/ruby-cbc/install/lib/pkgconfig/coindatasample.pc +9 -0
- data/ext/ruby-cbc/install/lib/pkgconfig/coinutils.pc +12 -0
- data/ext/ruby-cbc/install/lib/pkgconfig/osi-cbc.pc +12 -0
- data/ext/ruby-cbc/install/lib/pkgconfig/osi-clp.pc +12 -0
- data/ext/ruby-cbc/install/lib/pkgconfig/osi-unittests.pc +12 -0
- data/ext/ruby-cbc/install/lib/pkgconfig/osi.pc +12 -0
- data/lib/ruby-cbc/ilp/constant.rb +44 -0
- data/lib/ruby-cbc/ilp/constraint.rb +32 -0
- data/lib/ruby-cbc/ilp/objective.rb +26 -0
- data/lib/ruby-cbc/ilp/term.rb +47 -0
- data/lib/ruby-cbc/ilp/term_array.rb +80 -0
- data/lib/ruby-cbc/ilp/var.rb +62 -0
- data/lib/ruby-cbc/model.rb +125 -0
- data/lib/ruby-cbc/problem.rb +170 -0
- data/lib/ruby-cbc/version.rb +3 -0
- data/lib/ruby-cbc.rb +21 -0
- data/ruby-cbc.gemspec +36 -0
- metadata +431 -0
@@ -0,0 +1,299 @@
|
|
1
|
+
/* $Id: ClpPresolve.hpp 2134 2015-03-22 16:40:43Z forrest $ */
|
2
|
+
// Copyright (C) 2002, International Business Machines
|
3
|
+
// Corporation and others. All Rights Reserved.
|
4
|
+
// This code is licensed under the terms of the Eclipse Public License (EPL).
|
5
|
+
|
6
|
+
#ifndef ClpPresolve_H
|
7
|
+
#define ClpPresolve_H
|
8
|
+
#include "ClpSimplex.hpp"
|
9
|
+
|
10
|
+
class CoinPresolveAction;
|
11
|
+
#include "CoinPresolveMatrix.hpp"
|
12
|
+
/** This is the Clp interface to CoinPresolve
|
13
|
+
|
14
|
+
*/
|
15
|
+
class ClpPresolve {
|
16
|
+
public:
|
17
|
+
/**@name Main Constructor, destructor */
|
18
|
+
//@{
|
19
|
+
/// Default constructor
|
20
|
+
ClpPresolve();
|
21
|
+
|
22
|
+
/// Virtual destructor
|
23
|
+
virtual ~ClpPresolve();
|
24
|
+
//@}
|
25
|
+
/**@name presolve - presolves a model, transforming the model
|
26
|
+
* and saving information in the ClpPresolve object needed for postsolving.
|
27
|
+
* This underlying (protected) method is virtual; the idea is that in the future,
|
28
|
+
* one could override this method to customize how the various
|
29
|
+
* presolve techniques are applied.
|
30
|
+
|
31
|
+
This version of presolve returns a pointer to a new presolved
|
32
|
+
model. NULL if infeasible or unbounded.
|
33
|
+
This should be paired with postsolve
|
34
|
+
below. The advantage of going back to original model is that it
|
35
|
+
will be exactly as it was i.e. 0.0 will not become 1.0e-19.
|
36
|
+
If keepIntegers is true then bounds may be tightened in
|
37
|
+
original. Bounds will be moved by up to feasibilityTolerance
|
38
|
+
to try and stay feasible.
|
39
|
+
Names will be dropped in presolved model if asked
|
40
|
+
*/
|
41
|
+
ClpSimplex * presolvedModel(ClpSimplex & si,
|
42
|
+
double feasibilityTolerance = 0.0,
|
43
|
+
bool keepIntegers = true,
|
44
|
+
int numberPasses = 5,
|
45
|
+
bool dropNames = false,
|
46
|
+
bool doRowObjective = false,
|
47
|
+
const char * prohibitedRows=NULL,
|
48
|
+
const char * prohibitedColumns=NULL);
|
49
|
+
#ifndef CLP_NO_STD
|
50
|
+
/** This version saves data in a file. The passed in model
|
51
|
+
is updated to be presolved model.
|
52
|
+
Returns non-zero if infeasible*/
|
53
|
+
int presolvedModelToFile(ClpSimplex &si, std::string fileName,
|
54
|
+
double feasibilityTolerance = 0.0,
|
55
|
+
bool keepIntegers = true,
|
56
|
+
int numberPasses = 5,
|
57
|
+
bool dropNames = false,
|
58
|
+
bool doRowObjective = false);
|
59
|
+
#endif
|
60
|
+
/** Return pointer to presolved model,
|
61
|
+
Up to user to destroy */
|
62
|
+
ClpSimplex * model() const;
|
63
|
+
/// Return pointer to original model
|
64
|
+
ClpSimplex * originalModel() const;
|
65
|
+
/// Set pointer to original model
|
66
|
+
void setOriginalModel(ClpSimplex * model);
|
67
|
+
|
68
|
+
/// return pointer to original columns
|
69
|
+
const int * originalColumns() const;
|
70
|
+
/// return pointer to original rows
|
71
|
+
const int * originalRows() const;
|
72
|
+
/** "Magic" number. If this is non-zero then any elements with this value
|
73
|
+
may change and so presolve is very limited in what can be done
|
74
|
+
to the row and column. This is for non-linear problems.
|
75
|
+
*/
|
76
|
+
inline void setNonLinearValue(double value) {
|
77
|
+
nonLinearValue_ = value;
|
78
|
+
}
|
79
|
+
inline double nonLinearValue() const {
|
80
|
+
return nonLinearValue_;
|
81
|
+
}
|
82
|
+
/// Whether we want to do dual part of presolve
|
83
|
+
inline bool doDual() const {
|
84
|
+
return (presolveActions_ & 1) == 0;
|
85
|
+
}
|
86
|
+
inline void setDoDual(bool doDual) {
|
87
|
+
if (doDual) presolveActions_ &= ~1;
|
88
|
+
else presolveActions_ |= 1;
|
89
|
+
}
|
90
|
+
/// Whether we want to do singleton part of presolve
|
91
|
+
inline bool doSingleton() const {
|
92
|
+
return (presolveActions_ & 2) == 0;
|
93
|
+
}
|
94
|
+
inline void setDoSingleton(bool doSingleton) {
|
95
|
+
if (doSingleton) presolveActions_ &= ~2;
|
96
|
+
else presolveActions_ |= 2;
|
97
|
+
}
|
98
|
+
/// Whether we want to do doubleton part of presolve
|
99
|
+
inline bool doDoubleton() const {
|
100
|
+
return (presolveActions_ & 4) == 0;
|
101
|
+
}
|
102
|
+
inline void setDoDoubleton(bool doDoubleton) {
|
103
|
+
if (doDoubleton) presolveActions_ &= ~4;
|
104
|
+
else presolveActions_ |= 4;
|
105
|
+
}
|
106
|
+
/// Whether we want to do tripleton part of presolve
|
107
|
+
inline bool doTripleton() const {
|
108
|
+
return (presolveActions_ & 8) == 0;
|
109
|
+
}
|
110
|
+
inline void setDoTripleton(bool doTripleton) {
|
111
|
+
if (doTripleton) presolveActions_ &= ~8;
|
112
|
+
else presolveActions_ |= 8;
|
113
|
+
}
|
114
|
+
/// Whether we want to do tighten part of presolve
|
115
|
+
inline bool doTighten() const {
|
116
|
+
return (presolveActions_ & 16) == 0;
|
117
|
+
}
|
118
|
+
inline void setDoTighten(bool doTighten) {
|
119
|
+
if (doTighten) presolveActions_ &= ~16;
|
120
|
+
else presolveActions_ |= 16;
|
121
|
+
}
|
122
|
+
/// Whether we want to do forcing part of presolve
|
123
|
+
inline bool doForcing() const {
|
124
|
+
return (presolveActions_ & 32) == 0;
|
125
|
+
}
|
126
|
+
inline void setDoForcing(bool doForcing) {
|
127
|
+
if (doForcing) presolveActions_ &= ~32;
|
128
|
+
else presolveActions_ |= 32;
|
129
|
+
}
|
130
|
+
/// Whether we want to do impliedfree part of presolve
|
131
|
+
inline bool doImpliedFree() const {
|
132
|
+
return (presolveActions_ & 64) == 0;
|
133
|
+
}
|
134
|
+
inline void setDoImpliedFree(bool doImpliedfree) {
|
135
|
+
if (doImpliedfree) presolveActions_ &= ~64;
|
136
|
+
else presolveActions_ |= 64;
|
137
|
+
}
|
138
|
+
/// Whether we want to do dupcol part of presolve
|
139
|
+
inline bool doDupcol() const {
|
140
|
+
return (presolveActions_ & 128) == 0;
|
141
|
+
}
|
142
|
+
inline void setDoDupcol(bool doDupcol) {
|
143
|
+
if (doDupcol) presolveActions_ &= ~128;
|
144
|
+
else presolveActions_ |= 128;
|
145
|
+
}
|
146
|
+
/// Whether we want to do duprow part of presolve
|
147
|
+
inline bool doDuprow() const {
|
148
|
+
return (presolveActions_ & 256) == 0;
|
149
|
+
}
|
150
|
+
inline void setDoDuprow(bool doDuprow) {
|
151
|
+
if (doDuprow) presolveActions_ &= ~256;
|
152
|
+
else presolveActions_ |= 256;
|
153
|
+
}
|
154
|
+
/// Whether we want to do dependency part of presolve
|
155
|
+
inline bool doDependency() const {
|
156
|
+
return (presolveActions_ & 32768) != 0;
|
157
|
+
}
|
158
|
+
inline void setDoDependency(bool doDependency) {
|
159
|
+
if (doDependency) presolveActions_ |= 32768;
|
160
|
+
else presolveActions_ &= ~32768;
|
161
|
+
}
|
162
|
+
/// Whether we want to do singleton column part of presolve
|
163
|
+
inline bool doSingletonColumn() const {
|
164
|
+
return (presolveActions_ & 512) == 0;
|
165
|
+
}
|
166
|
+
inline void setDoSingletonColumn(bool doSingleton) {
|
167
|
+
if (doSingleton) presolveActions_ &= ~512;
|
168
|
+
else presolveActions_ |= 512;
|
169
|
+
}
|
170
|
+
/// Whether we want to do gubrow part of presolve
|
171
|
+
inline bool doGubrow() const {
|
172
|
+
return (presolveActions_ & 1024) == 0;
|
173
|
+
}
|
174
|
+
inline void setDoGubrow(bool doGubrow) {
|
175
|
+
if (doGubrow) presolveActions_ &= ~1024;
|
176
|
+
else presolveActions_ |= 1024;
|
177
|
+
}
|
178
|
+
/// Whether we want to do twoxtwo part of presolve
|
179
|
+
inline bool doTwoxTwo() const {
|
180
|
+
return (presolveActions_ & 2048) != 0;
|
181
|
+
}
|
182
|
+
inline void setDoTwoxtwo(bool doTwoxTwo) {
|
183
|
+
if (!doTwoxTwo) presolveActions_ &= ~2048;
|
184
|
+
else presolveActions_ |= 2048;
|
185
|
+
}
|
186
|
+
/// Whether we want to allow duplicate intersections
|
187
|
+
inline bool doIntersection() const {
|
188
|
+
return (presolveActions_ & 4096) != 0;
|
189
|
+
}
|
190
|
+
inline void setDoIntersection(bool doIntersection) {
|
191
|
+
if (doIntersection) presolveActions_ &= ~4096;
|
192
|
+
else presolveActions_ |= 4096;
|
193
|
+
}
|
194
|
+
/** How much we want to zero small values from aggregation - ratio
|
195
|
+
0 - 1.0e-12, 1 1.0e-11, 2 1.0e-10, 3 1.0e-9 */
|
196
|
+
inline int zeroSmall() const {
|
197
|
+
return (presolveActions_&(8192|16384))>>13;
|
198
|
+
}
|
199
|
+
inline void setZeroSmall(int value) {
|
200
|
+
presolveActions_ &= ~(8192|16384);
|
201
|
+
presolveActions_ |= value<<13;
|
202
|
+
}
|
203
|
+
/// Set whole group
|
204
|
+
inline int presolveActions() const {
|
205
|
+
return presolveActions_ & 0xffff;
|
206
|
+
}
|
207
|
+
inline void setPresolveActions(int action) {
|
208
|
+
presolveActions_ = (presolveActions_ & 0xffff0000) | (action & 0xffff);
|
209
|
+
}
|
210
|
+
/// Substitution level
|
211
|
+
inline void setSubstitution(int value) {
|
212
|
+
substitution_ = value;
|
213
|
+
}
|
214
|
+
/// Asks for statistics
|
215
|
+
inline void statistics() {
|
216
|
+
presolveActions_ |= 0x80000000;
|
217
|
+
}
|
218
|
+
/// Return presolve status (0,1,2)
|
219
|
+
int presolveStatus() const;
|
220
|
+
|
221
|
+
/**@name postsolve - postsolve the problem. If the problem
|
222
|
+
has not been solved to optimality, there are no guarantees.
|
223
|
+
If you are using an algorithm like simplex that has a concept
|
224
|
+
of "basic" rows/cols, then set updateStatus
|
225
|
+
|
226
|
+
Note that if you modified the original problem after presolving,
|
227
|
+
then you must ``undo'' these modifications before calling postsolve.
|
228
|
+
This version updates original*/
|
229
|
+
virtual void postsolve(bool updateStatus = true);
|
230
|
+
|
231
|
+
/// Gets rid of presolve actions (e.g.when infeasible)
|
232
|
+
void destroyPresolve();
|
233
|
+
|
234
|
+
/**@name private or protected data */
|
235
|
+
private:
|
236
|
+
/// Original model - must not be destroyed before postsolve
|
237
|
+
ClpSimplex * originalModel_;
|
238
|
+
|
239
|
+
/// ClpPresolved model - up to user to destroy by deleteClpPresolvedModel
|
240
|
+
ClpSimplex * presolvedModel_;
|
241
|
+
/** "Magic" number. If this is non-zero then any elements with this value
|
242
|
+
may change and so presolve is very limited in what can be done
|
243
|
+
to the row and column. This is for non-linear problems.
|
244
|
+
One could also allow for cases where sign of coefficient is known.
|
245
|
+
*/
|
246
|
+
double nonLinearValue_;
|
247
|
+
/// Original column numbers
|
248
|
+
int * originalColumn_;
|
249
|
+
/// Original row numbers
|
250
|
+
int * originalRow_;
|
251
|
+
/// Row objective
|
252
|
+
double * rowObjective_;
|
253
|
+
/// The list of transformations applied.
|
254
|
+
const CoinPresolveAction *paction_;
|
255
|
+
|
256
|
+
/// The postsolved problem will expand back to its former size
|
257
|
+
/// as postsolve transformations are applied.
|
258
|
+
/// It is efficient to allocate data structures for the final size
|
259
|
+
/// of the problem rather than expand them as needed.
|
260
|
+
/// These fields give the size of the original problem.
|
261
|
+
int ncols_;
|
262
|
+
int nrows_;
|
263
|
+
CoinBigIndex nelems_;
|
264
|
+
/// Number of major passes
|
265
|
+
int numberPasses_;
|
266
|
+
/// Substitution level
|
267
|
+
int substitution_;
|
268
|
+
#ifndef CLP_NO_STD
|
269
|
+
/// Name of saved model file
|
270
|
+
std::string saveFile_;
|
271
|
+
#endif
|
272
|
+
/** Whether we want to skip dual part of presolve etc.
|
273
|
+
512 bit allows duplicate column processing on integer columns
|
274
|
+
and dual stuff on integers
|
275
|
+
*/
|
276
|
+
int presolveActions_;
|
277
|
+
protected:
|
278
|
+
/// If you want to apply the individual presolve routines differently,
|
279
|
+
/// or perhaps add your own to the mix,
|
280
|
+
/// define a derived class and override this method
|
281
|
+
virtual const CoinPresolveAction *presolve(CoinPresolveMatrix *prob);
|
282
|
+
|
283
|
+
/// Postsolving is pretty generic; just apply the transformations
|
284
|
+
/// in reverse order.
|
285
|
+
/// You will probably only be interested in overriding this method
|
286
|
+
/// if you want to add code to test for consistency
|
287
|
+
/// while debugging new presolve techniques.
|
288
|
+
virtual void postsolve(CoinPostsolveMatrix &prob);
|
289
|
+
/** This is main part of Presolve */
|
290
|
+
virtual ClpSimplex * gutsOfPresolvedModel(ClpSimplex * originalModel,
|
291
|
+
double feasibilityTolerance,
|
292
|
+
bool keepIntegers,
|
293
|
+
int numberPasses,
|
294
|
+
bool dropNames,
|
295
|
+
bool doRowObjective,
|
296
|
+
const char * prohibitedRows=NULL,
|
297
|
+
const char * prohibitedColumns=NULL);
|
298
|
+
};
|
299
|
+
#endif
|
@@ -0,0 +1,72 @@
|
|
1
|
+
/* $Id: ClpPrimalColumnDantzig.hpp 1665 2011-01-04 17:55:54Z lou $ */
|
2
|
+
// Copyright (C) 2002, International Business Machines
|
3
|
+
// Corporation and others. All Rights Reserved.
|
4
|
+
// This code is licensed under the terms of the Eclipse Public License (EPL).
|
5
|
+
|
6
|
+
#ifndef ClpPrimalColumnDantzig_H
|
7
|
+
#define ClpPrimalColumnDantzig_H
|
8
|
+
|
9
|
+
#include "ClpPrimalColumnPivot.hpp"
|
10
|
+
|
11
|
+
//#############################################################################
|
12
|
+
|
13
|
+
/** Primal Column Pivot Dantzig Algorithm Class
|
14
|
+
|
15
|
+
This is simplest choice - choose largest infeasibility
|
16
|
+
|
17
|
+
*/
|
18
|
+
|
19
|
+
class ClpPrimalColumnDantzig : public ClpPrimalColumnPivot {
|
20
|
+
|
21
|
+
public:
|
22
|
+
|
23
|
+
///@name Algorithmic methods
|
24
|
+
//@{
|
25
|
+
|
26
|
+
/** Returns pivot column, -1 if none.
|
27
|
+
Lumbers over all columns - slow
|
28
|
+
The Packed CoinIndexedVector updates has cost updates - for normal LP
|
29
|
+
that is just +-weight where a feasibility changed. It also has
|
30
|
+
reduced cost from last iteration in pivot row
|
31
|
+
Can just do full price if you really want to be slow
|
32
|
+
*/
|
33
|
+
virtual int pivotColumn(CoinIndexedVector * updates,
|
34
|
+
CoinIndexedVector * spareRow1,
|
35
|
+
CoinIndexedVector * spareRow2,
|
36
|
+
CoinIndexedVector * spareColumn1,
|
37
|
+
CoinIndexedVector * spareColumn2);
|
38
|
+
|
39
|
+
/// Just sets model
|
40
|
+
virtual void saveWeights(ClpSimplex * model, int) {
|
41
|
+
model_ = model;
|
42
|
+
}
|
43
|
+
//@}
|
44
|
+
|
45
|
+
|
46
|
+
///@name Constructors and destructors
|
47
|
+
//@{
|
48
|
+
/// Default Constructor
|
49
|
+
ClpPrimalColumnDantzig();
|
50
|
+
|
51
|
+
/// Copy constructor
|
52
|
+
ClpPrimalColumnDantzig(const ClpPrimalColumnDantzig &);
|
53
|
+
|
54
|
+
/// Assignment operator
|
55
|
+
ClpPrimalColumnDantzig & operator=(const ClpPrimalColumnDantzig& rhs);
|
56
|
+
|
57
|
+
/// Destructor
|
58
|
+
virtual ~ClpPrimalColumnDantzig ();
|
59
|
+
|
60
|
+
/// Clone
|
61
|
+
virtual ClpPrimalColumnPivot * clone(bool copyData = true) const;
|
62
|
+
|
63
|
+
//@}
|
64
|
+
|
65
|
+
//---------------------------------------------------------------------------
|
66
|
+
|
67
|
+
private:
|
68
|
+
///@name Private member data
|
69
|
+
//@}
|
70
|
+
};
|
71
|
+
|
72
|
+
#endif
|
@@ -0,0 +1,155 @@
|
|
1
|
+
/* $Id: ClpPrimalColumnPivot.hpp 1732 2011-05-31 08:09:41Z forrest $ */
|
2
|
+
// Copyright (C) 2002, International Business Machines
|
3
|
+
// Corporation and others. All Rights Reserved.
|
4
|
+
// This code is licensed under the terms of the Eclipse Public License (EPL).
|
5
|
+
|
6
|
+
#ifndef ClpPrimalcolumnPivot_H
|
7
|
+
#define ClpPrimalcolumnPivot_H
|
8
|
+
|
9
|
+
class ClpSimplex;
|
10
|
+
class CoinIndexedVector;
|
11
|
+
|
12
|
+
//#############################################################################
|
13
|
+
|
14
|
+
/** Primal Column Pivot Abstract Base Class
|
15
|
+
|
16
|
+
Abstract Base Class for describing an interface to an algorithm
|
17
|
+
to choose column pivot in primal simplex algorithm. For some algorithms
|
18
|
+
e.g. Dantzig choice then some functions may be null. For Dantzig
|
19
|
+
the only one of any importance is pivotColumn.
|
20
|
+
|
21
|
+
If you wish to inherit from this look at ClpPrimalColumnDantzig.cpp
|
22
|
+
as that is simplest version.
|
23
|
+
*/
|
24
|
+
|
25
|
+
class ClpPrimalColumnPivot {
|
26
|
+
|
27
|
+
public:
|
28
|
+
|
29
|
+
///@name Algorithmic methods
|
30
|
+
//@{
|
31
|
+
|
32
|
+
/** Returns pivot column, -1 if none
|
33
|
+
|
34
|
+
Normally updates reduced costs using result of last iteration
|
35
|
+
before selecting incoming column.
|
36
|
+
|
37
|
+
The Packed CoinIndexedVector updates has cost updates - for normal LP
|
38
|
+
that is just +-weight where a feasibility changed. It also has
|
39
|
+
reduced cost from last iteration in pivot row
|
40
|
+
|
41
|
+
Inside pivotColumn the pivotRow_ and reduced cost from last iteration
|
42
|
+
are also used.
|
43
|
+
|
44
|
+
So in the simplest case i.e. feasible we compute the row of the
|
45
|
+
tableau corresponding to last pivot and add a multiple of this
|
46
|
+
to current reduced costs.
|
47
|
+
|
48
|
+
We can use other arrays to help updates
|
49
|
+
*/
|
50
|
+
virtual int pivotColumn(CoinIndexedVector * updates,
|
51
|
+
CoinIndexedVector * spareRow1,
|
52
|
+
CoinIndexedVector * spareRow2,
|
53
|
+
CoinIndexedVector * spareColumn1,
|
54
|
+
CoinIndexedVector * spareColumn2) = 0;
|
55
|
+
|
56
|
+
/// Updates weights - part 1 (may be empty)
|
57
|
+
virtual void updateWeights(CoinIndexedVector * input);
|
58
|
+
|
59
|
+
/** Saves any weights round factorization as pivot rows may change
|
60
|
+
Will be empty unless steepest edge (will save model)
|
61
|
+
May also recompute infeasibility stuff
|
62
|
+
1) before factorization
|
63
|
+
2) after good factorization (if weights empty may initialize)
|
64
|
+
3) after something happened but no factorization
|
65
|
+
(e.g. check for infeasible)
|
66
|
+
4) as 2 but restore weights from previous snapshot
|
67
|
+
5) forces some initialization e.g. weights
|
68
|
+
Also sets model
|
69
|
+
*/
|
70
|
+
virtual void saveWeights(ClpSimplex * model, int mode) = 0;
|
71
|
+
/** Signals pivot row choice:
|
72
|
+
-2 (default) - use normal pivot row choice
|
73
|
+
-1 to numberRows-1 - use this (will be checked)
|
74
|
+
way should be -1 to go to lower bound, +1 to upper bound
|
75
|
+
*/
|
76
|
+
virtual int pivotRow(double & way) {
|
77
|
+
way = 0;
|
78
|
+
return -2;
|
79
|
+
}
|
80
|
+
/// Gets rid of all arrays (may be empty)
|
81
|
+
virtual void clearArrays();
|
82
|
+
/// Returns true if would not find any column
|
83
|
+
virtual bool looksOptimal() const {
|
84
|
+
return looksOptimal_;
|
85
|
+
}
|
86
|
+
/// Sets optimality flag (for advanced use)
|
87
|
+
virtual void setLooksOptimal(bool flag) {
|
88
|
+
looksOptimal_ = flag;
|
89
|
+
}
|
90
|
+
//@}
|
91
|
+
|
92
|
+
|
93
|
+
///@name Constructors and destructors
|
94
|
+
//@{
|
95
|
+
/// Default Constructor
|
96
|
+
ClpPrimalColumnPivot();
|
97
|
+
|
98
|
+
/// Copy constructor
|
99
|
+
ClpPrimalColumnPivot(const ClpPrimalColumnPivot &);
|
100
|
+
|
101
|
+
/// Assignment operator
|
102
|
+
ClpPrimalColumnPivot & operator=(const ClpPrimalColumnPivot& rhs);
|
103
|
+
|
104
|
+
/// Destructor
|
105
|
+
virtual ~ClpPrimalColumnPivot ();
|
106
|
+
|
107
|
+
/// Clone
|
108
|
+
virtual ClpPrimalColumnPivot * clone(bool copyData = true) const = 0;
|
109
|
+
|
110
|
+
//@}
|
111
|
+
|
112
|
+
///@name Other
|
113
|
+
//@{
|
114
|
+
/// Returns model
|
115
|
+
inline ClpSimplex * model() {
|
116
|
+
return model_;
|
117
|
+
}
|
118
|
+
/// Sets model
|
119
|
+
inline void setModel(ClpSimplex * newmodel) {
|
120
|
+
model_ = newmodel;
|
121
|
+
}
|
122
|
+
|
123
|
+
/// Returns type (above 63 is extra information)
|
124
|
+
inline int type() {
|
125
|
+
return type_;
|
126
|
+
}
|
127
|
+
|
128
|
+
/** Returns number of extra columns for sprint algorithm - 0 means off.
|
129
|
+
Also number of iterations before recompute
|
130
|
+
*/
|
131
|
+
virtual int numberSprintColumns(int & numberIterations) const;
|
132
|
+
/// Switch off sprint idea
|
133
|
+
virtual void switchOffSprint();
|
134
|
+
/// Called when maximum pivots changes
|
135
|
+
virtual void maximumPivotsChanged() {}
|
136
|
+
|
137
|
+
//@}
|
138
|
+
|
139
|
+
//---------------------------------------------------------------------------
|
140
|
+
|
141
|
+
protected:
|
142
|
+
///@name Protected member data
|
143
|
+
//@{
|
144
|
+
/// Pointer to model
|
145
|
+
ClpSimplex * model_;
|
146
|
+
/// Type of column pivot algorithm
|
147
|
+
int type_;
|
148
|
+
/// Says if looks optimal (normally computed)
|
149
|
+
bool looksOptimal_;
|
150
|
+
//@}
|
151
|
+
};
|
152
|
+
#ifndef CLP_PRIMAL_SLACK_MULTIPLIER
|
153
|
+
#define CLP_PRIMAL_SLACK_MULTIPLIER 1.01
|
154
|
+
#endif
|
155
|
+
#endif
|