Download Latest Version (1.0)
400k .zip (Windows)
412k tar.gz (Linux / Unix)


a simplified java wrapper for linear and mixed integer programming





“Do I want this?” Intro & Quick Usage Example
Installation Instructions
Online Reference (JavaDoc)

What is JOpt?

JOpt is an open source Java wrapper that provides objects like Variable, Constraint, and Term and lets you express your linear or mixed integer programs in a natural manner, while remaining agnostic to the details of the solver backend. JOpt is not a solver. Rather, it requires a solver such as CPlex to operate. In the future, we aim to provide backend support for at least one free solver, such as hooks into the GNU Linear Programming Kit, etc. This means that any program written with JOpt will work regardless of the solver actually licensed or downloaded by the end user.

JOpt also provides a round-robin load balancer. If you solve multiple concurrent LP/MIPs, and have access to multiple machines with a solver, JOpt can take advantage of your setup to get a linear speed increase.

Why JOpt?

Still not sure if you want this? Click on this short introduction (with pictures!) to see how it works...
Otherwise: * Download * Installation Instructions * Online Reference (JavaDoc)

Instructions

Setup (CPLEX 8.0 or higher users)

Install solver.

Per the CPLEX for Java Manual (in your CPLEX 8.0 or higher installation), add cplex.jar to your classpath, and add the directory containing the CPLEX shared library to your java.library.path environment variables.

Setup (Load balancing for all solvers)

To be written.



FAQ

CPLEX

Q1. When I run, I see the following:

java.lang.UnsatisfiedLinkError: no cplexXX in java.library.path
java.library.path must point to the directory containing the CPLEX shared library
try invoking java with java -Djava.library.path=...
java.lang.UnsatisfiedLinkError: CPXopenCPLEX
at ilog.cplex.Cplex.CPXopenCPLEX(Native Method)
at ilog.cplex.CplexI.init(CplexI.java:3601)
at ilog.cplex.CplexI.<init>(CplexI.java:287)
at ilog.cplex.IloCplex.<init>(IloCplex.java:8556)
at
edu.harvard.econcs.jopt.solver.impl.CPlexMIPSolver.solve(CPlexMIPSolver.java:40)
at (etc)

A1. This is a CPLEX installation issue. Make sure that you have installed more than just the static CPLEX library during CPLEX installation. Then, make sure you are running Java with something like: -Djava.library.path=C:\ILOG\cplex81\bin\msvc6