I have defined the following tuple:

tuple capacity3 
{
int sup; // varies from 1 to 5
int comp; // varies from 1 to 3
int peri; // varies from 1 to 6
int val3; // values corresponding to sup, comp, peri
}
{capacity3} aa=...;
I have written my tuple as

aa={<1,1,1,620>,<1,1,2,610>,<1,1,3,630>,<1,1,4,620>,<1,1,5,640>,<1,1,6,630>, ...and so on.

Now I have the following constraint;

forall(i in I, c in C, p in P)
      sum(j in J)X[i][j][c][p]<= RHS

At RHS, I need to write the value defined as val3 (620, 610 ....) in tuple corresponding to specific i,c and p which are defined as sup, comp and peri in my tuple.

How will I write my constraint i.e. value in pace of RHS ? or I am going wrong elsewhere also?

I am new to CPLEX.

asked 16 Jul '17, 10:29

Manjot's gravatar image

Manjot
111
accept rate: 0%

edited 17 Jul '17, 14:35

fbahr's gravatar image

fbahr ♦
4.6k716

2

... and answered there.

(18 Jul '17, 14:56) Paul Rubin ♦♦
Be the first one to answer this question!
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "Title")
  • image?![alt text](/path/img.jpg "Title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Tags:

×191
×41
×25
×13

Asked: 16 Jul '17, 10:29

Seen: 219 times

Last updated: 18 Jul '17, 14:56

OR-Exchange! Your site for questions, answers, and announcements about operations research.