- Main Page
- Classes
- Files

- File List
- File Members

# examples/hs071_cpp/hs071_nlp.hpp

Go to the documentation of this file.

    00001 // Copyright (C) 2005, 2007 International Business Machines and others.
    00002 // All Rights Reserved.
    00003 // This code is published under the Eclipse Public License.
    00004 //
    00005 // $Id: hs071_nlp.hpp 1861 2010-12-21 21:34:47Z andreasw $
    00006 //
    00007 // Authors:  Carl Laird, Andreas Waechter     IBM    2005-08-09
    00008
    00009 #ifndef __HS071_NLP_HPP__
    00010 #define __HS071_NLP_HPP__
    00011
    00012 #include "IpTNLP.hpp"
    00013
    00014 using namespace Ipopt;
    00015
    00037 class HS071_NLP : public TNLP
    00038 {
    00039 public:
    00041   HS071_NLP();
    00042
    00044   virtual ~HS071_NLP();
    00045
    00049   virtual bool get_nlp_info(Index& n, Index& m, Index& nnz_jac_g,
    00050                             Index& nnz_h_lag, IndexStyleEnum& index_style);
    00051
    00053   virtual bool get_bounds_info(Index n, Number* x_l, Number* x_u,
    00054                                Index m, Number* g_l, Number* g_u);
    00055
    00057   virtual bool get_starting_point(Index n, bool init_x, Number* x,
    00058                                   bool init_z, Number* z_L, Number* z_U,
    00059                                   Index m, bool init_lambda,
    00060                                   Number* lambda);
    00061
    00063   virtual bool eval_f(Index n, const Number* x, bool new_x, Number& obj_value);
    00064
    00066   virtual bool eval_grad_f(Index n, const Number* x, bool new_x, Number* grad_f);
    00067
    00069   virtual bool eval_g(Index n, const Number* x, bool new_x, Index m, Number* g);
    00070
    00075   virtual bool eval_jac_g(Index n, const Number* x, bool new_x,
    00076                           Index m, Index nele_jac, Index* iRow, Index *jCol,
    00077                           Number* values);
    00078
    00083   virtual bool eval_h(Index n, const Number* x, bool new_x,
    00084                       Number obj_factor, Index m, const Number* lambda,
    00085                       bool new_lambda, Index nele_hess, Index* iRow,
    00086                       Index* jCol, Number* values);
    00087
    00089
    00093   virtual void finalize_solution(SolverReturn status,
    00094                                  Index n, const Number* x, const Number* z_L, const Number* z_U,
    00095                                  Index m, const Number* g, const Number* lambda,
    00096                                  Number obj_value,
    00097                  const IpoptData* ip_data,
    00098                  IpoptCalculatedQuantities* ip_cq);
    00100
    00101 private:
    00113   //  HS071_NLP();
    00114   HS071_NLP(const HS071_NLP&);
    00115   HS071_NLP& operator=(const HS071_NLP&);
    00117 };
    00118
    00119
    00120 #endif

All Classes Files Functions Variables Typedefs Enumerations Enumerator Friends Defines