I have to solve a problem with permutations. The function takes vector a with n elements as a parameter. I declare b as @variable - there should be the permutation 1:n that gives the best result after finding the solution of a problem.
The error appears when I want to create @constraint. I have to use a[b[1]], so it takes the first element from vector which is a variable. It gives my error, that I can't use type VariableRef as a index of an array. But how can I get around this when I have to use it?