Creating a Parameter from other Variables Topic is solved

Problems with modeling
Post Reply
mamba
User
User
Posts: 6
Joined: 3 years ago

Creating a Parameter from other Variables

Post by mamba »

Hello,
I have two different variables for example:
i set of product
let's say variables are production(i) and demand(i).
Can I create a parameter Inventory(i) from the equation below, do I need to specify that as a parameter or variable, I don't know how to implement on Gams. Can you help me about what to I do?

Inventory(i)=demand(i)-production(i)

Thank you for everything.
Best Regards
abhosekar
Moderator
Moderator
Posts: 295
Joined: 3 years ago

Re: Creating a Parameter from other Variables

Post by abhosekar »

For parameters, GAMS has to know the values before solving. As demand and production both are variables, you do not know the value of invenotry(i), which is why it has to be a variable.

- Atharv
mamba
User
User
Posts: 6
Joined: 3 years ago

Re: Creating a Parameter from other Variables

Post by mamba »

Hi Dear Atharv,
Thanks for the answer I understand very well you explained to me that in a very clear way and I appreciate that. Have a nice and healthy days.
Best Regards.
Post Reply