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

- File List
- File Members

# /home/coin/SVN-release/Vol-1.2.0/Osi/src/OsiCommonTest/OsiUnitTests.hpp File Reference

`#include <string>`
`#include <vector>`

Include dependency graph for OsiUnitTests.hpp:

Go to the source code of this file.

## Namespaces
namespace | OsiUnitTest
## Functions
int | OsiSolverInterfaceMpsUnitTest (const std::vector< OsiSolverInterface * > &vecEmptySiP, const std::string &mpsDir)
| A function that tests that a lot of problems given in MPS files (mostly the NETLIB problems) solve properly with all the specified solvers.
int | OsiSolverInterfaceCommonUnitTest (const OsiSolverInterface *emptySi, const std::string &mpsDir, const std::string &netlibDir)
void | OsiCutsUnitTest ()
void | OsiColCutUnitTest (const OsiSolverInterface *baseSiP, const std::string &mpsDir)
void | OsiRowCutUnitTest (const OsiSolverInterface *baseSiP, const std::string &mpsDir)
void | OsiRowCutDebuggerUnitTest (const OsiSolverInterface *baseSiP, const std::string &mpsDir)
int | testSimplexAPI (const OsiSolverInterface *emptySi, const std::string &mpsDir)
void | OsiUnitTest::failureMessage (const std::string &solverName, const std::string &message)
void | OsiUnitTest::failureMessage (const OsiSolverInterface &si, const std::string &message)
void | OsiUnitTest::testingMessage (const char *const msg)
bool | OsiUnitTest::equivalentVectors (const OsiSolverInterface *si1, const OsiSolverInterface *si2, double tol, const double *v1, const double *v2, int size)
bool | OsiUnitTest::compareProblems (OsiSolverInterface *osi1, OsiSolverInterface *osi2)
bool | OsiUnitTest::isEquivalent (const CoinPackedVectorBase &pv, int n, const double *fv)

## Function Documentation

int OsiSolverInterfaceMpsUnitTest | ( | const std::vector< OsiSolverInterface * > & | vecEmptySiP,
|  | const std::string & | mpsDir |
| ) |  |  |

A function that tests that a lot of problems given in MPS files (mostly the NETLIB problems) solve properly with all the specified solvers.

The routine creates a vector of NetLib problems (problem name, objective, various other characteristics), and a vector of solvers to be tested.

Each solver is run on each problem. The run is deemed successful if the solver reports the correct problem size after loading and returns the correct objective value after optimization.

If multiple solvers are available, the results are compared pairwise against the results reported by adjacent solvers in the solver vector. Due to limitations of the volume solver, it must be the last solver in vecEmptySiP.

int OsiSolverInterfaceCommonUnitTest | ( | const OsiSolverInterface * | emptySi,
|  | const std::string & | mpsDir,
|  | const std::string & | netlibDir |
| ) |  |  |

The only reason for it not to be a member method is that this way it doesn't have to be compiled into the library. And that's a gain, because the library should be compiled with optimization on, but this method should be compiled with debugging. Also, if this method is compiled with optimization, the compilation takes 10-15 minutes and the machine pages (has 256M core memory!)...

void OsiCutsUnitTest | ( |  | ) |

The only reason for it not to be a member method is that this way it doesn't have to be compiled into the library. And that's a gain, because the library should be compiled with optimization on, but this method should be compiled with debugging.

void OsiColCutUnitTest | ( | const OsiSolverInterface * | baseSiP,
|  | const std::string & | mpsDir |
| ) |  |  |

The only reason for it not to be a member method is that this way it doesn't have to be compiled into the library. And that's a gain, because the library should be compiled with optimization on, but this method should be compiled with debugging.

void OsiRowCutUnitTest | ( | const OsiSolverInterface * | baseSiP,
|  | const std::string & | mpsDir |
| ) |  |  |

The only reason for it not to be a member method is that this way it doesn't have to be compiled into the library. And that's a gain, because the library should be compiled with optimization on, but this method should be compiled with debugging.

void OsiRowCutDebuggerUnitTest | ( | const OsiSolverInterface * | baseSiP,
|  | const std::string & | mpsDir |
| ) |  |  |

The only reason for it not to be a member method is that this way it doesn't have to be compiled into the library. And that's a gain, because the library should be compiled with optimization on, but this method should be compiled with debugging.

int testSimplexAPI | ( | const OsiSolverInterface * | emptySi,
|  | const std::string & | mpsDir |
| ) |  |  |