JuMP GLPK method solver

Hello,

I am trying to solve a linear problem using GLPK. I have already found a solution but I would like to know which method is being used by GLPK to solve the LP problem.

My call is:

model = Model(GLPK.Optimizer)
# Set variables and constraints
JuMP.optimize!(model)

Does JuMP tell GLPK to solve the problem using Simplex method by default? Does GLPK decide which method it will use?

Thanks in advance,

1 Like

It uses the simplex method by default:

https://github.com/jump-dev/GLPK.jl/blob/d11ae27aaa3666217786850c564aeffa138a6dac/src/MOI_wrapper/MOI_wrapper.jl#L130-L151

1 Like

Thank you very much! So if I would like to use another method, I would have to specify it manually, right?

1 Like

Yes

Thanks again :slight_smile:

1 Like

how do you specify it?

Hello nico,

As far as I know, there are only three possible methods: GLPK.jl/MOI_wrapper.jl at dee196eabbc87da2a3bfcf210e3ebe17b302a178 · jump-dev/GLPK.jl · GitHub

I haven’t used them myself but I guess you can specify them as:

model = GLPK.Optimizer(method = GLPK.XXX)

See the following function:

Regards,

shce

2 Likes

Thanks a lot!