- Main Page
- Classes
- Files

- File List
- File Members

# contrib/sIPOPT/examples/redhess_cpp/MySensTNLP.hpp

Go to the documentation of this file.

    00001 // Copyright 2009 Hans Pirnay
    00002 // All Rights Reserved.
    00003 // This code is published under the Eclipse Public License.
    00004 //
    00005 // Date   : 2010-10-04
    00006
    00007 #ifndef __MYSENSNLP_HPP__
    00008 #define __MYSENSNLP_HPP__
    00009
    00010 #include "IpTNLP.hpp"
    00011
    00012 namespace Ipopt
    00013 {
    00014
    00015   class MySensTNLP : public TNLP
    00016   {
    00017   public:
    00018
    00020     MySensTNLP();
    00021
    00023     virtual ~MySensTNLP();
    00024
    00028     virtual bool get_nlp_info(Index& n, Index& m, Index& nnz_jac_g,
    00029                   Index& nnz_h_lag, IndexStyleEnum& index_style);
    00030
    00032     virtual bool get_bounds_info(Index n, Number* x_l, Number* x_u,
    00033                  Index m, Number* g_l, Number* g_u);
    00034
    00036     virtual bool get_starting_point(Index n, bool init_x, Number* x,
    00037                     bool init_z, Number* z_L, Number* z_U,
    00038                     Index m, bool init_lambda,
    00039                     Number* lambda);
    00040
    00042     virtual bool eval_f(Index n, const Number* x, bool new_x, Number& obj_value);
    00043
    00045     virtual bool eval_grad_f(Index n, const Number* x, bool new_x, Number* grad_f);
    00046
    00048     virtual bool eval_g(Index n, const Number* x, bool new_x, Index m, Number* g);
    00049
    00054     virtual bool eval_jac_g(Index n, const Number* x, bool new_x,
    00055                 Index m, Index nele_jac, Index* iRow, Index *jCol,
    00056                 Number* values);
    00057
    00062     virtual bool eval_h(Index n, const Number* x, bool new_x,
    00063             Number obj_factor, Index m, const Number* lambda,
    00064             bool new_lambda, Index nele_hess, Index* iRow,
    00065             Index* jCol, Number* values);
    00066
    00068
    00069     virtual bool get_var_con_metadata(Index n,
    00070                                       StringMetaDataMapType& var_string_md,
    00071                                       IntegerMetaDataMapType& var_integer_md,
    00072                                       NumericMetaDataMapType& var_numeric_md,
    00073                                       Index m,
    00074                                       StringMetaDataMapType& con_string_md,
    00075                                       IntegerMetaDataMapType& con_integer_md,
    00076                                       NumericMetaDataMapType& con_numeric_md);
    00077
    00081     virtual void finalize_solution(SolverReturn status,
    00082                    Index n, const Number* x, const Number* z_L, const Number* z_U,
    00083                    Index m, const Number* g, const Number* lambda,
    00084                    Number obj_value,
    00085                    const IpoptData* ip_data,
    00086                    IpoptCalculatedQuantities* ip_cq);
    00088
    00089   private:
    00101     MySensTNLP(const MySensTNLP&);
    00102     MySensTNLP& operator=(const MySensTNLP&);
    00104   };
    00105
    00106 }
    00107
    00108 #endif

All Classes Files Functions Variables Typedefs Enumerations Enumerator Friends Defines