示例#1
0
文件: SolverLP.cs 项目: say1981/Rawr
 private void SolveInternal()
 {
     if (compactSolution == null)
     {
         if (needsDual)
         {
             //System.Diagnostics.Trace.WriteLine("Solving " + Log.ToString());
             //System.Diagnostics.Debug.WriteLine("Solving H=" + HeroismHash.ToString("X") + ", AP=" + APHash.ToString("X") + ", IV=" + IVHash.ToString("X"));
             compactSolution = lp.SolveDual(false);
         }
         else
         {
             compactSolution = lp.SolvePrimal(false);
             //compactSolution = lp.SolveDual(true);
         }
         UnscaleSolution();
     }
 }
示例#2
0
文件: SolverLP.cs 项目: rakot/rawr
 private void SolveInternal()
 {
     if (compactSolution == null)
     {
         if (needsQuadratic)
         {
             compactSolution = lp.SolvePrimalQuadratic(mpsRow, sort, Qk, needsDual, maximizeColumn, targetValue, solver.CalculationOptions.GlobalRestarts);
         }
         else if (needsDual)
         {
             //System.Diagnostics.Trace.WriteLine("Solving " + Log.ToString());
             //System.Diagnostics.Debug.WriteLine("Solving H=" + HeroismHash.ToString("X") + ", AP=" + APHash.ToString("X") + ", IV=" + IVHash.ToString("X"));
             compactSolution = lp.SolveDual(false);
         }
         else
         {
             compactSolution = lp.SolvePrimal(false);
             //compactSolution = lp.SolveDual(true);
         }
         UnscaleSolution();
     }
 }