# \#cplex

**URL:** https://discourse.julialang.org/tag/cplex/604.md

[Latest](https://discourse.julialang.org/latest.md) · [Categories](https://discourse.julialang.org/categories.md) · [Tags](https://discourse.julialang.org/tags.md)

---

## [Why CPLEX’s Automatic Benders Outperforms Callback Benders in Julia?](https://discourse.julialang.org/t/why-cplex-s-automatic-benders-outperforms-callback-benders-in-julia/134440)

<div class="topic-metadata">

**Author:** [@ASUKaiwenFang](https://discourse.julialang.org/u/ASUKaiwenFang)\
**Replies:** 14\
**Last updated:** [July 11, 2026, 1:59pm UTC](https://discourse.julialang.org/t/why-cplex-s-automatic-benders-outperforms-callback-benders-in-julia/134440 "2026-07-11T13:59:35Z")

</div>

Hi all, I am trying to understand how to reproduce CPLEX’s automatic Benders decomposition using callbacks in Julia (via CPLEX.jl). CPLEX provides an automatic Benders mode, and the underlying procedure is described in …

---

## [Open source Solver to replace CPLEX in example?](https://discourse.julialang.org/t/open-source-solver-to-replace-cplex-in-example/137097)

<div class="topic-metadata">

**Author:** [@rt9f](https://discourse.julialang.org/u/rt9f)\
**Replies:** 6\
**Last updated:** [May 17, 2026, 8:03am UTC](https://discourse.julialang.org/t/open-source-solver-to-replace-cplex-in-example/137097 "2026-05-17T08:03:35Z")

</div>

Ten years ago this week, I read an article entitled Optimization in Julia. It was my first introduction to Julia and a great example of how easy one can define a constrained optimization problem in JuMP. The example used…

---

## [Using CPLEX Piecewise Linear function](https://discourse.julialang.org/t/using-cplex-piecewise-linear-function/28403)

<div class="topic-metadata">

**Author:** [@Codzilla](https://discourse.julialang.org/u/Codzilla)\
**Replies:** 8\
**Last updated:** [September 1, 2025, 10:48am UTC](https://discourse.julialang.org/t/using-cplex-piecewise-linear-function/28403 "2025-09-01T10:48:51Z")

</div>

I’m trying to solve a MILP with an piecewise linear function in the cost function. At the moment, i’m using a binairy variable per linear piece wich is not the state of the art (see for example http://www.mit.edu/~jvielm…

---

## [Solving a large scale MILP problem with cplex takes long time](https://discourse.julialang.org/t/solving-a-large-scale-milp-problem-with-cplex-takes-long-time/130491)

<div class="topic-metadata">

**Author:** [@JOHN1](https://discourse.julialang.org/u/JOHN1)\
**Replies:** 3\
**Last updated:** [July 6, 2025, 9:24pm UTC](https://discourse.julialang.org/t/solving-a-large-scale-milp-problem-with-cplex-takes-long-time/130491 "2025-07-06T21:24:44Z")

</div>

i am solving a large scale MILP problem with cplex, it takes too much time and cannot obtain the sollution, does it means that cplex is not suitable for this large scale MILP problem? what can i do to acceralate the solv…

---

## [CPU time vs Wallclock](https://discourse.julialang.org/t/cpu-time-vs-wallclock/114776)

<div class="topic-metadata">

**Author:** [@ShGE](https://discourse.julialang.org/u/ShGE)\
**Replies:** 11\
**Last updated:** [February 26, 2025, 5:41pm UTC](https://discourse.julialang.org/t/cpu-time-vs-wallclock/114776 "2025-02-26T17:41:07Z")

</div>

Hello there solve\_time does not return the CPU time even if I set set\_optimizer\_attribute(model, “CPXPARAM\_ClockType”, 1) # CPU clock time when using CPLEX. is there any way to get CPU time in Jump from whatever s…

---

## [Any plans to support cplex 22.1.2?](https://discourse.julialang.org/t/any-plans-to-support-cplex-22-1-2/126151)

<div class="topic-metadata">

**Author:** [@jpedro1992](https://discourse.julialang.org/u/jpedro1992)\
**Replies:** 0\
**Last updated:** [February 21, 2025, 1:59pm UTC](https://discourse.julialang.org/t/any-plans-to-support-cplex-22-1-2/126151 "2025-02-21T13:59:30Z")

</div>

Hi! Any plans regarding the support for cplex 22.1.2? I am having issues accessing IBM academic program to download a supported version by CPLEX.jl… Thanks!

---

## [Is there a package for monitoring Julia CPU mean usage?](https://discourse.julialang.org/t/is-there-a-package-for-monitoring-julia-cpu-mean-usage/117094)

<div class="topic-metadata">

**Author:** [@K5Julien](https://discourse.julialang.org/u/K5Julien)\
**Replies:** 2\
**Last updated:** [November 8, 2024, 10:57am UTC](https://discourse.julialang.org/t/is-there-a-package-for-monitoring-julia-cpu-mean-usage/117094 "2024-11-08T10:57:13Z")

</div>

Julia doesn’t seem to exist and thus doesn’t report CPU usage. I do not know if it is an issue related to the .sh script or to Julia Pardon-me if it is not Julia related, and let me know, I’ll ask StackExchange instead. …

---

## [Slow JuMP model creation](https://discourse.julialang.org/t/slow-jump-model-creation/122005)

<div class="topic-metadata">

**Author:** [@jakubp](https://discourse.julialang.org/u/jakubp)\
**Replies:** 3\
**Last updated:** [October 31, 2024, 5:52pm UTC](https://discourse.julialang.org/t/slow-jump-model-creation/122005 "2024-10-31T17:52:30Z")

</div>

I am trying to solve a very large (N=100M variables) and very sparse (density ~ 1/N) QUBO problem, using CPLEX interfaced via JuMP. To this end, I’m using the following function function solve\_with\_CPLEX(Q) L = size(…

---

## [Best way to generate vector of tuples based on two vectors](https://discourse.julialang.org/t/best-way-to-generate-vector-of-tuples-based-on-two-vectors/117687)

<div class="topic-metadata">

**Author:** [@K5Julien](https://discourse.julialang.org/u/K5Julien)\
**Replies:** 4\
**Last updated:** [July 31, 2024, 5:58pm UTC](https://discourse.julialang.org/t/best-way-to-generate-vector-of-tuples-based-on-two-vectors/117687 "2024-07-31T17:58:21Z")

</div>

The following does what I want, generate a vector of tuples thanks to the two vectors that I provide. xycoordinates = Tuple{Int,Int}\[(x,y) for x in collect(1:10), y in rand(1:10, 10)\] I wanted to know if there exists a…

---

## [Problem installing CPLEX.jl with CPLEX 22.1.1 on Mac OS](https://discourse.julialang.org/t/problem-installing-cplex-jl-with-cplex-22-1-1-on-mac-os/111967)

<div class="topic-metadata">

**Author:** [@mposs](https://discourse.julialang.org/u/mposs)\
**Replies:** 12\
**Last updated:** [March 25, 2024, 7:20am UTC](https://discourse.julialang.org/t/problem-installing-cplex-jl-with-cplex-22-1-1-on-mac-os/111967 "2024-03-25T07:20:23Z")

</div>

Hello I just installed CPLEX 22.1.1 poss@Mac-de-Michael x86-64\_osx % pwd /Applications/CPLEX\_Studio\_Community2211/cplex/bin/x86-64\_osx In configured CPLEX\_STUDIO\_BINARIES as requested: julia\> ENV\["CPLEX\_STUDIO\_BINARI…

---

## [Memory management in CPLEX.jl](https://discourse.julialang.org/t/memory-management-in-cplex-jl/109704)

<div class="topic-metadata">

**Author:** [@Matheus\_Diogenes\_And](https://discourse.julialang.org/u/Matheus_Diogenes_And)\
**Replies:** 9\
**Last updated:** [February 11, 2024, 11:28pm UTC](https://discourse.julialang.org/t/memory-management-in-cplex-jl/109704 "2024-02-11T23:28:12Z")

</div>

Hello. I am investigating a behavior related to the execution of CPLEX.jl. So, let’s consider the following environment: Linux pop-os 6.4.6-76060406-generic; And Julia version 1.8.4. And the following commands: juli…

---

## [Time to find the best solution in a mixed-integer linear programming model with JuMP](https://discourse.julialang.org/t/time-to-find-the-best-solution-in-a-mixed-integer-linear-programming-model-with-jump/106985)

<div class="topic-metadata">

**Author:** [@baprata](https://discourse.julialang.org/u/baprata)\
**Replies:** 2\
**Last updated:** [December 2, 2023, 10:28am UTC](https://discourse.julialang.org/t/time-to-find-the-best-solution-in-a-mixed-integer-linear-programming-model-with-jump/106985 "2023-12-02T10:28:53Z")

</div>

I am solving a mixed-integer linear programming model with JuMP and CPLEX. How could I measure the time required to find the best solution? Sometimes, the global optimal solution is found, but the solver continues the s…

---

## [Subtour elimination constraints](https://discourse.julialang.org/t/subtour-elimination-constraints/106902)

<div class="topic-metadata">

**Author:** [@Victor\_Neto](https://discourse.julialang.org/u/Victor_Neto)\
**Replies:** 15\
**Last updated:** [November 30, 2023, 1:58am UTC](https://discourse.julialang.org/t/subtour-elimination-constraints/106902 "2023-11-30T01:58:34Z")

</div>

Dear colleagues, I am studying the school bus routing problem: Redirecting. I am reproducing this mixed-integer linear programming formulation. However, I was replacing the sub-tour constraints (3) with a flow constrai…

---

## [Time to find the first feasible integer solution with JuMP](https://discourse.julialang.org/t/time-to-find-the-first-feasible-integer-solution-with-jump/106693)

<div class="topic-metadata">

**Author:** [@baprata](https://discourse.julialang.org/u/baprata)\
**Replies:** 2\
**Last updated:** [November 24, 2023, 11:05pm UTC](https://discourse.julialang.org/t/time-to-find-the-first-feasible-integer-solution-with-jump/106693 "2023-11-24T23:05:10Z")

</div>

I am solving a mixed-integer linear programming model with JuMP and CPLEX. How could I measure the time required to find the first feasible integer solution? Best regards, Bruno

---

## [Modeling constraints with CPLEXCP.jl](https://discourse.julialang.org/t/modeling-constraints-with-cplexcp-jl/102360)

<div class="topic-metadata">

**Author:** [@Matheus\_Diogenes\_And](https://discourse.julialang.org/u/Matheus_Diogenes_And)\
**Replies:** 3\
**Last updated:** [August 2, 2023, 9:17pm UTC](https://discourse.julialang.org/t/modeling-constraints-with-cplexcp-jl/102360 "2023-08-02T21:17:47Z")

</div>

Hello everyone. I am trying to model some constraints through constraint programming, by using CPLEXCP.jl. But I am having some issues with regards to translating the constraints into functions available by the library.…

---

## [Modeling Objective Function with CPLEXCP.jl](https://discourse.julialang.org/t/modeling-objective-function-with-cplexcp-jl/102336)

<div class="topic-metadata">

**Author:** [@Matheus\_Diogenes\_And](https://discourse.julialang.org/u/Matheus_Diogenes_And)\
**Replies:** 2\
**Last updated:** [August 1, 2023, 12:07pm UTC](https://discourse.julialang.org/t/modeling-objective-function-with-cplexcp-jl/102336 "2023-08-01T12:07:33Z")

</div>

Hello everyone. I am trying to use the CPLEXCP.jl. However, I am having some issues when using this library. Follows the code I am executing. This is the link of the github project. using CPLEXCP using MathOptInterface…

---

## [Cannot build CPLEX even with correct environment variable](https://discourse.julialang.org/t/cannot-build-cplex-even-with-correct-environment-variable/87234)

<div class="topic-metadata">

**Author:** [@Richard0416](https://discourse.julialang.org/u/Richard0416)\
**Replies:** 5\
**Last updated:** [June 8, 2023, 9:14pm UTC](https://discourse.julialang.org/t/cannot-build-cplex-even-with-correct-environment-variable/87234 "2023-06-08T21:14:33Z")

</div>

Hello! I am trying to add CPLEX to Julia. I download the latest version of CPLEX, 22.1 And also updated the CPLEX.jl package to the latest version, v0.9.4. When running Pkg.build(“CPLEX”), it seems that the path is wron…

---

## [Add local and purgeable cuts in CPLEX](https://discourse.julialang.org/t/add-local-and-purgeable-cuts-in-cplex/99378)

<div class="topic-metadata">

**Author:** [@Zacharie\_ALES](https://discourse.julialang.org/u/Zacharie_ALES)\
**Replies:** 4\
**Last updated:** [May 25, 2023, 7:48pm UTC](https://discourse.julialang.org/t/add-local-and-purgeable-cuts-in-cplex/99378 "2023-05-25T19:48:43Z")

</div>

I am using CPLEX.jl and I add cuts in a callback with this syntax: con = @build\_constraint(x \<= 0) MOI.submit(myModel, MOI.UserCut(cb\_data), con) CPLEX library normally has several parameters when addin…

---

## [Using CPLEX (solver dependent) callbacks for custom branching strategy in Julia](https://discourse.julialang.org/t/using-cplex-solver-dependent-callbacks-for-custom-branching-strategy-in-julia/99054)

<div class="topic-metadata">

**Author:** [@valdemarsoegaard](https://discourse.julialang.org/u/valdemarsoegaard)\
**Replies:** 6\
**Last updated:** [May 23, 2023, 7:01pm UTC](https://discourse.julialang.org/t/using-cplex-solver-dependent-callbacks-for-custom-branching-strategy-in-julia/99054 "2023-05-23T19:01:18Z")

</div>

Greetings! I am working on my master thesis on a large-scale flow problem, where I have implemented a surrogate model derived from a neural network in the form of a set of mixed integer linear constraints which replaces…

---

## [Job shop scheduling](https://discourse.julialang.org/t/job-shop-scheduling/96938)

<div class="topic-metadata">

**Author:** [@baprata](https://discourse.julialang.org/u/baprata)\
**Replies:** 4\
**Last updated:** [April 3, 2023, 12:52pm UTC](https://discourse.julialang.org/t/job-shop-scheduling/96938 "2023-04-03T12:52:40Z")

</div>

I am studying the mixed-integer linear programming formulation for the job shop with makespan minimization proposed by Manne (see Equations (1)-(7) from Ku and Beck (2016) http://dx.doi.org/10.1016/j.cor.2016.04.006, and…

---

## [Get all solution found by CPLEX.jl](https://discourse.julialang.org/t/get-all-solution-found-by-cplex-jl/89780)

<div class="topic-metadata">

**Author:** [@Luca](https://discourse.julialang.org/u/Luca)\
**Replies:** 1\
**Last updated:** [November 4, 2022, 6:16pm UTC](https://discourse.julialang.org/t/get-all-solution-found-by-cplex-jl/89780 "2022-11-04T18:16:45Z")

</div>

Dear all, I’m using CPLEX.jl to solve a MILP. I would like to retrieve all the solutions found by the solver. Do you have any advise or suggestion? Thanks very much. Bests.

---

## [JuMP and CPLEX - Setting number of threads](https://discourse.julialang.org/t/jump-and-cplex-setting-number-of-threads/83747)

<div class="topic-metadata">

**Author:** [@vmk97](https://discourse.julialang.org/u/vmk97)\
**Replies:** 4\
**Last updated:** [July 5, 2022, 12:56pm UTC](https://discourse.julialang.org/t/jump-and-cplex-setting-number-of-threads/83747 "2022-07-05T12:56:37Z")

</div>

I am trying to solve a mixed integer linear program by branch-and-cut using JuMP and CPLEX. I am having some trouble setting the number of threads for CPLEX. I am trying to set the parameter CPXPARAM\_Threads using set\_…

---

## [Using CPLEX populate method with JuMP](https://discourse.julialang.org/t/using-cplex-populate-method-with-jump/79973)

<div class="topic-metadata">

**Author:** [@MLainee](https://discourse.julialang.org/u/MLainee)\
**Replies:** 2\
**Last updated:** [April 25, 2022, 11:12am UTC](https://discourse.julialang.org/t/using-cplex-populate-method-with-jump/79973 "2022-04-25T11:12:22Z")

</div>

Greetings, I am currently using the CPLEX optimizer with the help of the JuMP package. In order to generate constraints for my model, I am currently using a function of the following type: using JuMP using CPLEX funct…

---

## [Early Stopping Using Float Cutoff on Dual](https://discourse.julialang.org/t/early-stopping-using-float-cutoff-on-dual/79516)

<div class="topic-metadata">

**Author:** [@chelseas](https://discourse.julialang.org/u/chelseas)\
**Replies:** 2\
**Last updated:** [April 15, 2022, 11:27pm UTC](https://discourse.julialang.org/t/early-stopping-using-float-cutoff-on-dual/79516 "2022-04-15T23:27:31Z")

</div>

I cannot figure out how to do the following. I would like for JuMP to stop once the dual bound (lower bound for minimization) is above some value. OR similarly, once the dual bound (upper bound for maximization) is belo…

---

## [JuMP optimize! used two much time and memory to solve a cplex model, do anyone knows why?](https://discourse.julialang.org/t/jump-optimize-used-two-much-time-and-memory-to-solve-a-cplex-model-do-anyone-knows-why/77966)

<div class="topic-metadata">

**Author:** [@yahengcui](https://discourse.julialang.org/u/yahengcui)\
**Replies:** 12\
**Last updated:** [April 1, 2022, 9:24pm UTC](https://discourse.julialang.org/t/jump-optimize-used-two-much-time-and-memory-to-solve-a-cplex-model-do-anyone-knows-why/77966 "2022-04-01T21:24:54Z")

</div>

I am solving cplex models using julia, while writing (in julia) the model (to .lp file) and solve the .lp file directly by cplex can be done in secs and mins, but when I want to solve the model directly in julia by using…

---

## [JuMP CPLEX attribute error for getting CPX\_PARAM\_INTSOLLIM](https://discourse.julialang.org/t/jump-cplex-attribute-error-for-getting-cpx-param-intsollim/77595)

<div class="topic-metadata">

**Author:** [@hideakiv](https://discourse.julialang.org/u/hideakiv)\
**Replies:** 2\
**Last updated:** [March 9, 2022, 3:41am UTC](https://discourse.julialang.org/t/jump-cplex-attribute-error-for-getting-cpx-param-intsollim/77595 "2022-03-09T03:41:58Z")

</div>

I am trying to get a CPLEX attribute of a model. I am using JuMP v0.21.10 and CPLEX v0.7.8. using JuMP, CPLEX m = Model() set\_optimizer(m, optimizer\_with\_attributes(CPLEX.Optimizer, "CPX\_PARAM\_INTSOLLIM" =\> 1)) get\_opt…

---

## [Serialized and deserialized JuMP CPLEX models are not the same](https://discourse.julialang.org/t/serialized-and-deserialized-jump-cplex-models-are-not-the-same/73194)

<div class="topic-metadata">

**Author:** [@filchristou](https://discourse.julialang.org/u/filchristou)\
**Replies:** 1\
**Last updated:** [December 16, 2021, 5:36pm UTC](https://discourse.julialang.org/t/serialized-and-deserialized-jump-cplex-models-are-not-the-same/73194 "2021-12-16T17:36:57Z")

</div>

I want to run some long simulations with JuMP. After the simulations ends, I will start with the metaanalysis. So what I wanted to do is store the solved model in the filesystem and analyze it afterwards. During my pre-…

---

## [User-cut with CPLEX](https://discourse.julialang.org/t/user-cut-with-cplex/71490)

<div class="topic-metadata">

**Author:** [@Matheus\_Diogenes\_And](https://discourse.julialang.org/u/Matheus_Diogenes_And)\
**Replies:** 2\
**Last updated:** [November 19, 2021, 4:23am UTC](https://discourse.julialang.org/t/user-cut-with-cplex/71490 "2021-11-19T04:23:28Z")

</div>

Greetings. This thread is related to this one. I am trying to use user-cut with JuMP 0.21.4, Julia 1.6.2, and CPLEX 12.10. Below follows the code I am running. using JuMP, CPLEX model = direct\_model(CPLEX.Optimizer())…

---

## [Save solution and warm start](https://discourse.julialang.org/t/save-solution-and-warm-start/70315)

<div class="topic-metadata">

**Author:** [@Brock](https://discourse.julialang.org/u/Brock)\
**Replies:** 1\
**Last updated:** [October 27, 2021, 4:50am UTC](https://discourse.julialang.org/t/save-solution-and-warm-start/70315 "2021-10-27T04:50:49Z")

</div>

I am using JuMP and CPLEX to solve an optimization problem. How can I save the best solution found after a certain time limit to a file? How can I then use this file as a warm start during another attempt to solve the …

---

## [JuMP only for formulation and CPLEX.jl (or Gurobi.jl) as callable library wrapper?](https://discourse.julialang.org/t/jump-only-for-formulation-and-cplex-jl-or-gurobi-jl-as-callable-library-wrapper/60662)

<div class="topic-metadata">

**Author:** [@rocarvaj](https://discourse.julialang.org/u/rocarvaj)\
**Replies:** 2\
**Last updated:** [May 6, 2021, 6:36pm UTC](https://discourse.julialang.org/t/jump-only-for-formulation-and-cplex-jl-or-gurobi-jl-as-callable-library-wrapper/60662 "2021-05-06T18:36:13Z")

</div>

Hello! I’ve read the documentation for both JuMP and CPLEX.jl (the readme page on Github) but I just want to be 100% if it is possible to do the following: Formulate a MILP (using only constraints supported by the sol…

[Next page](https://discourse.julialang.org/tag/cplex/604.md?match_all_tags=true&page=1&tags%5B%5D=cplex)
