Open grgmiller opened 1 year ago
After looking into the math a bit more, it looks like perhaps the input value of x
is in per unit on system base quantities, and the calculated output of x_pu
is in per unit on 1 MVA base (per the calculations happening here: https://github.com/PyPSA/PyPSA/blob/b066cb5d7af7b30861a2b76e486ec3910778e9c9/pypsa/pf.py#L1023).
However, this calculation is dividing x
by s_nom
, which in the documentation is defined as the transformer rating, not the system base MVA.
According to the documentation and https://github.com/PyPSA/PyPSA/blob/master/pypsa/component_attrs/transformers.csv, the input values of
x
,r
,g
, andb
for transformers are supposed to entered as per unit values, even though these same parameters for lines are entered as nominal values.What's more confusing, the transformer component also includes output values of
x_pu
,r_pu
,g_pu
, andb_pu
, which are calculated from the input values ofx
,r
,g
, andb
, which are already supposedly supposed to be pu values.Maybe I am misunderstanding something here, but this seems to suggest that: 1) the documentation includes the incorrect expected units for the input values, and/or 2) The input values are misnamed (should include the
_pu
suffix), and/or 3) The output _pu values are being incorrectly calculated.