Disciplined Nonlinear ProgrammingD. Cederberg, W. Zhang, P. Nobel, and S. Boyd
Manuscript, December 2025. We introduce disciplined nonlinear programming (DNLP), a syntax for specifying nonlinear programming problems, inspired by disciplined convex programming (DCP). In DNLP, smooth functions can be freely mixed with nonsmooth convex and concave functions, with some rules governing how the nonsmooth functions can be used. Problems expressed in DNLP form can be automatically compiled or canonicalized to a standard form for nonlinear programming (NLP), and then passed to a suitable NLP solver. As in DCP, the canonicalization relaxes nonsmooth convex and concave functions in a lossless way, allowing them to be handled by an NLP solver that requires smooth functions. In addition to extending NLP to include useful nondifferentiable convex and concave functions, there are several advantages to transforming the original problem to an equivalent one suitable for an NLP solver, including simpler problem initialization. We describe the language and our open-source implementation of DNLP as an extension of CVXPY, a parser for DCP. |