pwrs.power_models.costs#

Generator and DC-line cost parsing shared by optimization backends.

class pwrs.power_models.costs.PiecewiseLinearGeneratorCost(points)[source]#

Bases: object

Convex PWL points with power coordinates in per unit.

Parameters:

points (ndarray)

class pwrs.power_models.costs.PolynomialGeneratorCost(coefficients)[source]#

Bases: object

Descending polynomial coefficients evaluated against generator MW.

Parameters:

coefficients (ndarray)

pwrs.power_models.costs.dcline_costs(network)[source]#

Parse active DC-line from-side costs into backend-neutral data.

Parameters:

network (PowerNetwork)

Return type:

tuple[GeneratorCost, …]

pwrs.power_models.costs.generator_costs(network)[source]#

Parse active-generator cost rows into validated backend-neutral data.

Parameters:

network (PowerNetwork)

Return type:

tuple[GeneratorCost, …]