00001
00002
00003 #ifndef ClpAmplObjective_H
00004 #define ClpAmplObjective_H
00005
00006 #include "ClpObjective.hpp"
00007 #include "CoinPackedMatrix.hpp"
00008
00009
00010
00015 class ClpAmplObjective : public ClpObjective {
00016
00017 public:
00018
00020
00021
00028 virtual double * gradient(const ClpSimplex * model,
00029 const double * solution, double & offset,bool refresh,
00030 int includeLinear=2);
00032
00034 virtual double reducedGradient(ClpSimplex * model, double * region,
00035 bool useFeasibleCosts);
00042 virtual double stepLength(ClpSimplex * model,
00043 const double * solution,
00044 const double * change,
00045 double maximumTheta,
00046 double & currentObj,
00047 double & predictedObj,
00048 double & thetaObj);
00050 virtual double objectiveValue(const ClpSimplex * model, const double * solution) const ;
00051 virtual void resize(int newNumberColumns) ;
00053 virtual void deleteSome(int numberToDelete, const int * which) ;
00055 virtual void reallyScale(const double * columnScale) ;
00059 virtual int markNonlinear(char * which);
00060
00062 virtual void newXValues() ;
00064
00065
00067
00068
00069 ClpAmplObjective();
00070
00072 ClpAmplObjective(void * amplInfo);
00073
00076 ClpAmplObjective(const ClpAmplObjective & rhs);
00077
00079 ClpAmplObjective & operator=(const ClpAmplObjective& rhs);
00080
00082 virtual ~ClpAmplObjective ();
00083
00085 virtual ClpObjective * clone() const;
00086
00088
00089
00090
00091 double * linearObjective() const;
00093
00094
00095
00096 private:
00099 double offset_;
00101 void * amplObjective_;
00103 double * objective_;
00105 double * gradient_;
00107 };
00108
00109 #endif