Cgl
0.60.10
Toggle main menu visibility
Loading...
Searching...
No Matches
Cgl
src
CglLandP
CglLandPTabRow.hpp
Go to the documentation of this file.
1
// Copyright (C) 2005-2009, Pierre Bonami and others. All Rights Reserved.
2
// Author: Pierre Bonami
3
// LIF
4
// CNRS, Aix-Marseille Universites
5
// Date: 02/23/08
6
//
7
// $Id$
8
//
9
// This code is licensed under the terms of the Eclipse Public License (EPL).
10
//---------------------------------------------------------------------------
11
12
#ifndef CglLandPTabRow_H
13
#define CglLandPTabRow_H
14
15
#include "CoinIndexedVector.hpp"
16
#include <iostream>
17
18
namespace
LAP
19
{
20
class
CglLandPSimplex
;
21
struct
TabRow
:
public
CoinIndexedVector
22
{
24
int
num
;
26
double
rhs
;
28
const
CglLandPSimplex
*
si_
;
29
31
bool
modularized_
;
32
33
TabRow
():
34
CoinIndexedVector(),
si_
(NULL),
modularized_
(false) {}
35
36
TabRow
(
const
CglLandPSimplex
*si):
37
CoinIndexedVector(),
num
(-1),
rhs
(0),
si_
(si),
modularized_
(false) {}
38
39
TabRow
(
const
TabRow
& source):CoinIndexedVector(source),
40
num
(source.
num
),
rhs
(source.
rhs
),
si_
(source.
si_
)
41
{
42
}
43
44
TabRow
&
operator=
(
const
TabRow
& r)
45
{
46
if
(
this
!= &r)
47
{
48
CoinIndexedVector::operator=(r);
49
num
= r.
num
;
50
rhs
= r.
rhs
;
51
si_
= r.
si_
;
52
}
53
return
*
this
;
54
}
55
56
bool
operator==
(
const
TabRow
&r)
const
;
57
~TabRow
()
58
{
59
}
60
61
void
modularize
(
const
bool
* integerVar);
62
63
void
print
(std::ostream & os,
int
width = 9,
const
int
* nonBasics = NULL,
64
int
m = 0);
65
inline
66
const
double
&
operator[]
(
const
int
&index)
const
67
{
68
return
denseVector()[index];
69
}
70
71
inline
72
double
&
operator[]
(
const
int
&index)
73
{
74
return
denseVector()[index];
75
}
76
};
77
}
/* Ends LAP Namespace.*/
78
79
#endif
80
LAP::CglLandPSimplex
Definition
CglLandPSimplex.hpp:43
LAP
Performs one round of Lift & Project using CglLandPSimplex to build cuts.
Definition
CglLandP.hpp:25
LAP::TabRow::modularized_
bool modularized_
Flag to say if row is modularized.
Definition
CglLandPTabRow.hpp:31
LAP::TabRow::~TabRow
~TabRow()
Definition
CglLandPTabRow.hpp:57
LAP::TabRow::si_
const CglLandPSimplex * si_
Row of what?
Definition
CglLandPTabRow.hpp:28
LAP::TabRow::operator==
bool operator==(const TabRow &r) const
LAP::TabRow::rhs
double rhs
Row right-hand-side.
Definition
CglLandPTabRow.hpp:26
LAP::TabRow::operator[]
const double & operator[](const int &index) const
Definition
CglLandPTabRow.hpp:66
LAP::TabRow::modularize
void modularize(const bool *integerVar)
LAP::TabRow::operator=
TabRow & operator=(const TabRow &r)
Definition
CglLandPTabRow.hpp:44
LAP::TabRow::operator[]
double & operator[](const int &index)
Definition
CglLandPTabRow.hpp:72
LAP::TabRow::num
int num
Row number.
Definition
CglLandPTabRow.hpp:24
LAP::TabRow::print
void print(std::ostream &os, int width=9, const int *nonBasics=NULL, int m=0)
LAP::TabRow::TabRow
TabRow(const CglLandPSimplex *si)
Definition
CglLandPTabRow.hpp:36
LAP::TabRow::TabRow
TabRow()
Definition
CglLandPTabRow.hpp:33
LAP::TabRow::TabRow
TabRow(const TabRow &source)
Definition
CglLandPTabRow.hpp:39
Generated by
1.17.0