The following lists changes since 3.13.4.
In particular users of the Ipopt/Pardiso interface should be aware of the highlighted backward-incompatible changes.
The documentation provides a list of deprecated types and functions. To disable C/C++ compiler warnings from using deprecated types or functions, add a #define IPOPT_DEPRECATED
before the include of Ipopt headers in your code.
Data Types
- Due to a contribution by Mitchell Clement [#428], it is now possible to build Ipopt in a variant that uses single-precision floating point arithmetic instead of the default double-precision.
This can be enabled by specifying the configure flag--with-precision=single
.
Doing so has a number of consequences on Ipopt interfaces and Ipopt dependencies.
See the Ipopt installation instructions for more details. - The name of all functions in
IpBlas.hpp
andIpLapack.hpp
has been changed to drop the precision-specifier "D" in the name.
Wrapper using the old names are available, but their use is deprecated. - It is now possible to build Ipopt in a variant that uses 64-bit integers for its
Index
type.
This can be enabled by specifying the configure flag--with-intsize=64
.
Doing so has a number of consequences on Ipopt interfaces and Ipopt dependencies.
See the Ipopt installation instructions for more details. [#259] - Added new header
IpTypes.h
that defines Ipopt types for integer and real numbers for C users. - Deprecated almost never used type
Ipopt::Int
, useint
instead. - Deprecated
Number
,Index
, andInt
(on global namespace) inIpStdCInterface.h
, useipnumber
,ipindex
, andint
instead, respectively. - Deprecated
Bool
inIpStdCInterface.h
and replaced it bybool
fromstdbool.h
. Note, thatBool
was defined to beint
, butbool
is likely a shorter type, e.g.,signed char
. DeprecatedTRUE
andFALSE
, usetrue
andfalse
instead. - Deprecated
IPOPT_EXPORT
macro and introducedIPOPT_CALLCONV
. - Deprecated
IPOPT_FORTRAN_INTEGER_TYPE
andipfint
. These were always assumed to beint
. Useipindex
oripopt::Index
instead.
Linear Solver Interfaces
- Due to a contribution by Byron Tasseff [#446], it is now possible to use the linear solver SPRAL (Sparse Parallel Robust Algorithms Library) with Ipopt.
SPRAL is open-source and can, optionally, make use of NVIDIA GPUs.
If Ipopt has been build with SPRAL, then optionlinear_solver
can be set tospral
to enable use of SPRAL.
See the installation instructions on how to build the Ipopt/SPRAL interface and the options documentation for new options that are available for the Ipopt/SPRAL interface. - Added
IpoptLinearSolvers.h
with functionIpoptGetAvailableLinearSolvers()
to retrieve information which linear solvers are available for Ipopt (linked in or loaded at runtime).
Optionslinear_solver
andlinear_system_scaling
can now only be set to values which corresponding code is available (linked in or for load at runtime). - Revised and streamlined implementation of feature that loads libraries with HSL or Pardiso routines at runtime.
Added optionshsllib
andpardisolib
to specify name of of HSL and Pardiso libraries, respectively. - Separated interfaces for Pardiso from pardiso-project.org and Pardiso from Intel MKL and allow to have both Pardiso versions available with the same Ipopt libraries.
- Pardiso from pardiso-project.org can be selected via
linear_solver=pardiso
.
configure option--with-pardiso
should now specify only a Pardiso library to be loaded at runtime (the value for--with-pardiso
decides the default value for optionpardisolib
).
To avoid conflicts with Pardiso from MKL, it is no longer possible to link against Pardiso from pardiso-project.org. - Pardiso from MKL can be selected via
linear_solver=pardisomkl
. - Options that influence Pardiso from MKL are named
pardisomkl_msglvl
,pardisomkl_order
, etc. - configure option
--disable-pardisomkl
can be used to disable the check for MKL Pardiso. [#454]
- Pardiso from pardiso-project.org can be selected via
- Fixed that return code (
info%flag
) ofma97_solve()
was not checked inMa97SolverInterface::MultiSolve()
. - Calls into MUMPS are now protected by a mutex if compiling for C++11 or higher.
This prevents Ipopt from calling MUMPS concurrently from several threads. - An insufficient memory return status is now also given if the memory required for a working space array of a linear solver exceeds the maximal value for the working space length variable, e.g., if MA27 requires a working space array of length higher than 2^31.
- Avoid floating point overflow when computing memory increase in interfaces to MA27 and MA57.
Algorithm
- Changed treatment of NLPs with all variables fixed and
fixed_variable_treatment
set tomake_parameter
:
Ipopt will still terminate early, but initialize its data structures first and print a solve summary (49a0d3a).
Changed treatment of NLPs with inconsistent variable bounds or constraint sides: These will now result in an invalid problem definition error (-11) (5cdb262).
As a consequence, solve statistics should now always be available if the return status from(Re)Optimize()
is larger than -10. - Bound multipliers are now computed for fixed variables if
fixed_variable_treatment
is set tomake_parameter
(the default).
This can trigger a reevaluating of the gradient of the objective function or the Jacobian of the constraint functions. If this is not desired, then optionfixed_variable_treatment
can be set to the new valuemake_parameter_nodual
. [#308] - Changed default for
honor_original_bounds
to no.
Variable bounds (see optionbound_relax_factor
) are now relaxed by at most the value ofconstr_viol_tol
.
The solve summary now reports the violation of original bounds andSolveStatistics::(Scaled)Infeasibilities()
has been extended to report the violation of original variable bounds. [#312] - If Ipopt hits a time or iteration limit during watchdog phase, the iterate from before the watchdog phase is now restored and passed to
finalize_solution
. Note that this does not apply if Ipopt is stopped due to a user-interrupt (intermediate_callback
). [#289] - When
BacktrackingLinesearch
could not find a trial point that provided sufficient progress, it may resort to call the feasibility restoration phase. If, however, the current (scaled) constraint violation was below tol/100, this would result in the infamous "Restoration phase is called at almost feasible point..." abort with status codeRestoration_Failure
. Now, this message has been changed to "Linesearch failed, but no restoration phase or other fall back is available." and the status code toError_In_Step_Computation
to better reflect that the linesearch failed and not the restoration phase. Further, the unscaled constraint violation tolerance now needs to be belowconstr_viol_tol/10
as well in order to trigger this abort. - When a square problem is solved and the restoration phase only succeeded to find a point that is feasible w.r.t. constr_viol_tol, but not w.r.t. tol, then status Feasible_Point_Found is returned now.
Ipopt interfaces
- Added
TNLP::get_curr_iterate()
andTNLP::get_curr_violations()
to request the current iterate (primal and dual variable values) and primal and dual infeasibility w.r.t. the TNLP. The methods are meant to be called duringintermediate_callback
to inspect the current iterate. The C, Fortran, and Java interfaces have been extended by corresponding functions, too. The hs071 examples have been extended to show use of the new functions. Added testgetcurr
to test new functions. [#382, #451] - Extended the Java interface by the possibility to specify an
intermediate_callback
. - Added flag to
TNLPAdapter::ResortX()
to specify how to handle fixed variables.
Added flag toTNLPAdapter::ResortG()
to specify whether to correct by right-hand-side of equality constraints.
AddedTNLPAdapter::ResortBoundMultipliers()
to generate correct duals for fixed variables iffixed_variable_treatment
ismake_constraint
.
AddedTNLPAdapter::GetFullDimensions()
,TNLPAdapter::GetFixedVariables()
,TNLPAdapter::GetPermutationMatrices()
, andTNLPAdapter::GetC_Rhs()
to retrieve more information of the transformation in aTNLPAdapter
. - Added
TNLPAdapter::ResortBounds()
and deprecatedTNLPAdapter::ResortBnds()
. AmplTNLP
constructor andAmplTNLP::get_options()
now expect to receive a pointer to aRegisteredOptions
object as well.
Previous versions of these methods are still available but deprecated.
Using a NULL pointer for theRegisteredOptions
argument is also deprecated.std::overflow_error
exceptions are now caught by Ipopt even if rethrowing of non-Ipopt exceptions is enabled.
Timing
- Added option
max_wall_time
to specify a wallclock time limit.
AddedSolverReturn
codeWALLTIME_EXCEEDED
andApplicationReturnStatus
codeMaximum_WallTime_Exceeded
. - Changed default for
max_cpu_time
to 1e20 to indicate no CPU timelimit. - Detailed timing statistics are no longer collected by default.
To reenable, set the new optiontiming_statistics
to yes or set the optionprint_timing_statistics
to yes [#299]. - Removed
IpoptData::ResetCpuStartTime()
. DeprecatedIpoptData::cpu_time_start()
, useIpoptData::TimingStats()::OverallAlgorithm()::StartCpuTime()
instead. - Deprecated
SolveStatistics::TotalCPUTime()
, useSolveStatistics::TotalCpuTime()
instead.
Option handling
- All Ipopt options are now also available via the AMPL interface, that is, can be set in AMPL via an option
ipopt_options "..."
statement. - Added flag "advanced" for
RegisteredOption
to store whether an option is rather meant for expert users. - Added class
RegisteredCategory
to store information on category of registered option. Next to the name, this is a priority, which determines the order in which categories are printed. As a consequence, methodsRegisteredOption::RegisteringCategory()
andRegisteredOptions::RegisteringCategory()
now return aRegisteredCategory
object instead of a string. Further,RegisteredOption::SetRegisteringCategory()
has been removed. - Deprecated existing
RegisteredOptions::OutputXyz()
methods and added new variant ofRegisteredOptions::OutputOptionDocumentation()
.
Added parameterprint_advanced_options
to indicate whether to print documentation for advanced options, too. - Added previously undocumented advanced options to options reference.
Miscellaneous
- Updated buildsystem, including improved checks for dependencies, use of current autotools, and skipping the build of intermediate non-distributed libraries.
- Fixed missing initialization of
IpoptApplication::smart_jnlst
in secondIpoptApplication
constructor, ifipopt verbosity > 0
. - Add GCC format attribute to
Journalist::Printf
functions to enableprintf
-formatter check. - Fixed
DenseVector::SumLogsImpl()
such that it returns 0.0 for a vector of dimension 0. Returnednan
for homogeneous 0-vector of dimension 0 before, which may have caused the restoration phase to fail for problems with only equality or only inequality constraints.
Also otherDenseVector
methods now skip calculations when dimension is 0 to avoid (probably harmless) divisions by zero. - Fixed a problem where moving slack away from 0 did not succeed when mu was very small. [#212]
- Fixed a problem where moving slacks away from 0 resulted in
nan
if multipliers were zero. AddedVector::ElementWiseSelect()
. - Various tiny bugfixes and improvements in performance and code style by following suggestions of
cppcheck
. - Added documentation on some available C preprocessor flags for expert users.
- Fixed static build of sIpopt without GCC. Fixed that installed sIpopt headers were not usable (
SIPOPTLIB_EXPORT
not defined). - Fixed wrong gradient of objective function and Lagrangian Hessian in restoration problem [#478, by Nai-Yuan Chiang].
- If Ipopt is compiled for checklevel 2 or higher and the GLIBC extension
feenableexcept()
is available, then floating-pointing exceptions divbyzero, overflow, and invalid are raised whileIpoptAlgorithm::Optimize()
is running. - Fixed that norm on unscaled complementarity or scaled complementarity tolerance were negative when maximizing (by using a negative scaling factor for the objective).
- Changed formula for relative error in derivative checker. The absolute error is now scaled up if the approximate derivative value is between derivative_test_tol and 1. [#487].
- The second-order derivative checker now uses values for obj_factor and lambda that are different from 1.