Questions tagged [julia-jump]

JuMP is a domain-specific modeling language for mathematical programming embedded in the Julia language.

JuMP is a domain-specific modeling language for mathematical programming embedded in the Julia language.

https://github.com/JuliaOpt/JuMP.jl

362 questions
0
votes
1 answer

@NLConstraint with vectorized constraint JuMP/Julia

I am trying to solve a problem involving the equating of sums of exponentials. This is how I would do it hardcoded: @NLconstraint(m, exp(x[25])==exp(x[14])+exp(x[18])) This works fine with the rest of the code. However, when I try to do it for an…
Cuhrazatee
  • 101
  • 4
0
votes
1 answer

Julia MethodError: no method matching parseNLExpr_runtime(

I'm attempting to code the method described here to estimate production functions of metal manufacturers. I've done this in Python and Matlab, but am trying to learn Julia. spain_clean.csv is a dataset of log capital (lnk), log labor (lnl), log…
0
votes
1 answer

Getting incorrect values in JuMP

The following code is running correctly. However, when I call for the results one of the variables (utilizado) is returning incorrect values, only zeros. I know there is something I am making incorrectly but I don't know where. using JuMP, Clp m =…
Ushuaia81
  • 495
  • 1
  • 6
  • 14
0
votes
1 answer

Import a MutivariatePolynomials output into JuMP as a user defined function

I am trying import the output of a function from MultivariatePolynomials and use it into JuMp as a function. Below is the related code, which is part of a large system of NL equations. using JuMP using MultivariatePolynomials @polyvar k s θ_1k…
0
votes
1 answer

Unexpected error using Jump with Julia

I am trying to solve an optimization problem, I am getting error as "ERROR: Expected m to be a JuMP model, but it has type Int64 in validmodel(::Int64, ::Symbol) at C:\Users\Ting.julia\v0.5\JuMP\src\macros.jl:247 in macro expansion; at…
bhawesh sah
  • 103
  • 1
  • 10
0
votes
2 answers

Multi dimensional array in Gurobi/Jump/Julia

I am using Jump/Julia to solve an optimization problem. It is a transportation problem with some source locations and some destinations. Additionally, I have different product types so sending one kind of product from source i to destination j is…
bhawesh sah
  • 103
  • 1
  • 10
0
votes
0 answers

JuMP's objective function is called with NaN as argument

I want to minimize an objective function with JuMP involving a bessel function. The complete function is rather complex, and I do not have a derivative of this function. It seems that JuMP during the auto-derivation calls this function with…
Alex338207
  • 1,825
  • 12
  • 16
0
votes
0 answers

Quadratic Programming in Julia

Well, I have a quadratic programming optimization problem, well structured in Matlab. For instance, With x a n*1 vector, we have x = argmin (1/2*x'*H*x+f'*x) s.t. A*x <= b x_lb<=x<=x_ub Of course, A is a matrix and b, x_lb, x_ub are…
0
votes
2 answers

How to define a set in JuMP (JuliaOpt)

It should be easy, but it's almost 3 days that I'm trying to define a set in JuMP. Then, I need to set my variable y for each pair (i', i) belonging to the set O. O={(i,j): t[j] - t[i] + 30 < d[i,j]; i in D, j in K, i !=j } y[i,j]=0, for each (i,j)…
Francesco Clementi
  • 1,874
  • 4
  • 13
  • 28
0
votes
1 answer

Julia: global constrained optimization by minimizing an objective function

I am new to JULIA language and I am trying to perform a global optimization with constraints by minimizing an objective function RMSE by optimizing P1 and P2. I tried to run JumP algorithm but received many errors. I will be ever so grateful if you…
0
votes
1 answer

How to create an array of SD matrices?

How do you create an array of (variable)matrices A1,..,AN of semi definite matrices in Julia Jump where N is a parameter? @variable(model,x[1:N]) won't work because this is an array of variables, not of matrix variables. Thanks in advance.
0
votes
0 answers

Docker Julia dependency

Julia is installed on my host machine. Julia script runs very well from here. I invoke docker with shared Julia installation directories. Julia script is run from these shared directories within docker (i.e. there is no julia image inside docker). I…
Tims
  • 627
  • 7
  • 19
0
votes
0 answers

Error for Gradient of a multivariate NL function, using ForwardDiff

I am not able to obtain the gradient of a multivariate function using ForwardDiff, (Julia V.06) as shown in the code below: using ForwardDiff function…
ludo
  • 35
  • 9
0
votes
0 answers

How to modify variable attributes in JuMP?

I'm using Julia+JuMP and Gurobi to solve a MIP. Is it possible to modify variable attributes like BranchingPriority? So far, I only found methods in the documentation to modify model parameters. The only variable related modifications that seem to…
0
votes
2 answers

juMP - use variable defined in sum range

I am trying to define a constraint containing summation over two indices, k and t. for i in data.I for j in 1:length(data.P[i]) @constraint(m, w[i, j, length(data.T[data.P[i][j]])]/(1+sum(data.A[i][k][t] for k in 1:length(data.P[i]),…
dylee
  • 75
  • 6