source: html/trunk/Clp/userguide/ch02s07.html @ 956

Last change on this file since 956 was 956, checked in by ddelanu, 16 years ago

First revision of user guide

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 6.4 KB
1<html><head><meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><title>
2  Simplex-specific Methods
3  </title><meta name="generator" content="DocBook XSL Stylesheets V1.65.1"><link rel="home" href="index.html" title="CLP User Manual"><link rel="up" href="ch02.html" title="Chapter 2. 
4  Basic Model Classes
5  "><link rel="previous" href="ch02s06.html" title="Some Useful Set and Get Methods"><link rel="next" href="ch02s08.html" title="
6  Presolve
7  "></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">
8  Simplex-specific Methods
9  </th></tr><tr><td width="20%" align="left"><a accesskey="p" href="ch02s06.html">Prev</a> </td><th width="60%" align="center">Chapter 2. 
10  Basic Model Classes
11  </th><td width="20%" align="right"> <a accesskey="n" href="ch02s08.html">Next</a></td></tr></table><hr></div><div class="section" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="id4758869"></a>
12  Simplex-specific Methods
13  </h2></div></div><div></div></div><p>
14  Some of the most commonly-used methods when working with Simplex are listed in
15  the table below.
16  </p><div class="table"><a name="id4758879"></a><p class="title"><b>Table 2.3. Common Simplex-specific methods</b></p><table summary="Common Simplex-specific methods" border="0"><colgroup><col><col></colgroup><thead><tr><th>
17    Method(s)
18    </th><th>
19    Description
20    </th></tr></thead><tbody><tr><td align="left" valign="top"><tt class="function">primal(int mode=0)</tt></td><td align="left" valign="top">
21      This applies the primal algorithm. If <i class="parameter"><tt>mode</tt></i> is
22      set to the default of 0, then the method uses the status variables to
23      determine basis and solution. If <i class="parameter"><tt>mode</tt></i> is 1 then
24      the method does a values pass so variables not in basis are given their
25      current values and one pass of variables is done to clean up the basis
26      with an equal or better objective value.
27      </td></tr><tr><td align="left" valign="top"><tt class="function">dual(int mode=0)</tt></td><td align="left" valign="top">
28      This applies the dual algorithm. if <i class="parameter"><tt>mode</tt></i> is set
29      to the default of 0, then the method uses the status variables to
30      determine basis and solution.  If <i class="parameter"><tt>mode</tt></i> is 1 then
31      the method uses input duals and does a values pass so one pass of basic
32      variables is done to clean up the duals with an equal or better objective
33      value.
34      </td></tr><tr><td align="left" valign="top"><tt class="function">scaling(int mode=1)</tt></td><td align="left" valign="top">
35      This method toggles scaling on (<i class="parameter"><tt>mode</tt></i> set to 1)
36      and off (<i class="parameter"><tt>mode</tt></i> set to 0).
37      </td></tr><tr><td align="left" valign="top"><tt class="function">int crash(double gap,int mode)</tt></td><td align="left" valign="top">
38      This method attemps to improve on an all slack basis.
39      For dual this will move variables to the dual feasible bound
40      if the gap between bounds is less than <i class="parameter"><tt>gap</tt></i>.  Setting
41      <i class="parameter"><tt>mode</tt></i> to 0 guesses which algorithm is better, while
42      a value of 1 or 2 will result in more work being done.  The return code is
43      0 if the basis was not slacks in first case, it is negative if dual is
44      preferred or positive if primal.  ±1 means an all slack basis seemed
45      best, while ±2 means some work was done.
46      </td></tr><tr><td align="left" valign="top"><tt class="function">perturb(int mode)</tt></td><td align="left" valign="top">
47      This method toggles perturbation on (<i class="parameter"><tt>mode</tt></i> set to 1)
48      and off (<i class="parameter"><tt>mode</tt></i> set to 0).  It should be considered
49      a work in progress, although on some problems it gives very good results.
50      </td></tr><tr><td align="left" valign="top"><tt class="function">factorizationFrequency()</tt><br><tt class="function">setFactorizationFrequency(int value)</tt></td><td align="left" valign="top">
51      These are "get" and "set" methods for the basis matrix
52      factorization frequency.  The default is to refactor every 200 iterations,
53      but it may make more sense to use something such as 100 + the number of
54      rows divided by 50.
55      </td></tr><tr><td align="left" valign="top"><tt class="function">dualBound()</tt><br><tt class="function">setDualBound(double value)</tt></td><td align="left" valign="top">
56      These are "get" and "set" methods for the
57      "dual bound".  The CLP dual algorithm declares all problems
58      to be dual feasible by putting non-basic variables to correct bounds for
59      the reduced cost.  If the gap between the bounds is too big then it
60      pretends the gap is only the value specified by this set method.
61      In essence, this gives a composite dual rather than a pure
62      Phase I- Phase II method.
63      </td></tr><tr><td align="left" valign="top"><tt class="function">infeasibilityCost()</tt><br><tt class="function">setInfeasibilityCost(double value)</tt></td><td align="left" valign="top">
64      These are the primal analogs to the "dual bound" methods.
65      </td></tr><tr><td align="left" valign="top"><tt class="function">numberPrimalInfeasibilities()</tt><br><tt class="function">sumPrimalInfeasibilities()</tt></td><td align="left" valign="top">
66      After a solve, there may be infeasibilities.  These methods serve to
67      check for said infeasibilities.  One could check the solution explicitly
68      as well.  For a code fragement illustrating this, see
69      <a href="ch02s08.html#presolveexample" title="Example 2.3. Presolve code fragment">Example 2.3, &#8220;Presolve code fragment&#8221;</a>.
70      </td></tr></tbody></table></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="ch02s06.html">Prev</a> </td><td width="20%" align="center"><a accesskey="u" href="ch02.html">Up</a></td><td width="40%" align="right"> <a accesskey="n" href="ch02s08.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">Some Useful Set and Get Methods </td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right" valign="top"> 
71  Presolve
72  </td></tr></table></div></body></html>
Note: See TracBrowser for help on using the repository browser.