Changeset 1984


Ignore:
Timestamp:
Apr 14, 2011 3:44:30 AM (9 years ago)
Author:
hpirnay
Message:

Changed class names to match new sIPOPT name structure

Location:
trunk/Ipopt/contrib/sIPOPT
Files:
34 edited

Legend:

Unmodified
Added
Removed
  • trunk/Ipopt/contrib/sIPOPT/AmplSolver/ampl_nmpc.cpp

    r1982 r1984  
    1919  SmartPtr<IpoptApplication> app_ipopt = new IpoptApplication();
    2020
    21   SmartPtr<NmpcApplication> app_nmpc = new NmpcApplication(app_ipopt->Jnlst(),
     21  SmartPtr<SensApplication> app_sens = new SensApplication(app_ipopt->Jnlst(),
    2222                                                           app_ipopt->Options(),
    2323                                                           app_ipopt->RegOptions());
    2424
    25   // Register AsNMPC options
    26   RegisterOptions_AsNMPC(app_ipopt->RegOptions());
     25  // Register sIPOPT options
     26  RegisterOptions_sIPOPT(app_ipopt->RegOptions());
    2727  app_ipopt->Options()->SetRegisteredOptions(app_ipopt->RegOptions());
    2828
     
    5050  suffix_handler->AddAvailableSuffix("perturbed_value", AmplSuffixHandler::Variable_Source, AmplSuffixHandler::Number_Type);
    5151
    52   // Suffixes for NMPC
     52  // Suffixes for sIPOPT
    5353  suffix_handler->AddAvailableSuffix("sens_init_constr", AmplSuffixHandler::Constraint_Source, AmplSuffixHandler::Index_Type);
    5454
     
    8989    suffix_handler->AddAvailableSuffix(sol_state_zL, AmplSuffixHandler::Variable_Source, AmplSuffixHandler::Number_Type);
    9090    suffix_handler->AddAvailableSuffix(sol_state_zU, AmplSuffixHandler::Variable_Source, AmplSuffixHandler::Number_Type);
    91 
    9291  }
    9392
     
    9594  suffix_handler->AddAvailableSuffix("red_hessian", AmplSuffixHandler::Variable_Source, AmplSuffixHandler::Index_Type);
    9695
    97   // Create AmplOptionsList for AsNMPC AMPL options
     96  // Create AmplOptionsList for sIPOPT AMPL options
    9897  SmartPtr<AmplOptionsList> ampl_options_list = new AmplOptionsList();
    9998
     
    111110                                              ampl_options_list);
    112111
    113   app_nmpc->Initialize();
     112  app_sens->Initialize();
    114113
    115114  const int n_loops = 1; // make larger for profiling
     
    119118
    120119  /* give pointers to Ipopt algorithm objects to NMPC Application */
    121   app_nmpc->SetIpoptAlgorithmObjects(app_ipopt, retval);
     120  app_sens->SetIpoptAlgorithmObjects(app_ipopt, retval);
    122121
    123   app_nmpc->Run();
     122  app_sens->Run();
    124123
    125124
  • trunk/Ipopt/contrib/sIPOPT/examples/parametric_cpp/parametricTNLP.cpp

    r1960 r1984  
    1515
    1616/* Constructor */
    17 ParametricTNLP::ParametricTNLP() : 
     17ParametricTNLP::ParametricTNLP() :
    1818  nominal_eta1_(4.5),
    1919  nominal_eta2_(1.0),
     
    199199{
    200200  /* In this function, the indices for the parametric computations are set.
    201    * To keep track of the parameters, each parameter gets an index from 1 to n_parameters. 
     201   * To keep track of the parameters, each parameter gets an index from 1 to n_parameters.
    202202   * In this case, [1] eta_1, [2] eta_2.
    203203   * The following metadata vectors are important:
     
    205205
    206206
    207   /* 1. sens_init_constr: in this list, the constraints that set the initial 
    208    *    values for the parameters are indicated. 
     207  /* 1. sens_init_constr: in this list, the constraints that set the initial
     208   *    values for the parameters are indicated.
    209209   *    For parameter 1 (eta_1) this is constraint 3 (e.g. C++ index 2), which is
    210210   *    the constraint   eta_1 = eta_1_nominal;
     
    216216  con_integer_md["sens_init_constr"] = sens_init_constr;
    217217
    218   /* 2. sens_state_1: in this index list, the parameters are indicated: 
     218  /* 2. sens_state_1: in this index list, the parameters are indicated:
    219219   *    Here: [1] eta_1, [2] eta_2
    220220   */
     
    242242                                       IpoptCalculatedQuantities* ip_cq)
    243243{
    244   // Check whether AsNMPC Algorithm aborted internally
     244  // Check whether sIPOPT Algorithm aborted internally
    245245  //  bool nmpc_internal_abort;
    246246  //options_->GetBoolValue("nmpc_internal_abort", nmpc_internal_abort, "");
     
    275275                                       const NumericMetaDataMapType& con_numeric_md)
    276276{
    277   // bound multipliers for lower and upper bounds 
     277  // bound multipliers for lower and upper bounds
    278278  printf("\nDual bound multipliers:\n");
    279   NumericMetaDataMapType::const_iterator z_L_solution = var_numeric_md.find("sens_sol_state_1_z_L"); 
    280   NumericMetaDataMapType::const_iterator z_U_solution = var_numeric_md.find("sens_sol_state_1_z_U"); 
     279  NumericMetaDataMapType::const_iterator z_L_solution = var_numeric_md.find("sens_sol_state_1_z_L");
     280  NumericMetaDataMapType::const_iterator z_U_solution = var_numeric_md.find("sens_sol_state_1_z_U");
    281281  if (z_L_solution!=var_numeric_md.end() && z_U_solution!=var_numeric_md.end()) {
    282282    for (Index k=0; k<n; ++k) {
  • trunk/Ipopt/contrib/sIPOPT/examples/parametric_cpp/parametric_driver.cpp

    r1982 r1984  
    1 // Copyright 2010 Hans Pirnay
     1// Copyright 2010, 2011 Hans Pirnay
    22// All Rights Reserved.
    33// This code is published under the Eclipse Public License.
     
    1919  SmartPtr<IpoptApplication> app_ipopt = new IpoptApplication();
    2020
    21   SmartPtr<NmpcApplication> app_nmpc = new NmpcApplication(app_ipopt->Jnlst(),
     21  SmartPtr<SensApplication> app_sens = new SensApplication(app_ipopt->Jnlst(),
    2222                                                           app_ipopt->Options(),
    2323                                                           app_ipopt->RegOptions());
    2424
    25   // Register AsNMPC options
    26   RegisterOptions_AsNMPC(app_ipopt->RegOptions());
     25  // Register sIPOPT options
     26  RegisterOptions_sIPOPT(app_ipopt->RegOptions());
    2727  app_ipopt->Options()->SetRegisteredOptions(app_ipopt->RegOptions());
    2828
     
    3838
    3939  // create AmplSensTNLP from argc. This is an nlp because we are using our own TNLP Adapter
    40   SmartPtr<TNLP> nmpc_tnlp = new ParametricTNLP();
     40  SmartPtr<TNLP> sens_tnlp = new ParametricTNLP();
    4141
    4242  app_ipopt->Options()->SetStringValueIfUnset("run_sens", "yes");
    4343  app_ipopt->Options()->SetIntegerValueIfUnset("n_sens_steps", 1);
    4444
    45   app_nmpc->Initialize();
     45  app_sens->Initialize();
    4646
    47   retval = app_ipopt->OptimizeTNLP(nmpc_tnlp);
     47  retval = app_ipopt->OptimizeTNLP(sens_tnlp);
    4848
    4949  /* give pointers to Ipopt algorithm objects to NMPC Application */
    50   app_nmpc->SetIpoptAlgorithmObjects(app_ipopt, retval);
     50  app_sens->SetIpoptAlgorithmObjects(app_ipopt, retval);
    5151
    52   app_nmpc->Run();
     52  app_sens->Run();
    5353
    5454
  • trunk/Ipopt/contrib/sIPOPT/examples/redhess_cpp/redhess_cpp.cpp

    r1982 r1984  
    1 // Copyright 2009 Hans Pirnay
     1// Copyright 2009, 2011 Hans Pirnay
    22// All Rights Reserved.
    33// This code is published under the Eclipse Public License.
     
    2020  SmartPtr<IpoptApplication> app_ipopt = new IpoptApplication();
    2121
    22   SmartPtr<NmpcApplication> app_nmpc = new NmpcApplication(app_ipopt->Jnlst(),
     22  SmartPtr<SensApplication> app_sens = new SensApplication(app_ipopt->Jnlst(),
    2323                                                           app_ipopt->Options(),
    2424                                                           app_ipopt->RegOptions());
    2525
    26   // Register AsNMPC options
    27   RegisterOptions_AsNMPC(app_ipopt->RegOptions());
     26  // Register sIPOPT options
     27  RegisterOptions_sIPOPT(app_ipopt->RegOptions());
    2828  app_ipopt->Options()->SetRegisteredOptions(app_ipopt->RegOptions());
    2929
     
    4545  app_ipopt->Options()->SetStringValueIfUnset("compute_red_hessian", "yes");
    4646
    47   app_nmpc->Initialize();
     47  app_sens->Initialize();
    4848
    4949  retval = app_ipopt->OptimizeTNLP(nmpc_tnlp);
    5050
    5151  /* give pointers to Ipopt algorithm objects to NMPC Application */
    52   app_nmpc->SetIpoptAlgorithmObjects(app_ipopt, retval);
     52  app_sens->SetIpoptAlgorithmObjects(app_ipopt, retval);
    5353
    54   app_nmpc->Run();
     54  app_sens->Run();
    5555
    5656  return 0;
  • trunk/Ipopt/contrib/sIPOPT/src/SensAlgorithm.cpp

    r1982 r1984  
    1515#endif
    1616
    17   AsNmpController::AsNmpController(std::vector< SmartPtr<SchurDriver> >& driver_vec,
    18                                    SmartPtr<SensitivityStepCalculator> sens_step_calc,
    19                                    SmartPtr<Measurement> measurement,
    20                                    Index n_sens_steps)
     17  SensAlgorithm::SensAlgorithm(std::vector< SmartPtr<SchurDriver> >& driver_vec,
     18                               SmartPtr<SensitivityStepCalculator> sens_step_calc,
     19                               SmartPtr<Measurement> measurement,
     20                               Index n_sens_steps)
    2121    :
    2222    driver_vec_(driver_vec),
    2323    sens_step_calc_(sens_step_calc),
    2424    measurement_(measurement),
    25     n_sens_steps_(n_sens_steps)
     25    n_sens_steps_(n_sens_steps) // why doesn't he get this from the options?
    2626  {
    27     DBG_START_METH("AsNmpController::AsNmpController", dbg_verbosity);
     27    DBG_START_METH("SensAlgorithm::SensAlgorithm", dbg_verbosity);
    2828
    2929    DBG_ASSERT(n_sens_steps<=driver_vec.size());
    3030  }
    3131
    32   AsNmpController::~AsNmpController()
     32  SensAlgorithm::~SensAlgorithm()
    3333  {
    34     DBG_START_METH("AsNmpController::~AsNmpController", dbg_verbosity);
     34    DBG_START_METH("SensAlgorithm::~SensAlgorithm", dbg_verbosity);
    3535  }
    3636
    37   bool AsNmpController::InitializeImpl(const OptionsList& options,
    38                                        const std::string& prefix)
     37  bool SensAlgorithm::InitializeImpl(const OptionsList& options,
     38                                     const std::string& prefix)
    3939  {
    4040    return true;
     
    4444   *  bounds,  see to it that everything happens in the required
    4545   *  timeframe. */
    46   NmpControllerExitStatus AsNmpController::Run()
     46  SensAlgorithmExitStatus SensAlgorithm::Run()
    4747  {
    48     DBG_START_METH("AsNmpController::Run", dbg_verbosity);
     48    DBG_START_METH("SensAlgorithm::Run", dbg_verbosity);
    4949
    50     NmpControllerExitStatus retval = SOLVE_SUCCESS;
     50    SensAlgorithmExitStatus retval = SOLVE_SUCCESS;
    5151
    5252    /* Loop through all steps */
     
    9292
    9393        printf("***********************************\n"
    94         "Running AsNMPC my-formula\n"
     94        "Running sIPOPT my-formula\n"
    9595        "value of objective function:  %23.16e\n"
    9696        "Nrm2 of KKT residual:         %23.16e\n"
     
    107107
    108108}
    109 
  • trunk/Ipopt/contrib/sIPOPT/src/SensAlgorithm.hpp

    r1982 r1984  
    1 // Copyright 2009 Hans Pirnay
     1// Copyright 2009, 2011 Hans Pirnay
    22// All Rights Reserved.
    33// This code is published under the Eclipse Public License.
     
    1717{
    1818
    19   class AsNmpController : public AlgorithmStrategyObject
     19  class SensAlgorithm : public AlgorithmStrategyObject
    2020  {
    2121    /** This is the interface for the actual controller. It handles
     
    2424  public:
    2525
    26     AsNmpController(std::vector< SmartPtr<SchurDriver> >& driver_vec,
    27                     SmartPtr<SensitivityStepCalculator> sens_step_calc,
    28                     SmartPtr<Measurement> measurement,
    29                     Index n_sens_steps);
     26    SensAlgorithm(std::vector< SmartPtr<SchurDriver> >& driver_vec,
     27                  SmartPtr<SensitivityStepCalculator> sens_step_calc,
     28                  SmartPtr<Measurement> measurement,
     29                  Index n_sens_steps);
    3030
    31     virtual ~AsNmpController();
     31    virtual ~SensAlgorithm();
    3232
    3333    virtual bool InitializeImpl(const OptionsList& options,
     
    3737     *  bounds,  see to it that everything happens in the required
    3838     *  timeframe. */
    39     NmpControllerExitStatus Run();
     39    SensAlgorithmExitStatus Run();
    4040
    4141  private:
  • trunk/Ipopt/contrib/sIPOPT/src/SensApplication.cpp

    r1983 r1984  
    2222
    2323
    24   NmpcApplication::NmpcApplication(SmartPtr<Journalist> jnlst,
     24  SensApplication::SensApplication(SmartPtr<Journalist> jnlst,
    2525                                   SmartPtr<OptionsList> options,
    2626                                   SmartPtr<RegisteredOptions> reg_options)
     
    3131    ipopt_retval_(Internal_Error)
    3232  {
    33     DBG_START_METH("NmpcApplication::NmpcApplication", dbg_verbosity);
     33    DBG_START_METH("SensApplication::SensApplication", dbg_verbosity);
    3434
    3535    // Initialize Journalist
     
    3939  }
    4040
    41   NmpcApplication::~NmpcApplication()
    42   {
    43     DBG_START_METH("NmpcApplication::~NmpcApplication", dbg_verbosity);
    44   }
    45 
    46   void NmpcApplication::RegisterOptions(SmartPtr<RegisteredOptions> roptions)
    47   {
    48     // Options for NMPC Parameter Sensitivity
    49     roptions->SetRegisteringCategory("AsNmpc");
     41  SensApplication::~SensApplication()
     42  {
     43    DBG_START_METH("SensApplication::~SensApplication", dbg_verbosity);
     44  }
     45
     46  void SensApplication::RegisterOptions(SmartPtr<RegisteredOptions> roptions)
     47  {
     48    // Options for parameter sensitivity
     49    roptions->SetRegisteringCategory("sIPOPT");
    5050    roptions->AddLowerBoundedIntegerOption(
    5151                                           "n_sens_steps", "Number of steps computed by sIPOPT",
     
    134134  }
    135135
    136   NmpControllerExitStatus NmpcApplication::Run()
    137   {
    138     DBG_START_METH("NmpcApplication::Run", dbg_verbosity);
    139 
    140     NmpControllerExitStatus retval = SOLVE_SUCCESS;
     136  SensAlgorithmExitStatus SensApplication::Run()
     137  {
     138    DBG_START_METH("SensApplication::Run", dbg_verbosity);
     139
     140    SensAlgorithmExitStatus retval = SOLVE_SUCCESS;
    141141
    142142    bool nmpc_internal_abort, redhess_internal_abort;
     
    163163
    164164    if (compute_red_hessian_ && !redhess_internal_abort) {
    165       SmartPtr<SchurBuilder> schur_builder = new SchurBuilder();
     165      SmartPtr<SensBuilder> schur_builder = new SensBuilder();
    166166      const std::string prefix = ""; // I should be getting this somewhere else...
    167167      SmartPtr<ReducedHessianCalculator> red_hess_calc = schur_builder->BuildRedHessCalc(*jnlst_,
     
    177177
    178178    if (run_sens_ && n_sens_steps_>0 && !nmpc_internal_abort) {
    179       SmartPtr<SchurBuilder> schur_builder = new SchurBuilder();
     179      SmartPtr<SensBuilder> schur_builder = new SensBuilder();
    180180      const std::string prefix = ""; // I should be getting this somewhere else...
    181       SmartPtr<AsNmpController> controller = schur_builder->BuildNmpc(*jnlst_,
    182                                                                       *options_,
    183                                                                       prefix,
    184                                                                       *ip_nlp_,
    185                                                                       *ip_data_,
    186                                                                       *ip_cq_,
    187                                                                       *pd_solver_);
     181      SmartPtr<SensAlgorithm> controller = schur_builder->BuildSensAlg(*jnlst_,
     182                                                                       *options_,
     183                                                                       prefix,
     184                                                                       *ip_nlp_,
     185                                                                       *ip_data_,
     186                                                                       *ip_cq_,
     187                                                                       *pd_solver_);
    188188
    189189      retval = controller->Run();
     
    211211      case SUCCESS:
    212212        /*c = ip_cq_->curr_c();
    213         d = ip_cq_->curr_d();
    214         obj = ip_cq_->curr_f();
    215         zL = ip_data_->curr()->z_L();
    216         zU = ip_data_->curr()->z_U();
    217         yc = ip_data_->curr()->y_c();
    218         yd = ip_data_->curr()->y_d();*/
     213          d = ip_cq_->curr_d();
     214          obj = ip_cq_->curr_f();
     215          zL = ip_data_->curr()->z_L();
     216          zU = ip_data_->curr()->z_U();
     217          yc = ip_data_->curr()->y_c();
     218          yd = ip_data_->curr()->y_d();*/
    219219      case MAXITER_EXCEEDED:
    220220      case STOP_AT_TINY_STEP:
     
    270270  }
    271271
    272   void NmpcApplication::Initialize()
    273   {
    274     DBG_START_METH("NmpcApplication::Initialize", dbg_verbosity);
     272  void SensApplication::Initialize()
     273  {
     274    DBG_START_METH("SensApplication::Initialize", dbg_verbosity);
    275275
    276276    const std::string prefix = ""; // I should be getting this somewhere else...
     
    290290  }
    291291
    292   void NmpcApplication::SetIpoptAlgorithmObjects(SmartPtr<IpoptApplication> app_ipopt,
     292  void SensApplication::SetIpoptAlgorithmObjects(SmartPtr<IpoptApplication> app_ipopt,
    293293                                                 ApplicationReturnStatus ipopt_retval)
    294294  {
    295     DBG_START_METH("NmpcApplication::SetIpoptAlgorithmObjects", dbg_verbosity);
     295    DBG_START_METH("SensApplication::SetIpoptAlgorithmObjects", dbg_verbosity);
    296296
    297297    // get optionsList and Journalist
  • trunk/Ipopt/contrib/sIPOPT/src/SensApplication.hpp

    r1982 r1984  
    1 // Copyright 2009 Hans Pirnay
     1// Copyright 2009, 2011 Hans Pirnay
    22// All Rights Reserved.
    33// This code is published under the Eclipse Public License.
     
    2020  DECLARE_STD_EXCEPTION(NMPC_SUFFIX_ERROR);
    2121
    22   class NmpcApplication : public ReferencedObject
     22  class SensApplication : public ReferencedObject
    2323  {
    2424  public:
    2525    // constructor
    26     NmpcApplication(SmartPtr<Journalist> jnlst,
     26    SensApplication(SmartPtr<Journalist> jnlst,
    2727                    SmartPtr<OptionsList> options,
    2828                    SmartPtr<RegisteredOptions> reg_options);
    2929
    30     ~NmpcApplication();
     30    ~SensApplication();
    3131
    3232    static void RegisterOptions(SmartPtr<RegisteredOptions> roptions);
    3333
    34     NmpControllerExitStatus Run();
     34    SensAlgorithmExitStatus Run();
    3535
    3636    void Initialize();
     
    6060
    6161    // standard constructor just so it can't be used
    62     //    NmpcApplication();
     62    //    SensApplication();
    6363
    6464    // Pointers that are immediately passed from Ipopt and initialized by the constructor
     
    6969    SmartPtr<PDSystemSolver> pd_solver_;
    7070    SmartPtr<IpoptNLP> ip_nlp_;
    71     //SmartPtr<NmpcTNLPAdapter> tnlp_adapter_;
    7271    SmartPtr<RegisteredOptions> reg_options_;
    7372    ApplicationReturnStatus ipopt_retval_;
  • trunk/Ipopt/contrib/sIPOPT/src/SensBacksolver.hpp

    r1981 r1984  
    1 // Copyright 2009 Hans Pirnay
     1// Copyright 2009, 2011 Hans Pirnay
    22// All Rights Reserved.
    33// This code is published under the Eclipse Public License.
     
    1515{
    1616
    17   class AsBacksolver : public AlgorithmStrategyObject
     17  class SensBacksolver : public AlgorithmStrategyObject
    1818  {
    1919
    2020    /** This class is the interface to all backsolvers that may
    21      *  be used for the AsNMPC. */
     21     *  be used for the sIPOPT. */
    2222  public:
    23     AsBacksolver()
     23    SensBacksolver()
    2424    {
    2525    }
    26    
    27     virtual ~AsBacksolver()
     26
     27    virtual ~SensBacksolver()
    2828    {
    2929    }
  • trunk/Ipopt/contrib/sIPOPT/src/SensBuilder.cpp

    r1983 r1984  
    2424#endif
    2525
    26   SchurBuilder::SchurBuilder()
     26  SensBuilder::SensBuilder()
    2727  {
    28     DBG_START_METH("SchurBuilder::SchurBuilder", dbg_verbosity);
     28    DBG_START_METH("SensBuilder::SensBuilder", dbg_verbosity);
    2929  }
    3030
    31   SchurBuilder::~SchurBuilder()
     31  SensBuilder::~SensBuilder()
    3232  {
    33     DBG_START_METH("SchurBuilder::~SchurBuilder", dbg_verbosity);
     33    DBG_START_METH("SensBuilder::~SensBuilder", dbg_verbosity);
    3434  }
    3535
    36   SmartPtr<AsNmpController> SchurBuilder::BuildNmpc(const Journalist& jnlst,
     36  SmartPtr<SensAlgorithm> SensBuilder::BuildSensAlg(const Journalist& jnlst,
    3737                                                    const OptionsList& options,
    3838                                                    const std::string& prefix,
     
    4242                                                    PDSystemSolver& pd_solver)
    4343  {
    44     DBG_START_METH("SchurBuilder::BuildNmpc", dbg_verbosity);
     44    DBG_START_METH("SensBuilder::BuildSensAlg", dbg_verbosity);
    4545
    4646    // Very first thing is setting trial = curr.
     
    4949
    5050    // Check options which Backsolver to use here
    51     SmartPtr<AsBacksolver> backsolver = new SimpleBacksolver(&pd_solver);
     51    SmartPtr<SensBacksolver> backsolver = new SimpleBacksolver(&pd_solver);
    5252
    5353    // Create measurement unit
     
    9898     *  Measurement class. This should get it's own branch! */
    9999    for (Index i=0; i<n_sens_steps; ++i) {
    100       driver_vec[i] = new IFTSchurDriver(backsolver, pcalc,E_0);
     100      driver_vec[i] = new DenseGenSchurDriver(backsolver, pcalc,E_0);
    101101      driver_vec[i]->Initialize(jnlst,
    102102                                ip_nlp,
     
    120120                             prefix);
    121121
    122     SmartPtr<AsNmpController> controller = new AsNmpController(driver_vec,
    123                                                                sens_stepper,
    124                                                                measurement,
    125                                                                n_sens_steps);
     122    SmartPtr<SensAlgorithm> controller = new SensAlgorithm(driver_vec,
     123                                                           sens_stepper,
     124                                                           measurement,
     125                                                           n_sens_steps);
    126126
    127127    controller->Initialize(jnlst,
     
    134134  }
    135135
    136   SmartPtr<ReducedHessianCalculator> SchurBuilder::BuildRedHessCalc(const Journalist& jnlst,
    137                                                                     const OptionsList& options,
    138                                                                     const std::string& prefix,
    139                                                                     IpoptNLP& ip_nlp,
    140                                                                     IpoptData& ip_data,
    141                                                                     IpoptCalculatedQuantities& ip_cq,
    142                                                                     //NmpcTNLPAdapter& nmpc_tnlp_adapter,
    143                                                                     PDSystemSolver& pd_solver)
     136  SmartPtr<ReducedHessianCalculator> SensBuilder::BuildRedHessCalc(const Journalist& jnlst,
     137                                                                   const OptionsList& options,
     138                                                                   const std::string& prefix,
     139                                                                   IpoptNLP& ip_nlp,
     140                                                                   IpoptData& ip_data,
     141                                                                   IpoptCalculatedQuantities& ip_cq,
     142                                                                   PDSystemSolver& pd_solver)
    144143  {
    145     DBG_START_METH("SchurBuilder::BuildRedHessCalc", dbg_verbosity);
     144    DBG_START_METH("SensBuilder::BuildRedHessCalc", dbg_verbosity);
    146145
    147146    // Check options which Backsolver to use here
    148     SmartPtr<AsBacksolver> backsolver = new SimpleBacksolver(&pd_solver);
     147    SmartPtr<SensBacksolver> backsolver = new SimpleBacksolver(&pd_solver);
    149148
    150149    // Create suffix handler
     
    166165                   "the Indices for the reduced hessian computation: Something "
    167166                   "is wrong with index %d\n",setdata_error);
    168       THROW_EXCEPTION(ASNMPC_BUILDER_ERROR,
     167      THROW_EXCEPTION(SENS_BUILDER_ERROR,
    169168                      "Reduced Hessian Index Error");
    170169    }
  • trunk/Ipopt/contrib/sIPOPT/src/SensBuilder.hpp

    r1982 r1984  
    1 // Copyright 2009 Hans Pirnay
     1// Copyright 2009, 2011 Hans Pirnay
    22// All Rights Reserved.
    33// This code is published under the Eclipse Public License.
     
    1818namespace Ipopt
    1919{
    20   DECLARE_STD_EXCEPTION(ASNMPC_BUILDER_ERROR);
     20  DECLARE_STD_EXCEPTION(SENS_BUILDER_ERROR);
    2121
    22   class SchurBuilder : public ReferencedObject
     22  class SensBuilder : public ReferencedObject
    2323  {
    2424    /** This class sets up everything necessary and
     
    2626     *  in calculating the schur matrix. */
    2727  public:
    28     SchurBuilder();
     28    SensBuilder();
    2929
    30     ~SchurBuilder();
     30    ~SensBuilder();
    3131
    32     SmartPtr<AsNmpController> BuildNmpc(const Journalist& jnlst,
    33                                         const OptionsList& options,
    34                                         const std::string& prefix,
    35                                         IpoptNLP& ip_nlp,
    36                                         IpoptData& ip_data,
    37                                         IpoptCalculatedQuantities& ip_cq,
    38                                         PDSystemSolver& pd_solver);
     32    SmartPtr<SensAlgorithm> BuildSensAlg(const Journalist& jnlst,
     33                                         const OptionsList& options,
     34                                         const std::string& prefix,
     35                                         IpoptNLP& ip_nlp,
     36                                         IpoptData& ip_data,
     37                                         IpoptCalculatedQuantities& ip_cq,
     38                                         PDSystemSolver& pd_solver);
    3939
    4040    SmartPtr<ReducedHessianCalculator> BuildRedHessCalc(const Journalist& jnlst,
     
    4444                                                        IpoptData& ip_data,
    4545                                                        IpoptCalculatedQuantities& ip_cq,
    46                                                         //NmpcTNLPAdapter& nmpc_tnlp_adapter,
    4746                                                        PDSystemSolver& pd_solver);
    4847
  • trunk/Ipopt/contrib/sIPOPT/src/SensDenseGenSchurDriver.cpp

    r1982 r1984  
    1 // Copyright 2009 Hans Pirnay
     1// Copyright 2009, 2011 Hans Pirnay
    22// All Rights Reserved.
    33// This code is published under the Eclipse Public License.
     
    1414#endif
    1515
    16   IFTSchurDriver::IFTSchurDriver(SmartPtr<AsBacksolver> backsolver,
    17                                 SmartPtr<PCalculator> pcalc,
    18                                 SmartPtr<SchurData> data_B)
     16  DenseGenSchurDriver::DenseGenSchurDriver(SmartPtr<SensBacksolver> backsolver,
     17                                          SmartPtr<PCalculator> pcalc,
     18                                          SmartPtr<SchurData> data_B)
    1919    :
    2020    SchurDriver(pcalc,new IndexSchurData()),
     
    2222    S_(NULL)
    2323  {
    24     DBG_START_METH("IFTSchurDriver::IFTSchurDriver", dbg_verbosity);
     24    DBG_START_METH("DenseGenSchurDriver::DenseGenSchurDriver", dbg_verbosity);
    2525  }
    2626
    27   IFTSchurDriver::~IFTSchurDriver()
     27  DenseGenSchurDriver::~DenseGenSchurDriver()
    2828  {
    29     DBG_START_METH("IFTSchurDriver::~IFTSchurDriver", dbg_verbosity);
     29    DBG_START_METH("DenseGenSchurDriver::~DenseGenSchurDriver", dbg_verbosity);
    3030  }
    3131
    32   bool IFTSchurDriver::SchurBuild()
     32  bool DenseGenSchurDriver::SchurBuild()
    3333  {
    34     DBG_START_METH("IFTSchurDriver::SchurBuild", dbg_verbosity);
     34    DBG_START_METH("DenseGenSchurDriver::SchurBuild", dbg_verbosity);
    3535    /* This function is the very same as the one in DenseGenSchurDriver */
    3636    bool retval = true;
     
    4040    }
    4141    if (dim_S>0) {
    42     S_ = NULL;
    43     SmartPtr<DenseGenMatrixSpace> S_space = new DenseGenMatrixSpace(dim_S, dim_S);
    44     S_ = new DenseGenMatrix(GetRawPtr(S_space));
    45     SmartPtr<Matrix> S2 = GetRawPtr(S_);
    46     //retval = pcalc_nonconst()->GetSchurMatrix(GetRawPtr(data_B()), dynamic_cast<Matrix*>(GetRawPtr(S_)));
    47     retval = pcalc_nonconst()->GetSchurMatrix(data_B(), S2);
    48     S_->Print(Jnlst(),J_VECTOR,J_USER1,"S_");
     42      S_ = NULL;
     43      SmartPtr<DenseGenMatrixSpace> S_space = new DenseGenMatrixSpace(dim_S, dim_S);
     44      S_ = new DenseGenMatrix(GetRawPtr(S_space));
     45      SmartPtr<Matrix> S2 = GetRawPtr(S_);
     46      //retval = pcalc_nonconst()->GetSchurMatrix(GetRawPtr(data_B()), dynamic_cast<Matrix*>(GetRawPtr(S_)));
     47      retval = pcalc_nonconst()->GetSchurMatrix(data_B(), S2);
     48      S_->Print(Jnlst(),J_VECTOR,J_USER1,"S_");
    4949    }
    5050    return retval;
    5151  }
    5252
    53   bool IFTSchurDriver::SchurFactorize()
     53  bool DenseGenSchurDriver::SchurFactorize()
    5454  {
    55     DBG_START_METH("IFTSchurDriver::SchurFactorize", dbg_verbosity);
     55    DBG_START_METH("DenseGenSchurDriver::SchurFactorize", dbg_verbosity);
    5656    /* This function is the very same as the one in DenseGenSchurDriver */
    5757    bool retval;
     
    6464
    6565  /* The functions SchurSolve do IFT step, if S_==NULL, and DenseGenSchurDriver otherwise. */
    66   bool IFTSchurDriver::SchurSolve(SmartPtr<IteratesVector> lhs, // new left hand side will be stored here
    67                                   SmartPtr<const IteratesVector> rhs, // rhs r_s
    68                                   SmartPtr<Vector> delta_u,  // should be (u_p - u_0) WATCH OUT FOR THE SIGN! I like it this way, so that u_0+delta_u = u_p, but victor always used it the other way round, so be careful. At the end, delta_nu is saved in here.
    69                                   SmartPtr<IteratesVector> sol) // the vector K^(-1)*r_s which usually should have been computed before.
     66  bool DenseGenSchurDriver::SchurSolve(SmartPtr<IteratesVector> lhs, // new left hand side will be stored here
     67                                       SmartPtr<const IteratesVector> rhs, // rhs r_s
     68                                       SmartPtr<Vector> delta_u,  // should be (u_p - u_0) WATCH OUT FOR THE SIGN! I like it this way, so that u_0+delta_u = u_p, but victor always used it the other way round, so be careful. At the end, delta_nu is saved in here.
     69                                       SmartPtr<IteratesVector> sol) // the vector K^(-1)*r_s which usually should have been computed before.
    7070
    7171  {
    72     DBG_START_METH("IFTSchurDriver::SchurSolve", dbg_verbosity);
     72    DBG_START_METH("DenseGenSchurDriver::SchurSolve", dbg_verbosity);
    7373    DBG_ASSERT(IsValid(S_));
    7474    bool retval;
  • trunk/Ipopt/contrib/sIPOPT/src/SensDenseGenSchurDriver.hpp

    r1982 r1984  
    1 // Copyright 2009 Hans Pirnay
     1// Copyright 2009, 2011 Hans Pirnay
    22// All Rights Reserved.
    33// This code is published under the Eclipse Public License.
     
    1515{
    1616
    17   class IFTSchurDriver: public SchurDriver
     17  class DenseGenSchurDriver: public SchurDriver
    1818  {
    1919
    2020  public:
    2121
    22     IFTSchurDriver(SmartPtr<AsBacksolver> backsolver,
    23                    SmartPtr<PCalculator> pcalc,
    24                    SmartPtr<SchurData> data_B);
     22    DenseGenSchurDriver(SmartPtr<SensBacksolver> backsolver,
     23                        SmartPtr<PCalculator> pcalc,
     24                        SmartPtr<SchurData> data_B);
    2525
    26     virtual ~IFTSchurDriver();
     26    virtual ~DenseGenSchurDriver();
    2727
    2828    /** Creates the SchurMatrix from B and P */
     
    5656
    5757    /** DEPRECATED Performs a backsolve on S and K
    58     virtual bool SchurSolve(SmartPtr<IteratesVector> lhs,
    59                             SmartPtr<const IteratesVector> rhs,
    60                             SmartPtr<Vector> delta_u);
     58        virtual bool SchurSolve(SmartPtr<IteratesVector> lhs,
     59        SmartPtr<const IteratesVector> rhs,
     60        SmartPtr<Vector> delta_u);
    6161    */
    6262  private:
    6363    SmartPtr<SchurData> ift_data_;
    64     SmartPtr<AsBacksolver> backsolver_;
     64    SmartPtr<SensBacksolver> backsolver_;
    6565    SmartPtr<DenseGenMatrix> S_;
    6666
  • trunk/Ipopt/contrib/sIPOPT/src/SensIndexPCalculator.cpp

    r1982 r1984  
    1 // Copyright 2009 Hans Pirnay
     1// Copyright 2009, 2011 Hans Pirnay
    22// All Rights Reserved.
    33// This code is published under the Eclipse Public License.
     
    99#include "IpDenseVector.hpp"
    1010#include "IpDenseGenMatrix.hpp"
    11 //#include "IpDenseSymMatrix.hpp"
    1211#include "IpBlas.hpp"
    1312#include <vector>
     
    1918#endif
    2019
    21   IndexPCalculator::IndexPCalculator(SmartPtr<AsBacksolver> backsolver,
     20  IndexPCalculator::IndexPCalculator(SmartPtr<SensBacksolver> backsolver,
    2221                                     SmartPtr<SchurData> A_data)
    23   :
     22    :
    2423    PCalculator(backsolver, A_data),
    2524    nrows_(0),
     
    8281        col_values = new Number[nrows_];
    8382        curr_dim = 0;
    84          for (Index j=0; j<sol_vec->NComps(); ++j) {
    85            comp_vec = dynamic_cast<const DenseVector*>(GetRawPtr(sol_vec->GetComp(j)));
    86            comp_values = comp_vec->Values();
    87            IpBlasDcopy(comp_vec->Dim(), comp_values, 1, col_values+curr_dim,1);
    88            curr_dim += comp_vec->Dim();
    89          }
    90          cols_[col] = new PColumn(nrows_, col_values);
    91          col_values = NULL;
     83        for (Index j=0; j<sol_vec->NComps(); ++j) {
     84          comp_vec = dynamic_cast<const DenseVector*>(GetRawPtr(sol_vec->GetComp(j)));
     85          comp_values = comp_vec->Values();
     86          IpBlasDcopy(comp_vec->Dim(), comp_values, 1, col_values+curr_dim,1);
     87          curr_dim += comp_vec->Dim();
     88        }
     89        cols_[col] = new PColumn(nrows_, col_values);
     90        col_values = NULL;
    9291      }
    9392      curr_schur_row++;
     
    129128    }
    130129    /*
    131     DenseGenMatrix* dS = static_cast<DenseGenMatrix*>(&S);
    132     DBG_ASSERT(dynamic_cast<const DenseGenMatrix*>(&S));
     130      DenseGenMatrix* dS = static_cast<DenseGenMatrix*>(&S);
     131      DBG_ASSERT(dynamic_cast<const DenseGenMatrix*>(&S));
    133132    */
    134133    // Check whether data_A was changed from the outside
    135134    if (ncols_!=data_A()->GetNRowsAdded()) {
    136           ncols_ = data_A()->GetNRowsAdded();
    137           ComputeP();
     135      ncols_ = data_A()->GetNRowsAdded();
     136      ComputeP();
    138137    }
    139138    /*
    140     DBG_ASSERT(dS->NRows()==dS->NCols());
    141     DBG_ASSERT(dS->NRows()==data_A()->GetNRowsAdded());
     139      DBG_ASSERT(dS->NRows()==dS->NCols());
     140      DBG_ASSERT(dS->NRows()==data_A()->GetNRowsAdded());
    142141    */
    143142    std::vector<Index> indices;
  • trunk/Ipopt/contrib/sIPOPT/src/SensIndexPCalculator.hpp

    r1982 r1984  
    1 // Copyright 2009 Hans Pirnay
     1// Copyright 2009, 2011 Hans Pirnay
    22// All Rights Reserved.
    33// This code is published under the Eclipse Public License.
     
    2222  public:
    2323
    24     IndexPCalculator(SmartPtr<AsBacksolver> backsolver,
     24    IndexPCalculator(SmartPtr<SensBacksolver> backsolver,
    2525                     SmartPtr<SchurData> A_data);
    2626
     
    7777
    7878#endif
    79 
  • trunk/Ipopt/contrib/sIPOPT/src/SensIndexSchurData.cpp

    r1982 r1984  
    1 // Copyright 2009 Hans Pirnay
     1// Copyright 2009, 2011 Hans Pirnay
    22// All Rights Reserved.
    33// This code is published under the Eclipse Public License.
     
    269269
    270270  void IndexSchurData::PrintImpl(const Journalist& jnlst,
    271                               EJournalLevel level,
    272                               EJournalCategory category,
    273                               const std::string& name,
    274                               Index indent,
    275                               const std::string& prefix) const
     271                                EJournalLevel level,
     272                                EJournalCategory category,
     273                                const std::string& name,
     274                                Index indent,
     275                                const std::string& prefix) const
    276276  {
    277277    DBG_START_METH("IndexSchurData::PrintImpl", dbg_verbosity);
  • trunk/Ipopt/contrib/sIPOPT/src/SensIndexSchurData.hpp

    r1982 r1984  
    1 // Copyright 2009 Hans Pirnay
     1// Copyright 2009, 2011 Hans Pirnay
    22// All Rights Reserved.
    33// This code is published under the Eclipse Public License.
  • trunk/Ipopt/contrib/sIPOPT/src/SensMeasurement.hpp

    r1981 r1984  
    1919  class Measurement : public ReferencedObject
    2020  {
    21     /** This class provides an abstraction for the measurements of the states coming in 
     21    /** This class provides an abstraction for the measurements of the states coming in
    2222     *  and the solutions of the controller. It basicall acts as the "plant" of the controller. */
    2323  public:
    24    
     24
    2525    Measurement()
    2626    {
     
    3131    }
    3232
    33     /** This function returns a std::vector holding the indices in IteratesVector of the 
    34      *  equations that are to be "slacked" to free the initial values for the NMPC.
     33    /** This function returns a std::vector holding the indices in IteratesVector of the
     34     *  equations that are to be "slacked" to free the initial values for sIPOPT.
    3535     *  This std::vector is used in the construction of the A-SchurData for the Schur Decomposition. */
    3636    virtual std::vector<Index> GetInitialEqConstraints() =0;
    3737
    38     /** This function returns a std::vector holding the indices of the variables indexed 
     38    /** This function returns a std::vector holding the indices of the variables indexed
    3939     *  as sens_state_i */
    4040    virtual std::vector<Index> GetNmpcState(Index i) =0;
     
    4343    virtual SmartPtr<DenseVector> GetMeasurement(Index measurement_number) =0;
    4444
    45     /** This function does whatever the measurement machine does with the solution of the AsNmpController */
     45    /** This function does whatever the measurement machine does with the solution of the SensAlgorithm */
    4646    virtual void SetSolution(Index measurement_number, SmartPtr<IteratesVector> sol) =0;
    4747  };
     
    4949
    5050#endif
    51 
  • trunk/Ipopt/contrib/sIPOPT/src/SensMetadataMeasurement.hpp

    r1983 r1984  
    1 // Copyright 2009 Hans Pirnay
     1// Copyright 2009, 2011 Hans Pirnay
    22// All Rights Reserved.
    33// This code is published under the Eclipse Public License.
  • trunk/Ipopt/contrib/sIPOPT/src/SensPCalculator.hpp

    r1982 r1984  
    1 // Copyright 2009 Hans Pirnay
     1// Copyright 2009, 2011 Hans Pirnay
    22// All Rights Reserved.
    33// This code is published under the Eclipse Public License.
     
    2929  public:
    3030
    31     PCalculator(SmartPtr<AsBacksolver> backsolver,
     31    PCalculator(SmartPtr<SensBacksolver> backsolver,
    3232                SmartPtr<SchurData> A_data)
    3333      :
     
    8989     *  kind of dangerous but I don't think there is a way around it. Anyway,
    9090     *  there is no difference between this and the IpData() method of AlgStrategy.*/
    91     SmartPtr<AsBacksolver> Solver() const
     91    SmartPtr<SensBacksolver> Solver() const
    9292    {
    9393      return backsolver_;
     
    111111  private:
    112112
    113     SmartPtr<AsBacksolver> backsolver_;
     113    SmartPtr<SensBacksolver> backsolver_;
    114114
    115115    SmartPtr<const SchurData> data_A_init;
     
    123123
    124124#endif
    125 
  • trunk/Ipopt/contrib/sIPOPT/src/SensReducedHessianCalculator.cpp

    r1982 r1984  
    1 // Copyright 2009, 2010 Hans Pirnay
     1// Copyright 2009, 2011 Hans Pirnay
    22// All Rights Reserved.
    33// This code is published under the Eclipse Public License.
     
    2929
    3030  bool ReducedHessianCalculator::InitializeImpl(const OptionsList& options,
    31                               const std::string& prefix)
     31                                                const std::string& prefix)
    3232  {
    3333    DBG_START_METH("ReducedHessianCalculator::InitializeImpl", dbg_verbosity);
  • trunk/Ipopt/contrib/sIPOPT/src/SensReducedHessianCalculator.hpp

    r1982 r1984  
    1 // Copyright 2009, 2010 Hans Pirnay
     1// Copyright 2009, 2011 Hans Pirnay
    22// All Rights Reserved.
    33// This code is published under the Eclipse Public License.
  • trunk/Ipopt/contrib/sIPOPT/src/SensRegOp.cpp

    r1982 r1984  
    66//
    77// Authors:  Carl Laird, Andreas Waechter     IBM    2005-08-16
    8 // modified for AsNMPC by Hans Pirnay, 2009-07-22
     8// modified for sIPOPT by Hans Pirnay, 2009-07-22
    99
    1010#include "IpRegOptions.hpp"
     
    1313namespace Ipopt
    1414{
    15   void RegisterOptions_AsNMPC(const SmartPtr<RegisteredOptions>& roptions)
     15  void RegisterOptions_sIPOPT(const SmartPtr<RegisteredOptions>& roptions)
    1616  {
    1717    roptions->SetRegisteringCategory("Uncategorized");
    18     NmpcApplication::RegisterOptions(roptions);
     18    SensApplication::RegisterOptions(roptions);
    1919  }
    2020
  • trunk/Ipopt/contrib/sIPOPT/src/SensRegOp.hpp

    r1981 r1984  
    1 // Copyright 2009 Hans Pirnay
     1// Copyright 2009, 2011 Hans Pirnay
    22// All Rights Reserved.
    33// This code is published under the Eclipse Public License.
     
    1313  class RegisteredOptions;
    1414
    15   void RegisterOptions_AsNMPC(const SmartPtr<RegisteredOptions>& roptions);
     15  void RegisterOptions_sIPOPT(const SmartPtr<RegisteredOptions>& roptions);
    1616
    1717} // namespace Ipopt
  • trunk/Ipopt/contrib/sIPOPT/src/SensSchurData.hpp

    r1981 r1984  
    1 // Copyright 2009, 2010 Hans Pirnay
     1// Copyright 2009, 2011 Hans Pirnay
    22// All Rights Reserved.
    33// This code is published under the Eclipse Public License.
    44//
    5 // Date   : 2009-05-06 
     5// Date   : 2009-05-06
    66
    77#ifndef __ASSCHURDATA_HPP__
     
    1919  {
    2020    /** This interface serves as a reference point for multiple classes
    21      *  that need to use SchurData (PCalculator, SchurDriver). It 
     21     *  that need to use SchurData (PCalculator, SchurDriver). It
    2222     *  declares as little as possible, so that SchurData implementations
    23      *  can be very special and fast. 
     23     *  can be very special and fast.
    2424     *
    2525     *  I have not decided yet if there are certain ways I want to impose
    26      *  that SchurData can be set. I will figure this out as soon as I 
    27      *  write the upstream classes that need to do that 
     26     *  that SchurData can be set. I will figure this out as soon as I
     27     *  write the upstream classes that need to do that
    2828     *
    2929     *  Nomenclature in this program is based on Victor Zavalas thesis. */
    30    
    31   public: 
     30
     31  public:
    3232
    3333    SchurData()  : initialized_(false), nrows_(0)
     
    6969    virtual void GetRow(Index i, IteratesVector& v) const = 0;
    7070
    71     /** Returns two vectors that are needed for matrix-vector 
    72      *  multiplication of B and P. 
     71    /** Returns two vectors that are needed for matrix-vector
     72     *  multiplication of B and P.
    7373     *  The index is the row, the first vector are the indices
    7474     *  of non-zero components, in this row of B,
     
    7878    /** Computes B*v with B in R(mxn) */
    7979    virtual void Multiply(const IteratesVector& v, Vector& u) const =0;
    80    
     80
    8181    /** Computes A*u with A in R(nxm), KKT in R(n,n) */
    8282    virtual void TransMultiply(const Vector& u, IteratesVector& v) const =0;
  • trunk/Ipopt/contrib/sIPOPT/src/SensSchurDriver.hpp

    r1982 r1984  
    1 // Copyright 2009, 2010 Hans Pirnay
     1// Copyright 2009, 2011 Hans Pirnay
    22// All Rights Reserved.
    33// This code is published under the Eclipse Public License.
     
    9595
    9696    /** Performs a backsolve on S and K; calls the latter with sol=K^(-1)*r_s=0
    97     virtual bool SchurSolve(SmartPtr<IteratesVector> lhs,
    98                             SmartPtr<const IteratesVector> rhs,
    99                             SmartPtr<Vector> delta_u) =0;
     97        virtual bool SchurSolve(SmartPtr<IteratesVector> lhs,
     98        SmartPtr<const IteratesVector> rhs,
     99        SmartPtr<Vector> delta_u) =0;
    100100    */
    101101  private:
  • trunk/Ipopt/contrib/sIPOPT/src/SensSimpleBacksolver.cpp

    r1982 r1984  
    1 // Copyright 2009, 2010 Hans Pirnay
     1// Copyright 2009, 2011 Hans Pirnay
    22// All Rights Reserved.
    33// This code is published under the Eclipse Public License.
     
    2626
    2727  bool SimpleBacksolver::InitializeImpl(const OptionsList& options,
    28                                    const std::string& prefix)
     28                                        const std::string& prefix)
    2929  {
    3030    DBG_START_METH("SimpleBackSolver::InitializeImpl",dbg_verbosity);
  • trunk/Ipopt/contrib/sIPOPT/src/SensSimpleBacksolver.hpp

    r1982 r1984  
    1 // Copyright 2009 Hans Pirnay
     1// Copyright 2009, 2011 Hans Pirnay
    22// All Rights Reserved.
    33// This code is published under the Eclipse Public License.
     
    66//
    77// Purpose : This is the same as IpSensitivityCalculator.hpp
    8 //           It implements the AsBacksolver Interface.
     8//           It implements the SensBacksolver Interface.
    99
    1010#ifndef __ASSIMPLEBACKSOLVER_HPP__
     
    1616
    1717namespace Ipopt {
    18   class SimpleBacksolver : public AsBacksolver
     18  class SimpleBacksolver : public SensBacksolver
    1919  {
    2020  public:
  • trunk/Ipopt/contrib/sIPOPT/src/SensStdStepCalc.cpp

    r1982 r1984  
    1 // Copyright 2009, 2010 Hans Pirnay
     1// Copyright 2009, 2011 Hans Pirnay
    22// All Rights Reserved.
    33// This code is published under the Eclipse Public License.
     
    2020
    2121  StdStepCalculator::StdStepCalculator(SmartPtr<SchurData> ift_data,
    22                                        SmartPtr<AsBacksolver> backsolver)
     22                                       SmartPtr<SensBacksolver> backsolver)
    2323    :
    2424    ift_data_(ift_data),
  • trunk/Ipopt/contrib/sIPOPT/src/SensStdStepCalc.hpp

    r1982 r1984  
    1 // Copyright 2009, 2010 Hans Pirnay
     1// Copyright 2009, 2011 Hans Pirnay
    22// All Rights Reserved.
    33// This code is published under the Eclipse Public License.
     
    2020  public:
    2121    StdStepCalculator(SmartPtr<SchurData> ift_data,
    22                       SmartPtr<AsBacksolver> backsolver);
     22                      SmartPtr<SensBacksolver> backsolver);
    2323
    2424    virtual ~StdStepCalculator();
     
    3737  private:
    3838    SmartPtr<SchurData> ift_data_;
    39     SmartPtr<AsBacksolver> backsolver_;
     39    SmartPtr<SensBacksolver> backsolver_;
    4040    Number bound_eps_;
    4141    bool kkt_residuals_;
  • trunk/Ipopt/contrib/sIPOPT/src/SensStepCalc.hpp

    r1982 r1984  
    1 // Copyright 2009 Hans Pirnay
     1// Copyright 2009, 2011 Hans Pirnay
    22// All Rights Reserved.
    33// This code is published under the Eclipse Public License.
     
    3535
    3636    virtual bool InitializeImpl(const OptionsList& options,
    37                         const std::string& prefix)
     37                                const std::string& prefix)
    3838    {
    3939      options.GetBoolValue("sens_boundcheck", do_boundcheck_, prefix);
  • trunk/Ipopt/contrib/sIPOPT/src/SensSuffixHandler.hpp

    r1981 r1984  
    1 // Copyright 2009, 2010 Hans Pirnay
     1// Copyright 2009, 2011 Hans Pirnay
    22// All Rights Reserved.
    33// This code is published under the Eclipse Public License.
     
    2525    {
    2626    }
    27    
     27
    2828    virtual ~SuffixHandler()
    2929    {
    3030    }
    31    
     31
    3232    virtual std::vector<Index> GetIntegerSuffix(std::string suffix_string) =0;
    3333
  • trunk/Ipopt/contrib/sIPOPT/src/SensUtils.cpp

    r1982 r1984  
    1 // Copyright 2009 Hans Pirnay
     1// Copyright 2009, 2011 Hans Pirnay
    22// All Rights Reserved.
    33// This code is published under the Eclipse Public License.
     
    110110  }
    111111}
    112 
  • trunk/Ipopt/contrib/sIPOPT/src/SensUtils.hpp

    r1981 r1984  
    1 // Copyright 2009 Hans Pirnay
     1// Copyright 2009, 2011 Hans Pirnay
    22// All Rights Reserved.
    33// This code is published under the Eclipse Public License.
     
    2020
    2121
    22   enum NmpControllerExitStatus{
     22  enum SensAlgorithmExitStatus{
    2323    SOLVE_SUCCESS,
    2424    FATAL_ERROR
     
    3131  void append_Index(std::string& str, Index idx);
    3232
    33   SolverReturn AppReturn2SolverReturn(ApplicationReturnStatus ipopt_retval); 
     33  SolverReturn AppReturn2SolverReturn(ApplicationReturnStatus ipopt_retval);
    3434}
    3535
Note: See TracChangeset for help on using the changeset viewer.