Optex.LP (Optex v0.1.0)

Copy Markdown View Source

CPLEX-LP-format emitter for an Optex.Model, using sanitized versions of the user-facing variable and constraint names, so the file stays readable.

This is a debugging/interop feature: the output can be inspected by hand or fed to any LP-reading solver. Names are sanitized to LP-safe identifiers (y[1] becomes y_1); collisions get an id suffix; unnamed variables and constraints fall back to x<id> / c<id>.

Summary

Functions

Emit an LP-format document for the given model. Models carrying native general constraints (indicators, abs) are not representable in this emitter's plain LP dialect and raise.

Functions

emit(m)

@spec emit(Optex.Model.t()) :: iodata()

Emit an LP-format document for the given model. Models carrying native general constraints (indicators, abs) are not representable in this emitter's plain LP dialect and raise.