Scippy

SoPlex

Sequential object-oriented simPlex

spxdefaultrt.h
Go to the documentation of this file.
1 /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
2 /* */
3 /* This file is part of the class library */
4 /* SoPlex --- the Sequential object-oriented simPlex. */
5 /* */
6 /* Copyright (C) 1996-2019 Konrad-Zuse-Zentrum */
7 /* fuer Informationstechnik Berlin */
8 /* */
9 /* SoPlex is distributed under the terms of the ZIB Academic Licence. */
10 /* */
11 /* You should have received a copy of the ZIB Academic License */
12 /* along with SoPlex; see the file COPYING. If not email to soplex@zib.de. */
13 /* */
14 /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
15 
16 /**@file spxdefaultrt.h
17  * @brief Textbook ratio test for SoPlex.
18  */
19 #ifndef _SPXDEFAULTRT_H_
20 #define _SPXDEFAULTRT_H_
21 
22 
23 #include <assert.h>
24 
25 #include "soplex/spxdefines.h"
26 #include "soplex/spxratiotester.h"
27 
28 namespace soplex
29 {
30 
31 /**@brief Textbook ratio test for SoPlex.
32  @ingroup Algo
33 
34  Class SPxDefaultRT provides an implementation of the textbook ratio test
35  as a derived class of SPxRatioTester. This class is not intended for
36  reliably solving LPs (even though it does the job for ``numerically simple''
37  LPs). Instead, it should serve as a demonstration of how to write ratio
38  tester classes.
39 
40  See SPxRatioTester for a class documentation.
41 */
43 {
44 public:
45 
46  //-------------------------------------
47  /**@name Construction / destruction */
48  //@{
49  /// default constructor
51  : SPxRatioTester("Default")
52  {}
53  /// copy constructor
55  : SPxRatioTester(old)
56  {}
57  /// assignment operator
59  {
60  if(this != &rhs)
61  {
63  }
64 
65  return *this;
66  }
67  /// destructor
68  virtual ~SPxDefaultRT()
69  {}
70  /// clone function for polymorphism
71  inline virtual SPxRatioTester* clone() const
72  {
73  return new SPxDefaultRT(*this);
74  }
75  //@}
76 
77  //-------------------------------------
78  /**@name Select enter/leave */
79  //@{
80  ///
81  virtual int selectLeave(Real& val, Real, bool);
82  ///
83  virtual SPxId selectEnter(Real& val, int, bool);
84 };
85 
86 } // namespace soplex
87 #endif // _SPXDEFAULTRT_H_
virtual int selectLeave(Real &val, Real, bool)
Abstract ratio test base class.
Abstract ratio test base class.Class SPxRatioTester is the virtual base class for computing the ratio...
virtual SPxId selectEnter(Real &val, int, bool)
Generic Ids for LP rows or columns.Both SPxColIds and SPxRowIds may be treated uniformly as SPxIds: ...
Definition: spxid.h:85
double Real
Definition: spxdefines.h:218
virtual SPxRatioTester * clone() const
clone function for polymorphism
Definition: spxdefaultrt.h:71
SPxRatioTester & operator=(const SPxRatioTester &rhs)
assignment operator
SPxDefaultRT(const SPxDefaultRT &old)
copy constructor
Definition: spxdefaultrt.h:54
SPxDefaultRT()
default constructor
Definition: spxdefaultrt.h:50
virtual ~SPxDefaultRT()
destructor
Definition: spxdefaultrt.h:68
Debugging, floating point type and parameter definitions.
Everything should be within this namespace.
Textbook ratio test for SoPlex.Class SPxDefaultRT provides an implementation of the textbook ratio te...
Definition: spxdefaultrt.h:42
SPxDefaultRT & operator=(const SPxDefaultRT &rhs)
assignment operator
Definition: spxdefaultrt.h:58