#### 3.3 Generators

A generator is modeled as a complex power injection at a speciﬁc bus. For generator ,
the injection is

| (3.4) |

Let be the vector of these generator injections. The MW and
MVAr equivalents (before conversion to p.u.) of and are speciﬁed in columns PG
(2) and QG (3), respectively of row of the gen matrix. A sparse generator
connection matrix can be deﬁned such that its element is 1 if generator is
located at bus and 0 otherwise. The vector of all bus injections from
generators can then be expressed as

| (3.5) |

A generator with a negative injection can also be used to model a dispatchable
load.