pwrs.core.makeApq#

pwrs.core.makeApq.makeApq(baseMVA, gen, nargout=1)[source]#

Construct generator capability-curve linear constraints.

Builds the linear constraints Apqh * [Pg; Qg] <= ubpqh and Apql * [Pg; Qg] <= ubpql for trapezoidal generator capability curves.

Parameters:
  • baseMVA (float) – System power base.

  • gen (ndarray) – Generator matrix.

  • nargout (int, optional) – Number of outputs to emulate from the MATLAB interface.

Returns:

Returns (Apqh, ubpqh, Apql, ubpql, data) or the leading subset requested by nargout.

Return type:

tuple or sparse matrix

pwrs.core.makeApq.makeApq_full(baseMVA, gen)[source]#

Return all generator capability-curve constraint outputs.