pypowsybl.network.Network.reduce_by_voltage_range¶
- Network.reduce_by_voltage_range(v_min=0, v_max=1.7976931348623157e+308, with_boundary_lines=False, with_dangling_lines=None)[source]¶
Reduce to a smaller network (only keeping all elements whose nominal voltage is in the specified voltage range)
- Parameters:
v_min (float) – minimum voltage of the voltage levels kept after reducing
v_max (float) – voltage maximum of the voltage levels kept after reducing
with_boundary_lines (bool) – whether boundary lines should be created to replace lines cut at the boundary of reduction
with_dangling_lines (bool | None) – deprecated, use with_boundary_lines instead
- Return type:
None
Example
network.reduce_by_voltage_range(v_min=90, v_max=250, with_boundary_lines=True)
will only keep elements of voltage level between 90 and 250kV, replacing the lines cut at the boundary by boundary lines.