Skip to main content

Hi AIMMS community! I’m currently working on a resource transport model using AIMMS and I've encountered a symmetry challenge for resource balance between zones.

In the case when I would like to transport 200MW of power from zone 1 to zone 2, the net outflow of power from zone 2 must be equal to the net inflow of power into zone 1, which can be represented by the equation below:

F_in (z,z’) = F_out (z, z’)

whereby F_in (z,z’) is represented as the net inflow into zone z (zone 1) from zone z’ (zone 2);

while F_out (z,z’) is represented as the net outflow from zone z (zone 2) to zone z’ (zone 1).

Does anyone know of an AIMMS function that can seamlessly handle this equation? Any insights or tips are highly appreciated! Thanks so much!

Not sure if I am understanding, but if you have variables defined in AIMMS like F_in(z,z2) and F_out(z,z2) you can just create a constraint powerConservation(z,z2) with the definition

F_in(z, z2) = F_Out(z,z2)

 

 


Thanks @gdiepen for your prompt response! However, my concern here is with the ‘z’ index as index ‘z’ and ‘z2’ in F_in is different from the index ‘z’ and ‘z2’ in F_out. May I know is there a specific function in AIMMS where the ordinal ‘z’ and ‘z2’ can be swapped for a certain variable?

For example: 

ord(z) = 1 while ord(z2) = 2 in F_in as the power is being transferred into zone 1 from zone 2. Hence, 

ord(z) = 2 while ord(z2) =1 in F_out as power is flowing out of zone 2 to zone 1. 

 

Thank you!


You can use ord and element functions in aimms to convert from and to ordinal values. 

 

Easier solution might be to make use of sets and subsets though and ensure you can use the same indices


Alright thanks @gdiepen! I’ll try that out. 


Reply


Didn't find what you were looking for? Try searching on our documentation pages:

AIMMS Developer & PRO | AIMMS How-To | AIMMS SC Navigator