Creating a collection of ordered tuple


#1

Hi All,

I am relatively new to Julia, moving from GAMS and AMPL. I am building a JuMP mode, for Distribution Optimal power Flow. The grid is mostly radial, so I am thinking of creating a collection of order tuples (branches, sending_node, receiving_node). This then permits me to write each branch voltage drop constraints as V(sending_node) - V(receiving_node) - r(branches)*i(branches) = 0, Where each branch has a sending node and receiving node.

I was thinking if I could create a bunch of ordered tuples, I can iterate these constraints over the indices present in the tuples.

Any ideas on how I can write this??

Thanks


#2

Hey @Sharabh_Shukla,

You can find documentation for JuMP here:
http://www.juliaopt.org/JuMP.jl/0.18/quickstart.html

There are also lots of examples on Github, for example:

You might also be interested in https://github.com/lanl-ansi/PowerModels.jl