Optimization Programming Language (OPL)

The Optimization Programming Language (OPL) provides a natural mathematical description of optimization models. Using high-level syntax for mathematical models produces substantially simpler and shorter code than general-purpose programming languages, reducing the effort and improving the reliability of application development, upgrades, and maintenance. Its powerful syntax supports all expressions needed to model and solve problems using both mathematical programming and constraint programming.

OPL supports mathematical and constraint programming models and allows users to define decision variables and decision expressions over index sets to represent choices affected by them. Apart from this, users can also maximize or minimize an objective function of the decision expressions, switch between using the mathematical programming and constraint programming solvers simply by changing a single switch and utilize specialized data structures for formulating detailed scheduling models using constraint programming.

OPL users can develop, debug, test and tune math programming, constraint programming and constraint-based scheduling models. The ability to specify constraints, sums, and other mathematical operations over index sets is another important benefit. Users can utilize logical constraints that allow writing higher level, more powerful constraints using operators such as AND, OR, NOT, MIN, MAX and Absolute Value.

OPL Features

Advanced types for data organization

Define ranges, arrays, and sets of strings and numbers. Apply set operations to construct complex index sets. Define tuples, data structures comprising heterogeneous data elements, and sets of tuples, with optional primary and foreign keys. Use tuple slicing (similar to the SQL SELECT operation) to define sparse models that reduce both problem size and data requirements

Support for real or integer variables

Represent decisions involving quantities or amounts using real-number decision variables. Represent discrete choices or indivisible quantities using binary or integer decision variables. Utilize IBM ILOG CPLEX Optimizer’s mixed integer solver with sophisticated branch-and-cut search to solve difficult discrete optimization problems or use IBM ILOG CPLEX CP Optimizer to solve hard combinatorial problems less suited to mixed-integer optimization algorithms.

Represent detailed scheduling problems

Make use of OPL’s unique syntax and data structures to define problems in which timing is the fundamental decision. Use interval variables to represent activities, or tasks to be completed. Specify temporal constraints, relationships between the start and end times of the intervals, to represent precedence among activities. Define intensity and cumulative functions to represent resource usage as a function of time and specify resource constraints among intervals. 

 

Connect to relational databases and Excel spreadsheets

Import data and export optimal solutions to databases and Microsoft Excel spreadsheets. For Excel spreadsheets, use specified cell references or named ranges. For larger data sources, access major relational databases through SQL commands in an OPL data source. A clean separation of the model and the data values makes it easy to switch between data sources and migrate from test data to a production database.

Products

IBM ILOG CPLEX Optimization Studio

Develop and deploy optimization models quickly and identify the best possible actions that your users should take by using powerful and robust decision optimization algorithms

Resources

Introduction to IBM ILOG CPLEX Optimization Studio