Hello,
I am not used with CPLEX thus in other softwares this problem never happened to me, let me see if you might know how i can do this:
I am using a objective function that uses a binary decision variable lets say Y[i][j]
My objective function (maximization) will calculate a price if there Y exists in [i][j], this is Y[i][j] * Price, but will discount a penalty if Y exists in i+1[j], this is Yi+1[j] * Penalty. In the end the function would be something like:
maximize sum (i in days, j in years) Y[i][j] * Price  Yi+1[j] * Penalty
But this brings an error: operator not available for string +int
if I use Y[i][j] * Price  Y[i][j] * Penalty (no i+1) the optimization runs smoothly.
days is defined as a string, {string} Days =...; and is associated with a excel table something like this C2:E2 (monday, tuesday, sunday). Might this be the problem, to have the index as a string and therefore not possible to calculate the i+1?
How can I implement this?
Also I was told about a next() function that might help me on this. Can I implement it inside the objective/decision function?
Thank you for the help.
Topic

Re: help with objective function (operator not available for string +int)
20130326T08:01:36ZThis is the accepted answer. This is the accepted answer.Hi,
indeed next could help you, it will give you the next one in a string set like the days in the week.
But you may also use the function ord that will turn Monday into its rank in the set. To do the opposite, ie turn a rank in an element you may then use item.
All those keywords are in the documentation.
I hope this helps.
Regards 
Re: help with objective function (operator not available for string +int)
20130326T11:17:25ZThis is the accepted answer. This is the accepted answer. AlexFleischer
 20130326T08:01:36Z
Hi,
indeed next could help you, it will give you the next one in a string set like the days in the week.
But you may also use the function ord that will turn Monday into its rank in the set. To do the opposite, ie turn a rank in an element you may then use item.
All those keywords are in the documentation.
I hope this helps.
Regards
Thank you. 
Re: help with objective function (operator not available for string +int)
20130327T11:41:31ZThis is the accepted answer. This is the accepted answer. SystemAdmin
 20130326T11:17:25Z
I will check on these and Will get back to let you know if I could manage my problem with.
Thank you.
I will open a new question thread with some futher questions with a better subject so other people might find it.
I hope you can check this threat I will create since it regards your suggested functions.
Best regards,
Marco Amorim