Building data structures differently

Explains how to tune the way data structures inside a model are built.

A way of using less memory is to tune the way the data structures inside a model are built.

For instance, creating many intermediate arrays and sets that are not directly used in the model will increase memory. In addition, it is important to take advantage of proper modeling techniques; building a large, sparse, multi-dimensional array generally uses more memory than an equivalent set of tuples. Other treatments of sparsity and generic arrays are covered in greater detail in Modeling tips of the Language User’s Manual. In addition, IDE users can also use the Profiler tab of the Output window to identify constructs that use large amounts of memory; an example is given in Profiling the execution of a model of IDE Tutorials.

See also the white paper “Efficient Modeling in ILOG OPL-CPLEX Development System” available from the IBM ILOG web site for IBM ILOG OPL at: http://www-01.ibm.com/software/integration/optimization/cplex-optimization-studio/library/.