Skip to content

Bus - Outputs

Output attributes are calculated by the optimization solver or power flow analysis. These values are read-only and represent the results of network calculations.

Basic

AttributeData TypeUnitDefaultRequiredStorage TypeDescription
controlstringn/aPQNostaticP,Q,V control strategy for PF, must be "PQ", "PV" or "Slack". Note that this attribute is an output inherited from the controls of the generators attached to the bus; setting it directly on the bus will not have any effect.
generatorstringn/an/aNostaticName of slack generator attached to slack bus.
sub_networkstringn/an/aNostaticName of connected sub-network to which bus belongs. This attribute is set by PyPSA in the function network.determine_network_topology(); do not set it directly by hand.

Electrical

AttributeData TypeUnitDefaultRequiredStorage TypeDescription
pfloatMW0Notimeseriesactive power at bus (positive if net generation at bus)
qfloatMVar0Notimeseriesreactive power (positive if net generation at bus)
v_mag_pufloatper unit1NotimeseriesVoltage magnitude, per unit of v_nom
v_angfloatradians0NotimeseriesVoltage angle

Costs

AttributeData TypeUnitDefaultRequiredStorage TypeDescription
marginal_pricefloatcurrency/MWh0NotimeseriesLocational marginal price from LOPF from power balance constraint

© Copyright 2025 Bayesian Energy