Clp 1.16.9
Loading...
Searching...
No Matches
ClpNetworkBasis.hpp
Go to the documentation of this file.
1/* $Id: ClpNetworkBasis.hpp 1722 2011-04-17 09:58:37Z stefan $ */
2// Copyright (C) 2003, International Business Machines
3// Corporation and others. All Rights Reserved.
4// This code is licensed under the terms of the Eclipse Public License (EPL).
5/*
6 Authors
7
8 John Forrest
9
10 */
11#ifndef ClpNetworkBasis_H
12#define ClpNetworkBasis_H
13
14class ClpMatrixBase;
15class CoinIndexedVector;
16class ClpSimplex;
17#include "CoinTypes.hpp"
18#ifndef COIN_FAST_CODE
19#define COIN_FAST_CODE
20#endif
21
27
28public:
29
36 int numberRows, const CoinFactorizationDouble * pivotRegion,
37 const int * permuteBack, const CoinBigIndex * startColumn,
38 const int * numberInColumn,
39 const int * indexRow, const CoinFactorizationDouble * element);
42
48
59 int factorize ( const ClpMatrixBase * matrix,
60 int rowIsBasic[], int columnIsBasic[]);
62
65
69 int replaceColumn ( CoinIndexedVector * column,
70 int pivotRow);
72
79 double updateColumn ( CoinIndexedVector * regionSparse,
80 CoinIndexedVector * regionSparse2,
81 int pivotRow);
87 int updateColumn ( CoinIndexedVector * regionSparse,
88 double array[] ) const;
95 int updateColumnTranspose ( CoinIndexedVector * regionSparse,
96 double array[] ) const;
98 int updateColumnTranspose ( CoinIndexedVector * regionSparse,
99 CoinIndexedVector * regionSparse2) const;
101
102private:
103
104 // checks looks okay
105 void check();
106 // prints data
107 void print();
110#ifndef COIN_FAST_CODE
112 double slackValue_;
113#endif
115 int numberRows_;
117 int numberColumns_;
119 const ClpSimplex * model_;
121 int * parent_;
123 int * descendant_;
125 int * pivot_;
127 int * rightSibling_;
129 int * leftSibling_;
131 double * sign_;
133 int * stack_;
135 int * permute_;
137 int * permuteBack_;
139 int * stack2_;
141 int * depth_;
143 char * mark_;
145};
146#endif
Abstract base class for Clp Matrices.
This deals with Factorization and Updates for network structures.
double updateColumn(CoinIndexedVector *regionSparse, CoinIndexedVector *regionSparse2, int pivotRow)
Updates one column (FTRAN) from region, Returns pivot value if "pivotRow" >=0.
int updateColumnTranspose(CoinIndexedVector *regionSparse, double array[]) const
Updates one column transpose (BTRAN) For large problems you should ALWAYS know where the nonzeros are...
ClpNetworkBasis & operator=(const ClpNetworkBasis &other)
= copy
~ClpNetworkBasis()
Destructor.
int updateColumn(CoinIndexedVector *regionSparse, double array[]) const
Updates one column (FTRAN) to/from array For large problems you should ALWAYS know where the nonzeros...
ClpNetworkBasis()
Default constructor.
int factorize(const ClpMatrixBase *matrix, int rowIsBasic[], int columnIsBasic[])
When part of LP - given by basic variables.
int updateColumnTranspose(CoinIndexedVector *regionSparse, CoinIndexedVector *regionSparse2) const
Updates one column (BTRAN) from region2.
int replaceColumn(CoinIndexedVector *column, int pivotRow)
Replaces one Column to basis, returns 0=OK, 1=Probably OK, 2=singular!!
ClpNetworkBasis(const ClpNetworkBasis &other)
Copy constructor.
ClpNetworkBasis(const ClpSimplex *model, int numberRows, const CoinFactorizationDouble *pivotRegion, const int *permuteBack, const CoinBigIndex *startColumn, const int *numberInColumn, const int *indexRow, const CoinFactorizationDouble *element)
Constructor from CoinFactorization.
This solves LPs using the simplex method.
Definition: ClpSimplex.hpp:70