Bonmin::AmplInterface Class Reference

Class for providing an Osi interface to Ipopt with an ampl nl file as input. More...

#include <BonAmplInterface.hpp>

Inheritance diagram for Bonmin::AmplInterface:

Inheritance graph
[legend]
Collaboration diagram for Bonmin::AmplInterface:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 AmplInterface ()
 Default constructor no initialization.
 AmplInterface (const AmplInterface &other)
 Copy constructor.
virtual OsiSolverInterface * clone (bool CopyData=true)
 Clone.
virtual ~AmplInterface ()
 Destructor.
const AmplTMINLPamplModel () const
 Fast access to AmplTMINLP.
virtual void setAppDefaultOptions (Ipopt::SmartPtr< Ipopt::OptionsList > Options)
 To set some application specific defaults.
Methods to input a problem
virtual void readAmplNlFile (char **&argv, Ipopt::SmartPtr< Bonmin::RegisteredOptions > roptions, Ipopt::SmartPtr< Ipopt::OptionsList > options, Ipopt::SmartPtr< Ipopt::Journalist > journalist, std::string *nl_file_content=NULL)

Protected Member Functions

void readNames ()
 Read variables and row names in .col and .row files.

Protected Attributes

Ipopt::SmartPtr< Bonmin::AmplTMINLPamplTminlp_
 TMINLP problem (the original problem usually an AmplTMINLP).

Private Attributes

int writeAmplSolFile_
 Write the ampl solution file or write a bonmin one?

Detailed Description

Class for providing an Osi interface to Ipopt with an ampl nl file as input.

Definition at line 22 of file BonAmplInterface.hpp.


Constructor & Destructor Documentation

Bonmin::AmplInterface::AmplInterface (  ) 

Default constructor no initialization.

Definition at line 29 of file BonAmplInterface.cpp.

Referenced by clone().

Bonmin::AmplInterface::AmplInterface ( const AmplInterface other  ) 

Copy constructor.

Definition at line 34 of file BonAmplInterface.cpp.

References amplTminlp_.

Bonmin::AmplInterface::~AmplInterface (  )  [virtual]

Destructor.

Definition at line 47 of file BonAmplInterface.cpp.

References amplTminlp_.


Member Function Documentation

void Bonmin::AmplInterface::readAmplNlFile ( char **&  argv,
Ipopt::SmartPtr< Bonmin::RegisteredOptions roptions,
Ipopt::SmartPtr< Ipopt::OptionsList >  options,
Ipopt::SmartPtr< Ipopt::Journalist >  journalist,
std::string *  nl_file_content = NULL 
) [virtual]

Definition at line 53 of file BonAmplInterface.cpp.

References amplTminlp_, Bonmin::AmplTMINLP::createEmpty(), Bonmin::OsiTMINLPInterface::getNumCols(), Bonmin::AmplTMINLP::Initialize(), readNames(), and Bonmin::OsiTMINLPInterface::setStrParam().

OsiSolverInterface * Bonmin::AmplInterface::clone ( bool  CopyData = true  )  [virtual]

Clone.

Reimplemented in Bonmin::CouenneInterface.

Definition at line 41 of file BonAmplInterface.cpp.

References AmplInterface().

const AmplTMINLP* Bonmin::AmplInterface::amplModel (  )  const [inline]

Fast access to AmplTMINLP.

Definition at line 45 of file BonAmplInterface.hpp.

References amplTminlp_.

void Bonmin::AmplInterface::setAppDefaultOptions ( Ipopt::SmartPtr< Ipopt::OptionsList >  Options  )  [virtual]

To set some application specific defaults.

Reimplemented in Bonmin::CouenneInterface.

Definition at line 106 of file BonAmplInterface.cpp.

void Bonmin::AmplInterface::readNames (  )  [protected]

Read variables and row names in .col and .row files.

Definition at line 111 of file BonAmplInterface.cpp.

References Bonmin::NamesReader::copyNames(), Bonmin::OsiTMINLPInterface::getStrParam(), and Bonmin::NamesReader::readFile().

Referenced by readAmplNlFile().


Member Data Documentation

Ipopt::SmartPtr<Bonmin::AmplTMINLP> Bonmin::AmplInterface::amplTminlp_ [protected]

TMINLP problem (the original problem usually an AmplTMINLP).

Definition at line 57 of file BonAmplInterface.hpp.

Referenced by AmplInterface(), amplModel(), readAmplNlFile(), and ~AmplInterface().

int Bonmin::AmplInterface::writeAmplSolFile_ [private]

Write the ampl solution file or write a bonmin one?

Definition at line 61 of file BonAmplInterface.hpp.


The documentation for this class was generated from the following files:
Generated on Thu Aug 5 03:12:27 2010 by  doxygen 1.4.7