00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023 #if !defined (octave_NLP_h)
00024 #define octave_NLP_h 1
00025
00026 #include "dColVector.h"
00027 #include "Objective.h"
00028 #include "Bounds.h"
00029 #include "LinConst.h"
00030 #include "NLConst.h"
00031 #include "base-min.h"
00032
00033 class
00034 NLP : public base_minimizer
00035 {
00036 public:
00037
00038 NLP (void)
00039 : base_minimizer (), phi (), bnds (), lc (), nlc () { }
00040
00041 NLP (const ColumnVector& x, const Objective& obj)
00042 : base_minimizer (x), phi (obj), bnds (), lc (), nlc () { }
00043
00044 NLP (const ColumnVector& x, const Objective& obj, const Bounds& b)
00045 : base_minimizer (x), phi (obj), bnds (b), lc (), nlc () { }
00046
00047 NLP (const ColumnVector& x, const Objective& obj, const Bounds& b,
00048 const LinConst& l)
00049 : base_minimizer (x), phi (obj), bnds (b), lc (l), nlc () { }
00050
00051 NLP (const ColumnVector& x, const Objective& obj, const Bounds& b,
00052 const LinConst& l, const NLConst& nl)
00053 : base_minimizer (x), phi (obj), bnds (b), lc (l), nlc (nl) { }
00054
00055 NLP (const ColumnVector& x, const Objective& obj, const LinConst& l)
00056 : base_minimizer (x), phi (obj), bnds (), lc (l), nlc () { }
00057
00058 NLP (const ColumnVector& x, const Objective& obj, const LinConst& l,
00059 const NLConst& nl)
00060 : base_minimizer (x), phi (obj), bnds (), lc (l), nlc (nl) { }
00061
00062 NLP (const ColumnVector& x, const Objective& obj, const NLConst& nl)
00063 : base_minimizer (x), phi (obj), bnds (), lc (), nlc (nl) { }
00064
00065 NLP (const ColumnVector& x, const Objective& obj, const Bounds& b,
00066 const NLConst& nl)
00067 : base_minimizer (x), phi (obj), bnds (b), lc (), nlc (nl) { }
00068
00069 NLP (const NLP& a)
00070 : base_minimizer (a), phi (a.phi), bnds (a.bnds), lc (a.lc), nlc (a.nlc)
00071 { }
00072
00073 NLP& operator = (const NLP& a)
00074 {
00075 if (this != &a)
00076 {
00077 base_minimizer::operator = (a);
00078
00079 phi = a.phi;
00080 bnds = a.bnds;
00081 lc = a.lc;
00082 nlc = a.nlc;
00083 }
00084 return *this;
00085 }
00086
00087 virtual ~NLP (void) { }
00088
00089 Objective objective (void) const { return phi; }
00090
00091 Bounds bounds (void) const { return bnds; }
00092
00093 LinConst linear_constraints (void) const { return lc; }
00094
00095 NLConst nonlinear_constraints (void) const { return nlc; }
00096
00097 protected:
00098
00099 Objective phi;
00100 Bounds bnds;
00101 LinConst lc;
00102 NLConst nlc;
00103 };
00104
00105 #endif
00106
00107
00108
00109
00110
00111