1/* $Id: CoinPresolveDual.hpp 1372 2011-01-03 23:31:00Z lou $ */
2
3// Copyright (C) 2002, International Business Machines
4// Corporation and others. All Rights Reserved.
5// This code is licensed under the terms of the Eclipse Public License (EPL).
6
7#ifndef CoinPresolveDual_H
8#define CoinPresolveDual_H
9
10/*! \class remove_dual_action
11 \brief Attempt to fix variables by bounding reduced costs
12
13 The reduced cost of x_j is d_j = c_j - y*a_j (1). Assume minimization,
14 so that at optimality d_j >= 0 for x_j nonbasic at lower bound, and
15 d_j <= 0 for x_j nonbasic at upper bound.
16
17 For a slack variable s_i, c_(n+i) = 0 and a_(n+i) is a unit vector, hence
18 d_(n+i) = -y_i. If s_i has a finite lower bound and no upper bound, we
19 must have y_i <= 0 at optimality. Similarly, if s_i has no lower bound and a
20 finite upper bound, we must have y_i >= 0.
21
22 For a singleton variable x_j, d_j = c_j - y_i*a_ij. Given x_j with a
23 single finite bound, we can bound d_j greater or less than 0 at
24 optimality, and that allows us to calculate an upper or lower bound on y_i
25 (depending on the bound on d_j and the sign of a_ij).
26
27 Now we have bounds on some subset of the y_i, and we can use these to
28 calculate upper and lower bounds on the d_j, using bound propagation on
29 (1). If we can manage to bound some d_j as strictly positive or strictly
30 negative, then at optimality the corresponding variable must be nonbasic
31 at its lower or upper bound, respectively. If the required bound is lacking,
32 the problem is unbounded.
33
34 There is no postsolve object specific to remove_dual_action, but execution
35 will queue postsolve actions for any variables that are fixed.
36*/
37
38class remove_dual_action : public CoinPresolveAction {
39 public:
40 remove_dual_action(int nactions,
41 //const action *actions,
42 const CoinPresolveAction *next);
43/*! \brief Attempt to fix variables by bounding reduced costs
44
45 Always scans all variables. Propagates bounds on reduced costs until there's
46 no change or until some set of variables can be fixed.
47*/
48 static const CoinPresolveAction *presolve(CoinPresolveMatrix *prob,
49 const CoinPresolveAction *next);
50};
51#endif
52