Loading...
Searching...
No Matches
ClpPdcoBase.hpp
Go to the documentation of this file.
/* $Id$ */
// Copyright (C) 2003, International Business Machines
// Corporation and others. All Rights Reserved.
// This code is licensed under the terms of the Eclipse Public License (EPL).
#ifndef ClpPdcoBase_H
#define ClpPdcoBase_H
#include "CoinPragma.hpp"
#include "CoinPackedMatrix.hpp"
#include "CoinDenseVector.hpp"
class ClpInterior;
class ClpPdcoBase {
public:
virtual void matVecMult(ClpInterior *model, int mode, double *x, double *y) const = 0;
virtual void getGrad(ClpInterior *model, CoinDenseVector< double > &x, CoinDenseVector< double > &grad) const = 0;
virtual void getHessian(ClpInterior *model, CoinDenseVector< double > &x, CoinDenseVector< double > &H) const = 0;
virtual double getObj(ClpInterior *model, CoinDenseVector< double > &x) const = 0;
virtual void matPrecon(ClpInterior *model, double delta, double *x, double *y) const = 0;
virtual ClpPdcoBase *clone() const = 0;
inline int type() const
{
return type_;
};
inline void setType(int type)
{
type_ = type;
};
inline int sizeD1() const
{
return 1;
};
inline double getD1() const
{
return d1_;
};
inline int sizeD2() const
{
return 1;
};
inline double getD2() const
{
return d2_;
};
protected:
ClpPdcoBase();
public:
virtual ~ClpPdcoBase();
protected:
// Copy
ClpPdcoBase(const ClpPdcoBase &);
// Assignment
ClpPdcoBase &operator=(const ClpPdcoBase &);
protected:
double d1_;
double d2_;
int type_;
};
#endif
/* vi: softtabstop=2 shiftwidth=2 expandtab tabstop=2
*/
ClpInterior
This solves LPs using interior point methods.
Definition ClpInterior.hpp:72
ClpPdcoBase::setType
void setType(int type)
Sets type.
Definition ClpPdcoBase.hpp:51
ClpPdcoBase::type
int type() const
Returns type.
Definition ClpPdcoBase.hpp:46
ClpPdcoBase::ClpPdcoBase
ClpPdcoBase()
Default constructor.
ClpPdcoBase::ClpPdcoBase
ClpPdcoBase(const ClpPdcoBase &)
ClpPdcoBase::getHessian
virtual void getHessian(ClpInterior *model, CoinDenseVector< double > &x, CoinDenseVector< double > &H) const =0
ClpPdcoBase::~ClpPdcoBase
virtual ~ClpPdcoBase()
Destructor (has to be public).
ClpPdcoBase::d1_
double d1_
Should be dense vectors.
Definition ClpPdcoBase.hpp:100
ClpPdcoBase::clone
virtual ClpPdcoBase * clone() const =0
ClpPdcoBase::type_
int type_
type (may be useful)
Definition ClpPdcoBase.hpp:103
ClpPdcoBase::operator=
ClpPdcoBase & operator=(const ClpPdcoBase &)
ClpPdcoBase::sizeD1
int sizeD1() const
Returns size of d1.
Definition ClpPdcoBase.hpp:56
ClpPdcoBase::getGrad
virtual void getGrad(ClpInterior *model, CoinDenseVector< double > &x, CoinDenseVector< double > &grad) const =0
ClpPdcoBase::getD1
double getD1() const
Returns d1 as scalar.
Definition ClpPdcoBase.hpp:61
ClpPdcoBase::matVecMult
virtual void matVecMult(ClpInterior *model, int mode, double *x, double *y) const =0
ClpPdcoBase::sizeD2
int sizeD2() const
Returns size of d2.
Definition ClpPdcoBase.hpp:66
ClpPdcoBase::getObj
virtual double getObj(ClpInterior *model, CoinDenseVector< double > &x) const =0
ClpPdcoBase::d2_
double d2_
Definition ClpPdcoBase.hpp:101
ClpPdcoBase::getD2
double getD2() const
Returns d2 as scalar.
Definition ClpPdcoBase.hpp:71
ClpPdcoBase::matPrecon
virtual void matPrecon(ClpInterior *model, double delta, double *x, double *y) const =0