Clp  1.17.8
List of all members
ClpDualRowSteepest Class Reference

Dual Row Pivot Steepest Edge Algorithm Class. More...

#include <ClpDualRowSteepest.hpp>

+ Inheritance diagram for ClpDualRowSteepest:
+ Collaboration diagram for ClpDualRowSteepest:

Public Member Functions

Constructors and destructors
 ClpDualRowSteepest (int mode=3)
 Default Constructor 0 is uninitialized, 1 full, 2 is partial uninitialized, 3 starts as 2 but may switch to 1. More...
 
 ClpDualRowSteepest (const ClpDualRowSteepest &)
 Copy constructor. More...
 
ClpDualRowSteepestoperator= (const ClpDualRowSteepest &rhs)
 Assignment operator. More...
 
void fill (const ClpDualRowSteepest &rhs)
 Fill most values. More...
 
virtual ~ClpDualRowSteepest ()
 Destructor. More...
 
virtual ClpDualRowPivotclone (bool copyData=true) const
 Clone. More...
 
gets and sets
int mode () const
 Mode. More...
 
void setMode (int mode)
 Set mode. More...
 
void setPersistence (Persistence life)
 Set/ get persistence. More...
 
Persistence persistence () const
 
- Public Member Functions inherited from ClpDualRowPivot
virtual void checkAccuracy ()
 checks accuracy and may re-initialize (may be empty) More...
 
 ClpDualRowPivot ()
 Default Constructor. More...
 
 ClpDualRowPivot (const ClpDualRowPivot &)
 Copy constructor. More...
 
ClpDualRowPivotoperator= (const ClpDualRowPivot &rhs)
 Assignment operator. More...
 
virtual ~ClpDualRowPivot ()
 Destructor. More...
 
ClpSimplexmodel ()
 Returns model. More...
 
void setModel (ClpSimplex *newmodel)
 Sets model (normally to NULL) More...
 
int type ()
 Returns type (above 63 is extra information) More...
 

Protected Attributes

Protected member data
int state_
 Status 0) Normal -1) Needs initialization 1) Weights are stored by sequence number. More...
 
int mode_
 If 0 then we are using uninitialized weights, 1 then full, if 2 then uninitialized partial, 3 switchable. More...
 
Persistence persistence_
 Life of weights. More...
 
double * weights_
 weight array More...
 
CoinIndexedVector * infeasible_
 square of infeasibility array (just for infeasible rows) More...
 
CoinIndexedVector * alternateWeights_
 alternate weight array (so we can unroll) More...
 
CoinIndexedVector * savedWeights_
 save weight array (so we can use checkpoint) More...
 
int * dubiousWeights_
 Dubious weights. More...
 
- Protected Attributes inherited from ClpDualRowPivot
ClpSimplexmodel_
 Pointer to model. More...
 
int type_
 Type of row pivot algorithm. More...
 

Algorithmic methods

enum  Persistence { normal = 0x00, keep = 0x01 }
 enums for persistence More...
 
virtual int pivotRow ()
 Returns pivot row, -1 if none. More...
 
virtual double updateWeights (CoinIndexedVector *input, CoinIndexedVector *spare, CoinIndexedVector *spare2, CoinIndexedVector *updatedColumn)
 Updates weights and returns pivot alpha. More...
 
virtual void updatePrimalSolution (CoinIndexedVector *input, double theta, double &changeInObjective)
 Updates primal solution (and maybe list of candidates) Uses input vector which it deletes Computes change in objective function. More...
 
virtual void saveWeights (ClpSimplex *model, int mode)
 Saves any weights round factorization as pivot rows may change Save model May also recompute infeasibility stuff 1) before factorization 2) after good factorization (if weights empty may initialize) 3) after something happened but no factorization (e.g. More...
 
void passInSavedWeights (const CoinIndexedVector *saved)
 Pass in saved weights. More...
 
CoinIndexedVector * savedWeights ()
 Get saved weights. More...
 
virtual void unrollWeights ()
 Gets rid of last update. More...
 
virtual void clearArrays ()
 Gets rid of all arrays. More...
 
virtual bool looksOptimal () const
 Returns true if would not find any row. More...
 
virtual void maximumPivotsChanged ()
 Called when maximum pivots changes. More...
 

Detailed Description

Dual Row Pivot Steepest Edge Algorithm Class.

See Forrest-Goldfarb paper for algorithm

Definition at line 20 of file ClpDualRowSteepest.hpp.

Member Enumeration Documentation

◆ Persistence

enums for persistence

Enumerator
normal 
keep 

Definition at line 74 of file ClpDualRowSteepest.hpp.

Constructor & Destructor Documentation

◆ ClpDualRowSteepest() [1/2]

ClpDualRowSteepest::ClpDualRowSteepest ( int  mode = 3)

Default Constructor 0 is uninitialized, 1 full, 2 is partial uninitialized, 3 starts as 2 but may switch to 1.

By partial is meant that the weights are updated as normal but only part of the infeasible basic variables are scanned. This can be faster on very easy problems.

◆ ClpDualRowSteepest() [2/2]

ClpDualRowSteepest::ClpDualRowSteepest ( const ClpDualRowSteepest )

Copy constructor.

◆ ~ClpDualRowSteepest()

virtual ClpDualRowSteepest::~ClpDualRowSteepest ( )
virtual

Destructor.

Member Function Documentation

◆ pivotRow()

virtual int ClpDualRowSteepest::pivotRow ( )
virtual

Returns pivot row, -1 if none.

Implements ClpDualRowPivot.

Reimplemented in ClpPEDualRowSteepest.

◆ updateWeights()

virtual double ClpDualRowSteepest::updateWeights ( CoinIndexedVector *  input,
CoinIndexedVector *  spare,
CoinIndexedVector *  spare2,
CoinIndexedVector *  updatedColumn 
)
virtual

Updates weights and returns pivot alpha.

Also does FT update

Implements ClpDualRowPivot.

◆ updatePrimalSolution()

virtual void ClpDualRowSteepest::updatePrimalSolution ( CoinIndexedVector *  input,
double  theta,
double &  changeInObjective 
)
virtual

Updates primal solution (and maybe list of candidates) Uses input vector which it deletes Computes change in objective function.

Implements ClpDualRowPivot.

Reimplemented in ClpPEDualRowSteepest.

◆ saveWeights()

virtual void ClpDualRowSteepest::saveWeights ( ClpSimplex model,
int  mode 
)
virtual

Saves any weights round factorization as pivot rows may change Save model May also recompute infeasibility stuff 1) before factorization 2) after good factorization (if weights empty may initialize) 3) after something happened but no factorization (e.g.

check for infeasible) 4) as 2 but restore weights from previous snapshot 5) for strong branching - initialize (uninitialized) , infeasibilities

