The complex current at the end of each branch (transmission line or transformer) can be computed directly from the complex power and voltage (S = VI*), which are computed as part of the solution.
r = runpf(mycase); % for branch k, connecting bus i to bus j ... branch_k_from_current = (r.branch(k, PF) - sqrt(-1) * r.branch(k, QF)) / r.bus(i, VM) * exp(-r.bus(i, VA) * pi/180); branch_k_to_current = (r.branch(k, PT) - sqrt(-1) * r.branch(k, QT)) / r.bus(j, VM) * exp(-r.bus(j, VA) * pi/180); I think that's correct (double-check my formulas), though I haven't tested it. Hope this helps, -- Ray Zimmerman Senior Research Associate 419A Warren Hall, Cornell University, Ithaca, NY 14853 phone: (607) 255-9645 On Mar 14, 2013, at 2:48 AM, ahmad rezaee <[email protected]> wrote: > Dear Dr zimmerman > > Does Matpower compute currents of branches? What is the easiest way for > calculating them considering the fact its formulation for lines is different > from branches with transformers. > > Regards > > Ahmad
