- Main Page
- Namespaces
- Classes
- Files
- Related Pages

- Alphabetical List
- Class List
- Class Hierarchy
- Class Members

# KnitroProblem Class Reference

`#include <OSKnitroSolver.h>`

Collaboration diagram for KnitroProblem:

[legend]
List of all members.

## Public Member Functions
| KnitroProblem (OSInstance *osinstance_, OSResult *osresult_)
| the IpoptProblemclass constructor
virtual | ~KnitroProblem ()
| the IpoptProblem class destructor
int | getN (void)
int | getM (void)
void | getInitialX (double *const daX)
bool | loadProblemIntoKnitro (KTR_context_ptr kc)
| Define the fixed problem definition information and pass it to KNITRO by calling KTR_init_problem.
bool | areDerivativesImplemented (const DerivativesImplementedType nWhichDers)
int | evalFC (const double *const daX, double *const dObj, double *const daC, void *userParams)
int | evalGA (const double *const daX, double *const daG, double *const daJ, void *userParams)
int | evalH (const double *const daX, const double *const daLambda, double *const daH, void *userParams)
int | evalHV (const double *const daX, const double *const daLambda, double *const daHV, void *userParams)
## Public Attributes
OSResult * | osresult
OSInstance * | osinstance
std::string | knitroErrorMsg

## Detailed Description

Definition at line 87 of file OSKnitroSolver.h.

## Constructor & Destructor Documentation

KnitroProblem::KnitroProblem | ( | OSInstance * | osinstance_,
|  | OSResult * | osresult_ |
| ) |  |  |

the IpoptProblemclass constructor

Definition at line 184 of file OSKnitroSolver.cpp.

References osinstance, and osresult.

KnitroProblem::~KnitroProblem | ( |  | ) | `[virtual]`

the IpoptProblem class destructor

Definition at line 193 of file OSKnitroSolver.cpp.

## Member Function Documentation

int KnitroProblem::getN | ( | void |  | ) |

Definition at line 204 of file OSKnitroSolver.cpp.

int KnitroProblem::getM | ( | void |  | ) |

Definition at line 209 of file OSKnitroSolver.cpp.

void KnitroProblem::getInitialX | ( | double *const | daX | ) |

Definition at line 214 of file OSKnitroSolver.cpp.

bool KnitroProblem::loadProblemIntoKnitro | ( | KTR_context_ptr | kc | ) |

Define the fixed problem definition information and pass it to KNITRO by calling KTR_init_problem.

Definition at line 232 of file OSKnitroSolver.cpp.

References OSInstance::bUseExpTreeForFunEval, ErrorClass::errormsg, OSInstance::getConstraintLowerBounds(), OSInstance::getConstraintNumber(), OSInstance::getConstraintUpperBounds(), OSInstance::getJacobianSparsityPattern(), OSInstance::getObjectiveNumber(), OSInstance::getVariableLowerBounds(), OSInstance::getVariableNumber(), OSInstance::getVariableUpperBounds(), SparseJacobianMatrix::indexes, OSInstance::initForAlgDiff(), knitroErrorMsg, OSDBL_MAX, osinstance, SparseJacobianMatrix::starts, and SparseJacobianMatrix::valueSize.

bool KnitroProblem::areDerivativesImplemented | ( | const DerivativesImplementedType | nWhichDers | ) |

Definition at line 396 of file OSKnitroSolver.cpp.

int KnitroProblem::evalFC | ( | const double *const | daX,
|  | double *const | dObj,
|  | double *const | daC,
|  | void * | userParams |
| ) |  |  |

Definition at line 410 of file OSKnitroSolver.cpp.

References OSInstance::calculateAllConstraintFunctionValues(), OSInstance::calculateAllObjectiveFunctionValues(), ErrorClass::errormsg, knitroErrorMsg, and osinstance.

int KnitroProblem::evalGA | ( | const double *const | daX,
|  | double *const | daG,
|  | double *const | daJ,
|  | void * | userParams |
| ) |  |  |

Definition at line 446 of file OSKnitroSolver.cpp.

References OSInstance::calculateAllConstraintFunctionGradients(), OSInstance::calculateAllObjectiveFunctionGradients(), ErrorClass::errormsg, knitroErrorMsg, osinstance, and SparseJacobianMatrix::values.

int KnitroProblem::evalH | ( | const double *const | daX,
|  | const double *const | daLambda,
|  | double *const | daH,
|  | void * | userParams |
| ) |  |  |

Definition at line 488 of file OSKnitroSolver.cpp.

References OSInstance::calculateLagrangianHessian(), ErrorClass::errormsg, SparseHessianMatrix::hessValues, knitroErrorMsg, and osinstance.

int KnitroProblem::evalHV | ( | const double *const | daX,
|  | const double *const | daLambda,
|  | double *const | daHV,
|  | void * | userParams |
| ) |  |  |

Definition at line 515 of file OSKnitroSolver.cpp.

## Member Data Documentation

OSResult* KnitroProblem::osresult

Definition at line 96 of file OSKnitroSolver.h.

Referenced by KnitroProblem().

OSInstance* KnitroProblem::osinstance

Definition at line 98 of file OSKnitroSolver.h.

Referenced by evalFC(), evalGA(), evalH(), KnitroProblem(), and loadProblemIntoKnitro().

std::string KnitroProblem::knitroErrorMsg

Definition at line 127 of file OSKnitroSolver.h.

Referenced by evalFC(), evalGA(), evalH(), and loadProblemIntoKnitro().

The documentation for this class was generated from the following files:

- /home/coin/SVN-release/OS-2.3.5/OS/src/OSSolverInterfaces/OSKnitroSolver.h
- /home/coin/SVN-release/OS-2.3.5/OS/src/OSSolverInterfaces/OSKnitroSolver.cpp