Reimplemented from ClpDualRowPivot.

Reimplemented in ClpPEDualRowSteepest.

◆ passInSavedWeights()

void ClpDualRowSteepest::passInSavedWeights ( const CoinIndexedVector *  saved)

Pass in saved weights.

◆ savedWeights()

CoinIndexedVector* ClpDualRowSteepest::savedWeights ( )
inline

Get saved weights.

Definition at line 58 of file ClpDualRowSteepest.hpp.

◆ unrollWeights()

virtual void ClpDualRowSteepest::unrollWeights ( )
virtual

Gets rid of last update.

Reimplemented from ClpDualRowPivot.

◆ clearArrays()

virtual void ClpDualRowSteepest::clearArrays ( )
virtual

Gets rid of all arrays.

Reimplemented from ClpDualRowPivot.

◆ looksOptimal()

virtual bool ClpDualRowSteepest::looksOptimal ( ) const
virtual

Returns true if would not find any row.

Reimplemented from ClpDualRowPivot.

◆ maximumPivotsChanged()

virtual void ClpDualRowSteepest::maximumPivotsChanged ( )
virtual

Called when maximum pivots changes.

Reimplemented from ClpDualRowPivot.

◆ operator=()

ClpDualRowSteepest& ClpDualRowSteepest::operator= ( const ClpDualRowSteepest rhs)

Assignment operator.

◆ fill()

void ClpDualRowSteepest::fill ( const ClpDualRowSteepest rhs)

Fill most values.

◆ clone()

virtual ClpDualRowPivot* ClpDualRowSteepest::clone ( bool  copyData = true) const
virtual

Clone.

Implements ClpDualRowPivot.

Reimplemented in ClpPEDualRowSteepest.

◆ mode()

int ClpDualRowSteepest::mode ( ) const
inline

Mode.

Definition at line 109 of file ClpDualRowSteepest.hpp.

◆ setMode()

void ClpDualRowSteepest::setMode ( int  mode)
inline

Set mode.

Definition at line 114 of file ClpDualRowSteepest.hpp.

◆ setPersistence()

void ClpDualRowSteepest::setPersistence ( Persistence  life)
inline

Set/ get persistence.

Definition at line 119 of file ClpDualRowSteepest.hpp.

◆ persistence()

Persistence ClpDualRowSteepest::persistence ( ) const
inline

Definition at line 123 of file ClpDualRowSteepest.hpp.

Member Data Documentation

◆ state_

int ClpDualRowSteepest::state_
protected

Status 0) Normal -1) Needs initialization 1) Weights are stored by sequence number.

Definition at line 138 of file ClpDualRowSteepest.hpp.

◆ mode_

int ClpDualRowSteepest::mode_
protected

If 0 then we are using uninitialized weights, 1 then full, if 2 then uninitialized partial, 3 switchable.

Definition at line 141 of file ClpDualRowSteepest.hpp.

◆ persistence_

Persistence ClpDualRowSteepest::persistence_
protected

Life of weights.

Definition at line 143 of file ClpDualRowSteepest.hpp.

◆ weights_

double* ClpDualRowSteepest::weights_
protected

weight array

Definition at line 145 of file ClpDualRowSteepest.hpp.

◆ infeasible_

CoinIndexedVector* ClpDualRowSteepest::infeasible_
protected

square of infeasibility array (just for infeasible rows)

Definition at line 147 of file ClpDualRowSteepest.hpp.

◆ alternateWeights_

CoinIndexedVector* ClpDualRowSteepest::alternateWeights_
protected

alternate weight array (so we can unroll)

Definition at line 149 of file ClpDualRowSteepest.hpp.

◆ savedWeights_

CoinIndexedVector* ClpDualRowSteepest::savedWeights_
protected

save weight array (so we can use checkpoint)

Definition at line 151 of file ClpDualRowSteepest.hpp.

◆ dubiousWeights_

int* ClpDualRowSteepest::dubiousWeights_
protected

Dubious weights.

Definition at line 153 of file ClpDualRowSteepest.hpp.


The documentation for this class was generated from the following file: