- Main Page
- Modules
- Namespaces
- Classes
- Files
- Related Pages

- File List
- File Members

# /home/coin/SVN-release/Blis-0.91.2/CoinUtils/src/CoinPresolveZeros.hpp

Go to the documentation of this file.

    00001 /* $Id: CoinPresolveZeros.hpp 1215 2009-11-05 11:03:04Z forrest $ */
    00002 // Copyright (C) 2002, International Business Machines
    00003 // Corporation and others.  All Rights Reserved.
    00004
    00005 #ifndef CoinPresolveZeros_H
    00006 #define CoinPresolveZeros_H
    00007
    00013 #define DROP_ZERO       8
    00014
    00021 struct dropped_zero {
    00022   int row;
    00023   int col;
    00024 };
    00025
    00031 class drop_zero_coefficients_action : public CoinPresolveAction {
    00032
    00033   const int nzeros_;
    00034   const dropped_zero *const zeros_;
    00035
    00036   drop_zero_coefficients_action(int nzeros,
    00037                                 const dropped_zero *zeros,
    00038                                 const CoinPresolveAction *next) :
    00039     CoinPresolveAction(next),
    00040     nzeros_(nzeros), zeros_(zeros)
    00041 {}
    00042
    00043  public:
    00044   const char *name() const { return ("drop_zero_coefficients_action"); }
    00045
    00046   static const CoinPresolveAction *presolve(CoinPresolveMatrix *prob,
    00047                                          int *checkcols,
    00048                                          int ncheckcols,
    00049                                          const CoinPresolveAction *next);
    00050
    00051   void postsolve(CoinPostsolveMatrix *prob) const;
    00052
    00053   ~drop_zero_coefficients_action() { deleteAction(zeros_,dropped_zero*); }
    00054 };
    00055
    00056 const CoinPresolveAction *drop_zero_coefficients(CoinPresolveMatrix *prob,
    00057                                               const CoinPresolveAction *next);
    00058
    00059 #endif