Changelog¶
Unreleased¶
PR429 GH298 Add
rlf.plotting.voltage_profilefunction to plot the voltage profile of a network. The function returns an object withplot_matplotlib()andplot_plotly()methods to create plots using Matplotlib or Plotly respectively.PR427 Add missing transformer tap to the edge data in the graph generated by
ElectricalNetwork.to_graph.PR426 Add
rlf.plotting.plot_results_interactive_mapfor plotting a network with load flow results on an interactive map. Buses are colored according to their voltage levels and lines are colored according to their loading levels.PR425 Enforce the following deprecations:
The
sideparameter ofrlf.GroundConnection,rlf.plotting.plot_voltage_phasorsandrlf.plotting.plot_symmetrical_voltagesis removed. Pass a branch side directly instead (e.g.rlf.GroundConnection(ground=ground, element=transformer.side_hv)).The
potentialsattribute and and constructor parameter ofBusis removed. Useinitial_potentialsinstead.The
busof a disconnected load or source no longer returnsNone. Use the newis_disconnectedproperty to check if the load or source is disconnected.The
phaseparameter ofrlf.PotentialRefis removed. Usephasesinstead.The
res_voltages_hvandres_voltages_lvattributes ofrlf.Transformerare removed. Use<side>.res_voltagesinstead.Deprecated names in
rlf.constants,rlf.typesandrlf.symmodules are removed.Deprecated modules in the
rlf.utilspackage are removed. This package is for internal use only and should not be considered stable.
PR421 Improve initial voltage guesses in the Newton algorithm for networks involving delta connected sources.
PR419 PR420 Require Python 3.12 or newer and bump the minimum supported versions of some dependencies per SPEC-0.
PR418 Many improvements to the styles of interactive map plots:
Different voltage levels are represented with different marker sizes and line widths. Nominal voltages are used to determine the voltage levels automatically. If nominal voltages are not available, they are inferred from the transformers and sources
Underground lines are dashed while other lines are solid including lines with unknown line type
Transformers are now represented with a square icon with a divider in the middle and with both HV and LV buses information in the tooltip and popup
Sourcers are represented with a bigger square icon
If the new parameter
fit_boundsis set toTrue(default), the bounds of the map will be automatically adjusted usingfolium.FitOverlaysto fit the network elements.
Note that the markers of buses, transformers and sources now use the
folium.DivIconicon which means the style function must now return a style dictionary of the form{'html': ...}for these elements.PR413 Restore bus and layers to the layer control in the interactive map plot. This was broken in version 0.13.0.
PR404 Fix filtering catalogues using compiled regular expressions with newer versions of pandas.
Version 0.13.1¶
Fix a bug where license validation failed when the English (US) language was not installed on the system (observed on Linux).
PR408 Improve the display of C++ code error messages.
Version 0.13.0¶
PR402 Improve the
en.to_graphmethod.Add nominal voltage and min/max voltage levels as node attributes.
Change the
geomattribute to be a GeoJSON-like dictionary instead of a shapely geometry object. This makes the graph data JSON-serializable and compatible with pyviz plotting.
PR401 Rename some internal models modules. The models classes are always available as
rlf.<model_name>.PR400 Add
LineParameters.to_symmethod to convert three-phase line parameters to symmetrical components. The method returns the symmetrical components:z0,z1,y0,y1, and for lines with a neutral wire:zn,zpn,yn,ypn.PR399 Add popup and search functionality to the interactive map plot.
rlf.plotting.plot_interactive_mapnow acceptsadd_tooltips,add_popupsandadd_searcharguments to control the display of tooltips, popups and search features. These features are enabled by default.PR398 Improve the performance of accessing network results as dataframes by up to 20% and serializing a network to a dictionary by up to 15%. The improvements are mostly noticeable for large networks or when performing many simulations like in a time series analysis.
PR396 Allow passing a single
FlexibleParameterobject to a constant-power load to be used for all phases.PR395 Improve line and bus hover information in interactive map plots. Fix an error in automatic zoom calculation when the whole network is on the same longitude or latitude.
PR394 Add support for musl linux distributions. Also add preliminary support for python 3.14 development version and for free-threaded python 3.13t and 3.14t. Full support is waiting on our dependencies to release relevant wheels.
PR393 Use the
uv_buildbuild backend instead ofhatchlingto build the package.PR392 Disconnect a ground connection of a load or source when the load or source is disconnected from the network. Add
is_disconnectedproperty to loads, sources and ground connections to check if the element is disconnected. In the future, accessing the bus of a disconnected load or source will return the original bus instead ofNone, useis_disconnectedto check if the load or source is disconnected.PR391 GH390
ElectricalNetwork.to_graphnow returns a multi-graph to preserve parallel edges. It also gained arespect_switchesparameter that can be set toFalseto include open switches in the graph. The default value isTrue, which means that open switches are not included in the graph.PR389 Add support for open switches. Pass
closed=Falseto theSwitchconstructor to create an open switch. Callswitch.open()to open an existing switch andswitch.close()to close it.switch.closedtells if the switch is closed or not. The switch is closed by default.PR388 GH378 Add
ElectricalNetwork.tool_datato attach tool-specific data to the electrical network. The data is written to the JSON file when saving the network and is read when loading.PR387 Stop reformatting arrays in json output.
PR385 GH344 Add sides accessors to branches.
Transformer.side_hvandTransformer.side_lvreturn the high-voltage and low-voltage sides of a transformer.Line.side1andLine.side2return the two sides of a line.Switch.side1andSwitch.side2return the two sides of a switch.
A side is a bus connectable element and has all common attributes of bus connectables. For example,
Transformer.side_hvhas the attributesbus,phases,res_currents,res_powers,res_voltages, etc.Passing a branch element and a separate side argument to
rlf.GroundConnection,rlf.plotting.plot_voltage_phasorsandrlf.plotting.plot_symmetrical_voltagesis deprecated in favor of passing a branch side directly. For example, replacerlf.GroundConnection(ground=ground, element=transformer, side="HV")byrlf.GroundConnection(ground=ground, element=transformer.side_hv).PR382 Improve load flow convergence for networks with step-up transformers by improving the initial guesses for the voltages of the buses.
PR380 GH379 Fix error when neutral ampacity is not passed to
LineParameters.from_geometry.PR374 Rename the
from_dgsmethod ofrlf.ElectricalNetworktofrom_dgs_fileand add a newfrom_dgs_dictmethod to load a network from a DGS-formatted dictionary. The old method is deprecated and will be removed in a future release. Thefrom_dgs_filemethod accepts an optionalencodingparameter to specify the encoding of the DGS file.PR371 Deprecate
Transformer.res_voltage_hvandTransformer.res_voltage_lvproperties added in the last release by mistake. A simpler interface will be added later as described in GH344.PR369 Add
Line.res_ground_potentialproperty to get the potential of the ground port of lines with shunt components. Update JSON file format to version 5 to store this information. Files created with previous versions of Roseau Load Flow will still be readable and will warn on loading.PR366 Add nominal frequency (
fn), cooling class (cooling) and insulation type (insulation) to theTransformerParametersclass. The transformers catalogue has been updated accordingly. The manufacturer names in the catalogue have been expanded to better accommodate new transformers (SE->Schneider Electric,FT->France Transfo, …). More HV/MV transformers have been added to the catalogue. The cooling and insulation are described in the new enumeration typesTransformerCoolingandTransformerInsulationrespectively.PR365 Fix minor inconsistency in the calculation of short-circuit parameters of transformers with no open and short circuit tests data. The iron losses are now consistently ignored during the calculation of the short-circuit parameters.
PR364 GH363 Fix missing floating neutral of three-phase transformers when the bus does not have a neutral.
PR361 GH300 Raise an error when duplicate line or transformer parameters IDs are used in the same network.
PR360 GH359 Fix a bug related to adding short circuits to a bus when the ground fault was not already part of the electrical network.
PR358 Fix a division by zero error during DGS export.
PR357 Improve support for unbalance calculations.
The
res_voltage_unbalancemethod now accepts adefinitionparameter to choose between the definitions of the voltage unbalance from'VUF'(IEC),'PVUR'(IEEE) and'LVUR'(NEMA).Loads and sources now have a
res_current_unbalancemethod to compute the current unbalance.
PR356 Fix regression since version 0.11.0 where
max_voltage_levelfor buses was missing in the catalogue networks.
Version 0.12.0¶
Note
This is the last version of Roseau Load Flow to support Python 3.10.
See also
This release also includes the modifications that are in the version 0.12.0-alpha.
Breaking changes¶
The following columns have been renamed in
ElectricalNetwork.transformers_frame:bus1_id,bus2_id->bus_hv_id,bus_lv_idphases1,phases2->phases_hv,phases_lv
and the following columns have been renamed in
ElectricalNetwork.res_transformers:current1,current2->current_hv,current_lvpotential1,potential2->potential_hv,potential_lvvoltage1,voltage2->voltage_hv,voltage_lvpower1,power2->power_hv,power_lv
The
ElectricalNetwork.crsnow defaults toNone(no CRS) instead of"EPSG:4326". The attribute is also no longer normalized to apyproj.CRSobject but is stored as is. UseCRS(en.crs)to always get apyproj.CRSobject.
Detailed changes¶
A new experimental module named
roseau.load_flow_singlehas been added for studying balanced three-phase systems using the simpler single-line model. This module is unstable and undocumented, use at your own risk.Improvements of license validation, particularly during simultaneous use of multiple threads or processes.
PR351 GH332 Improved support of the network’s Coordinate Reference System (CRS).
The
CRSwill now default toNone(no CRS) instead of"EPSG:4326"if not provided.The
ElectricalNetwork.crsattribute is no longer normalized to apyproj.CRSobject.The
CRScan be set when creating a network with theElectricalNetwork.from_elementmethod.The
CRSis now correctly stored in the JSON file and is read when loading the network.
PR350 GH349 Fix invalid transformer parameters with no leakage inductance when created from open and short circuit tests.
PR348 The load classes have two new properties:
res_inner_currentsandres_inner_powers. These are the currents and powers that flow in the inner components of the load as opposed tores_currentsandres_powersthat flow into the load.PR343 GH336 Warn when a line/switch connects buses with different nominal voltages.
PR341 Compute the transformer’s open-circuit (no-load) and short-circuit tests results if they are not provided.
TransformerParameters’si0,p0,vsc, andpscare now always available and no longer returnNonewhen the transformer is created fromz2andym.PR340 Improve the support for the conversion from the PowerFactory DGS format.
Add an option to
ElectricalNetwork.from_dgsto use the element names (loc_namein DGS) as IDs. The names must be unique for each element type.Read the transformer’s maximum loading from the DGS file.
Read the bus’s nominal voltage from the DGS file.
Fix conversion of the transformer’s no-load test results.
PR339 Constant current loads are no longer allowed on a bus with a short-circuit. Previously, the load flow would fail with a singular matrix error.
PR335 Add
GroundConnectionclass with the following features:Ground connections for all terminal elements (buses, loads, sources) and all branch elements, (transformers, lines, switches). Previously only buses could be connected to ground.
Non-ideal (impedant) ground connections with the
impedanceparameter.Access to the current in the ground connection with the
res_currentproperty.
The method
Ground.connectis deprecated in favor of the new class. Replaceground.connect(bus)byGroundConnection(ground=ground, element=bus). The attributeGround.connected_busesis also deprecated in favor ofGroundConnection.connected_elements.PR331 Add
voltage_typeto theplot_voltage_phasorsfunction to be able to plot the voltages in phase-to-phase or phase-to-neutral. Theplot_symmetrical_voltagesfunction now plots each sequence in a separate axes for better readability.PR330 Add phase-to-phase (
res_voltages_pp) and phase-to-neutral (res_voltages_pn) voltage results for terminal elements. Voltage unbalance results are now available for all terminal elements with theres_voltage_unbalancemethod.PR328 Support floating neutrals for transformers. The
Transformerclass constructor now accepts optionalconnect_neutral_hvandconnect_neutral_lvparameters to specify if the neutral is to be connected to the bus’s neutral or to be left floating. By default the neutral is connected when the bus has a neutral and left floating otherwise.PR328 The
plot_voltage_phasorsfunction and theplot_symmetrical_voltagesfunctions now also support transformers, lines and switches.PR325 Rename
Bus.potentialstoBus.initial_potentials. The old attribute and constructor parameter are deprecated and will be removed in a future release.PR319 PR320 PR321 GH191 Deprecate the notion of “primary” and “secondary” sides of transformers in favor of “high-voltage” and “low-voltage” sides following the IEC 60076-1 standard. The following parameters of
rlf.Transformerare deprecated and renamed:bus1,bus2->bus_hv,bus_lvphases1,phases2->phases_hv,phases_lv
The attributes
bus1,bus2,phases1,phases2,winding1,winding2,phase_displacementare still available. They are aliases to newly added attributesbus_hv,bus_lv,phases_hv,phases_lv,whv,wlv, andclockrespectively. The old attributes will NOT be removed.The corresponding columns in
ElectricalNetwork.transformers_frameandElectricalNetwork.res_transformershave been renamed as well. The old columns have been removed.PR318 Implement all common and additional three-phase transformer vector groups. Notable addition is transformers with clock number 1, common in North America.
Version 0.12.0-alpha¶
Some improvements of the underlying engine:
Simplify the center-tapped transformer model in order to improve the convergence speed (especially in case of a short-circuit).
Add the backward-forward algorithm for the single-phase transformers.
Improve the error message if a singular matrix is detected.
Build the engine using the
manylinux_2_34image for Linux distributions (previously it wasmanylinux_2_28).
PR311 Add French aliases to line enumeration types.
PR311 Fix
TypeErrors in theLineParameters.from_coiffier_model. The error message of invalid models now indicates whether the line type or the conductor material is invalid.PR310 GH308 Support star and zig-zag windings with non-brought out neutral. In earlier versions, vector groups like “Yd11” were considered identical to “YNd11”.
PR307 GH296 Make
line.res_violatedandbus.res_violatedreturn a boolean array indicating if the corresponding phase is violated. This is consistent with the dataframe resultsen.res_linesanden.res_buses_voltages. For old behavior, useline_or_bus.res_violated.any().PR305 Add missing
tapcolumn toen.transformers_frame.PR305 Add
element_typecolumn toen.potential_refs_frameto indicate if the potential reference is connected to a bus or a ground.PR305 Add missing information to
results_to_dictwithfull=True. This addsloadingto lines and transformers,voltage_levelsto buses, andvoltagesto loads and sources.PR305 Improve the performance of
res_violatedof buses, lines and transformers.PR304 Add top-level modules
rlf.constantsandrlf.types. The old modules in theutilspackage are deprecated and will be removed in a future release. Theutilspackage is for internal use only and should not be considered stable.PR304 Add top-level module
rlf.symfor symmetrical components utilities. Thesym_to_phasor,phasor_to_symandseries_phasor_to_symfunctions are moved from therlf.convertersmodule to this module. The old functions are deprecated and will be removed in a future release.PR303 Fix missing
voltage_levelinen.res_buses_voltageswhen the buses define nominal voltage but not voltage limits.PR303 Add
rlf.SQRT3constant for the square root of 3. It can be useful for the conversion between phase-to-phase and phase-to-neutral voltages.PR303 Improve the performance of some dataframe properties.
PR301 GH299 Improve the error message when the Jacobian matrix contains infinite or NaN values.
Version 0.11.0¶
This release adds official support for Python 3.13 and adds a new experimental backward-forward solver.
Breaking changes¶
The
min_voltageandmax_voltageofBushave been replaced bynominal_voltage(phase-to-phase, in V), amin_voltage_level(unitless) and amax_voltage_level(unitless).The
typeparameter ofTransformerParametersconstructors becomesvgfor vector group. Replacetype="single"byvg="Ii0"andtype="center"byvg="Iii0".The
typeattribute ofTransformerParametersnow returnsthree-phase,single-phaseorcenter-tapped. UseTransformerParameters.vgto get the vector group.The names of the transformers in the catalogue have been modified to add voltage levels and vector groups. Use
rlf.TransformerParameters.get_catalogue()to see the updated catalogue.The
max_current,section,insulator_typeandconductor_typeparameters of theLineParametersclass are renamed toampacities,sections,insulatorsandmaterialsrespectively. The new parameters accept arrays of values, one per conductor.The enumeration
InsulatorType.UNKNOWNis removed. Please useNoneif the insulator is unknown.The definition of constant-current loads is modified to be the magnitudes of the currents and their phase shift from the voltages instead of the absolute phase shift. Currents should no longer be rotated by 120° to be in sync with the voltages.
Deprecations¶
The enumerated classes
InsulatorTypeandConductorTypeare renamed toInsulatorandMaterialrespectively. Their old names are deprecated and will be removed in a future release.The deprecated method
LineParameters.from_name_mvis removed.
Detailed changes¶
PR293 Fixed
loadingcalculation for lines and transformersPR291 Fixed several bugs in JSON serialization and deserialization.
PR289 GH264 Improve the
TransformerParametersclass and the transformers catalogueAdd 15kV transformers to the catalogue (SE and FT)
Add single-phase transformers to the catalogue (Schneider Imprego)
Add step-up transformers to the catalogue (Cahors “Série Jaune”)
Use the correct LV side no-load voltage as defined in the datasheets (some 400V became 410V)
Revert PR282 to keep the IEC 600076 names
uhvandulvfor the transformer voltages.Replace the
typeparameter ofTransformerParametersconstructors byvgfor vector group.TransformerParameters.typenow returnsthree-phase,single-phaseorcenter-tapped. UseTransformerParameters.vgto get vector group.Modify the names of the transformers in the catalogue to add voltage levels and vector groups
PR285 GH279 Add maximum loading for lines and transformers.
The constructors of
TransformerandLinenow accept a unitlessmax_loadingparameter equal to 1 (=100%) by default.The parameter
max_currentsofLineParametersis now calledampacities.The
Lineclass gained a new propertymax_currentsthat returns the maximal admissible currents (in Amps) for each conductor:line.max_current = line.parameters.ampacity * line.max_loading.The
res_violatedproperty ofTransformerandLinenow take into account thismax_loading.The
LineandTransformerclasses have a newres_loadingproperty to compute the loading of the element:line.res_loading = line.res_currents / line.parameters.ampacitiestransformer.res_loading = sum(transformer.res_powers) / transformer.parameters.sn
PR286 The deprecated method
LineParameters.from_name_mvis removed.PR283 Several changes related to the
LineParameters:The
max_current,section,insulator_typeandconductor_typeparameters are renamed tomax_currents,sections,insulatorsandmaterialsrespectively. The new parameters accept arrays of values, one per conductor.The class method
from_geometrynow accepts several additional arguments related to the neutral (material_neutral,insulator_neutral,max_current_neutral)The enumerated classes
InsulatorTypeandConductorTypeare renamed toInsulatorandMaterial. Their old names are deprecated and will be removed in a future release.The insulator
UNKNOWNis removed. Please useNoneif the insulator is unknown.The insulator
NONEis added. It must be used to describe conductors without insulator.The catalogue has now several additional columns related to the neutral parameters (resistance, reactance, susceptance, material, insulator, maximal current). The
get_catalogueand thefrom_cataloguemethods have been changed to accept filter on the columns (material_neutral,insulator_neutral,section_neutral)
PR281 Add official support for Python 3.13.
GH278 PR280 Modify the
Busvoltage limits:The
min_voltageandmax_voltageparameters and attributes ofBushave been replaced bynominal_voltage(phase-to-phase, in V), amin_voltage_level(unitless) and amax_voltage_level(unitless).Busgained a new propertyres_voltage_levelsthat returns the voltage levels of the bus as a percentage of the nominal voltage;The JSON file format also changed to take into account these changes. If a
min_voltageormax_voltageexisted in a file of a previous version, they are lost when upgrading the file.
PR277 Fix the definition of constant current loads to be the magnitudes of the currents and their phase shift from the voltages instead of the absolute phase shift. Currents should no longer be rotated by 120° to be in sync with the voltages.
PR276 Add a backward-forward solver (experimental).
PR273 Dynamically calculate the stacklevel of the first frame outside of
roseau.load_flowfor warningsPR272 GH271: Fix segfault when phases of a potential reference are not the same as the bus phases.
PR269 Optimize the SVG files of the documentation.
PR268 Set up ReadTheDoc to automatically compile the documentation.
PR267 Add a section in the documentation on Google Colab secrets.
Version 0.10.0¶
A wheel for Python 3.13 is available.
The wheels for Windows are now available. The problem was the same as the one of the issue 28551 of the Matplotlib repository.
PR237 Improvements of the Sphinx configuration.
PR262 Raise a proper error when a transformer is defined with null impedance.
PR259 The cache of the license object was not reset after the activation of a new license key.
PR258 PR261 PR263 Add basic plotting functionality in the new
roseau.load_flow.plottingmodule. Theplot_interactive_mapfunction plots an electrical network on an interactive map using the folium library and theplot_voltage_phasorsfunction plots the voltage phasors of a bus, load or source in the complex plane. The revamped plotting section of the documentation demonstrates the plotting functionalities available in Roseau Load Flow with examples.PR258 The documentation gained a new “advanced” section with a page on floating neutrals and a page on potential references.
PR257 GH252 Updates to the
LineParametersclass:The method
from_name_lv, deprecated since version 0.6, has been removed. It can be easily replaced by thefrom_geometrymethod.The method
from_name_mvis deprecated. A new methodfrom_coiffier_modelis added with the same functionality and more flexibility. The new method computes the ampacity of the line based on Coiffier’s model and works with different numbers of phases.
-
Accept scalar values for the
powers,currents,impedancesparameters of the load classes.Add
rlf.PositiveSequence,rlf.NegativeSequenceandrlf.ZeroSequencevectors for easier creation of balanced quantities.
PR255 Update the figures of loads and of voltage sources in the documentation to be compliant with the work of PR249.
PR254 GH251 Allow passing multiple phases to potential references. The
phaseattribute of thePotentialRefis replaced byphases.PR249 GH248 Accept scalar values for the
voltagesparameter of theVoltageSourceclass.PR247 Add
connect_neutralparameter to the loads and sources constructor to specify if the neutral is to be connected to the bus’s neutral or to be left floating. This allows loads connected to the same bus to have different neutral connections. The default behavior remains the same as before where the neutral is connected when the bus has a neutral and floating otherwise.PR246 Improvements to the
rlf.convertersmodule:Fix
series_phasor_to_symfunction with series that have different phases per element.Make
calculate_voltagestake array-like potentials.Improve typing of several functions.
PR245 GH244 Fix the
LineParameters.from_geometrymethod to not crash when passedunknowninsulator type orNone.Add
res_voltagesto theVoltageSourceclass for symmetry with the other elements.res_voltagesis always equal to the suppliedvoltagesfor a voltage source.PR243 Fix cross-sectional area of DGS line types created from line elements and special case invalid PwF line geographical coordinates table.
PR240 Add tests for switches imported from DGS and improve warning and error messages.
PR235 BREAKING CHANGE: The constructor of the class
ElectricalNetworkhas changed:it accepts keyword arguments only.
it accepts the arguments
lines,transformersandswitchesin replacement of the argumentbranches.As a consequence,
the results method
res_brancheshas been removed. Please useres_lines,res_transformersandres_switchesmethods instead.the field
branchesdoes not exist anymore. Please use the fieldslines,transformersandswitches.
PR235 Move the
Switchclass into its own fileroseau/load_flow/models/switches.py.PR235 PR239 The JSON file format number is upgraded to the version 2. All the files in version 0 or 1 can still be read. Please upgrade them manually using the following code:
path = "my_json_file.json" ElectricalNetwork.from_json(path).to_json(path)
PR235 The method
results_to_dictnow accepts the keyword-only argumentfullwhich allows the export of all the results of an element.PR235 Solve a bug concerning the accessors to the flexible powers result of flexible power loads. An unwanted error was raised.
PR235 Replace the occurrences of the
str.findmethod by thestr.indexfunction.PR235 The method
to_graphof the classElectricalNetworknow retrieves a graph with additional data store in the edges depending on the edge type: line, transformer or switch.PR242 Add optional data to the
TransformerParametersclass: manufacturer, efficiency and range.PR242 Fixed a bug in the unit of
q_minandq_maxin the constructor ofFlexibleParameter.PR242 Add equality operator for the classes
FlexibleParameter,ControlandProjection.
Version 0.9.1¶
Note
The wheels for Windows are temporarily unavailable anymore. If you need them, please post an issue on GitHub.
PR231 Add
LineParameters.from_power_factoryandTransformerParameters.from_power_factorymethods to easily import PowerFactory lines and transformer models into Roseau Load Flow.PR230 Improve the algorithm for assigning potential references for DGS networks.
PR229 Several fixes and improvements to the PowerFactory import:
Update the “Export Definition Folder” bundled with Roseau Load Flow as a pfd file;
Support lines with missing type ID. This is the case when the
TypLneobjects are inherited from an external library in PowerFactory and not included in the project being exported; ALineParametersobject is automatically created for these lines;Support “General Load (
ElmLod)” elements;Preserve Geometry information on buses and branches;
Improve handling of phases of several elements. Previously, phases were hard-coded.
Fix the unit of the power of static generators;
Fix the re-sizing of the matrices of line types without neutral elements;
Fix the total power of “MV Loads (
ElmLodmv)” to take into account the generation power;Fix all loads to no longer ignore the scale factor of the power;
Fix the sign of the reactive power of MV and LV loads
Fix the ground connection to the source bus
And many more…
Version 0.9.0¶
PR227 Sources and loads are now allowed to have floating neutrals. This means that a load/source with
phases="abcn"can now be connected to a bus withphases="abc".PR225 The
calculate_voltagesfunction now accepts and return pint quantities.MacOS wheels for roseau-load-flow-engine are now published on PyPI. This means that
pip install roseau-load-flowshould now work on macOS.Added support for running in Google Colab documents.
Fixed a bug in license checks caching on Windows.
Added support for Numpy 2.0.
GH222 PR223
from_catalogue()methods of the electrical network and transformer and line parameters now perform “full match” comparison on textual inputs. If you need the old behavior, use regular expression wild cards.*in the input string.GH220 PR221 Add
LineParameters.from_open_dssandTransformerParameters.from_open_dssmethods to easily import OpenDSS lines and transformer models into Roseau Load Flow. More information is available in the documentation of these methods.GH210 PR219 Add a parameter to
LineParameters.from_catalogueto choose the number of phases of the created line parameters object.PR218 Add
Transformer.res_power_lossesto get the total power losses in a transformer.PR217 Add an ID override to
TransformerParameters.from_cataloguesimilar toLineParameters.from_catalogue.GH216 PR217 BREAKING CHANGE: Rename the
idparameter ofTransformerParameterscatalogue methods tonameto be consistent withLineParameters. If you call these methods by keyword arguments, make sure to update your usage ofTransformerParameters.from_catalogue(id="xxx")toTransformerParameters.from_catalogue(name="xxx").PR212 BREAKING CHANGE: Modify the constructor of
TransformerParametersto take thez2andymparameters directly instead of the open and short circuit tests parameters. You can still create an object from these tests using thefrom_open_and_short_circuit_testsconstructor. This change comes with other changes toTransformerParameters, notably:The
z2,ym,k, andorientationare now always available as attributes on the instanceThe
to_zykmethod is deprecated in favour of the direct attribute access on the instance. This method will be removed in a future versionThe parameters
i0,p0,psc, andvscare now optional. They return None for instances created usingz2andymdirectlyThe JSON representation of
TransformerParametershas changed, but it is still compatible with the old representation.
Version 0.8.1¶
GH214 Solve a bug in the engine when using delta connected flexible loads.
PR213 Better detection of poorly connected elements as described in GH209. It raises a proper error message.
PR211 Several improvements of the documentation:
Add Open Graph metadata to the documentation page.
Error on the susceptance unit in the tables of the
LineParameters’ catalogue.Replot the networks of the catalogue (add a
H1title, use the Raleway font, only plot the lines to add their parameters id in the tooltip)
Version 0.8.0¶
PR207 Fix a bug in the zig-zag three-phase transformer model that led to incorrect active power flow in the transformer. The bug affected the 50 kVA transformers that have the type
Yzn11in the catalogue.PR206 GH187 Un-deprecate
results_to_dict/jsonmethods and remove deprecatedresults_from_dict/jsonmethods.PR205 GH200 Fix error when propagating the potentials from a voltage source with fewer phases than the bus.
PR204 GH193 Remove restrictions on geometry types. Allow specifying the CRS of the geometries.
PR203 GH186 Detect invalid element overrides when connecting a new element with the same ID and type of an existing element.
PR202 GH188 Explicitly prevent instantiation of abstract classes.
PR201 GH185 Add
typeattribute to the load classes and rename branchesbranch_typeattribute totypefor consistency. Please replacebranch.branch_typebybranch.typein your code. In addition, loads data frames gained two new columns:typeindicating the load type: constant-(power,current,impedance);and
flexibleindicating if the load is flexible.
PR197 Fix a bug in three-phase transformer models that led to excessive reactive power flow in the transformer.
PR199 Add Schneider Electric EcoDesign transformers to the catalogue. These are tagged with the AA0Ak efficiency class. Other internal data have been added to the catalogue for testing purposes.
PR198 Simplify the storage of the transformer catalogues. This is an internal change that should not have effects on user code.
PR196 GH194 Improve the error message when accessing
res_flexible_powerson a non-flexible load and relax the flexible parameters plotting methods to accept an array-like of voltages.PR195 Use
latexindent.plto automatically indent LaTeX files in the documentation.PR192 Speed up results access by up to 3x using several optimization techniques. This is especially noticeable in timeseries simulations and when accessing results of large networks.
PR184 Improve the documentation to have a better SEO (sitemap, metadata and canonical URLs). The navigation menu has also been improved.
PR183 GH181 Update the networks catalogue to better represent the real networks. LV loads are made single-phase, MV sources are connected in delta, and MV buses lost their neutral. Voltage, current, and power limits are added to the buses, lines, and transformers. The line parameters IDs are also updated to match the new line parameters catalogue.
PR182 Improve the error message when trying to access results on the network before running the load flow.
PR189 Allow flexible loads to have a null active theoretical power.
Version 0.7.0¶
Important
Starting with version 0.7.0, Roseau Load Flow is no longer supplied as a SaaS. The software is now available as a standalone Python library.
The documentation is moved from GitHub Pages to https://roseau-load-flow.roseautechnologies.com/.
Fix a bug in the engine: it was impossible to change the parameters of center-tapped and single phase transformers.
PR179 Fix a bug in the propagation of potentials when a center-tapped transformer is used without neutral at the primary side.
PR178 GH176 Merge the
results_to_json,results_from_json,results_to_dictandresults_from_dictmethods of theElectricalNetworkandElements classes into the methodsto_json,from_json,to_dictandfrom_dictrespectively. The oldresults_methods are deprecated and will be removed in a future release. The new methods will include the results by default, but you can passinclude_results=Falseto exclude them.PR175 GH174 Fix JSON serialization of network with line parameters created from the catalogue.
PR173 Remove the conda installation option.
PR167 GH161 Add a catalogue of lines using the IEC standards. You can use the method
LineParameters.get_catalogue()to get a data frame of the available lines and the methodLineParameters.from_catalogue()to create a line from the catalogue. Several line types, conductor material, and insulation types have been updated. Physical constants have been updated to match the IEC standards where applicable.PR167 The class
LineParametersnow takes optional argumentsline_type,conductor_type,insulator_typeandsection. These parameters are accessible as properties. They are filled automatically when creating a line from the catalogue or from a geometry.PR167 Replace all
print_catalogue()methods byget_catalogue()methods that return a data frame instead of printing the catalogue to the console.PR167 Enumeration classes no longer have a
from_stringmethod, you can call the enumeration class directly with the string value to get the corresponding enumeration member. Case-insensitive behavior is preserved.PR167 GH122 Add checks on line height and diameter in the
LineParameters.from_geometry()alternative constructor. This method will try to guess a default conductor and insulation type if none is provided.PR163 BREAKING CHANGE: roseau-load-flow is no longer a SaaS project. Starting with version 0.7.0, the software is distributed as a standalone Python package. You need a license to use it for commercial purposes. See the documentation for more details. This comes with a huge performance improvement but requires a breaking change to the API:
The
ElectricalNetwork.solve_load_flow()method no longer takes anauthargument.To activate the license, you need to call
roseau.load_flow.activate_license("MY LICENSE KEY")or set the environment variableROSEAU_LOAD_FLOW_LICENSE_KEY(preferred) before callingElectricalNetwork.solve_load_flow(). More information in the documentation.Several methods on the
FlexibleParameterclass that previously requiredauthare changed. Make sure to follow the documentation to update your code.
PR163 GH158 Fix
ElectricalNetwork.res_transformersreturning an empty dataframe when max_power is not set.PR163 Several unused exception codes were removed. An
EMPTY_NETWORKcode was added to indicate that a network is being created with no elements.PR163 Remove the
ElectricalNetwork.res_infoattribute.ElectricalNetwork.solve_load_flow()now returns the tuple (number of iterations, residual).PR163 Remove the
Bus.clear_short_circuits()andElectricalNetwork.clear_short_circuits()methods. It is currently not possible to clear short-circuits from the network.PR163 Improve performance of network creation and results access.
PR163 Attributes
phasesandbusare now read-only on all elements.PR151 Require Python 3.10 or newer.
Version 0.6.0¶
PR149 GH145 Add custom pint wrapper for better handling of pint arrays.
PR148 GH122 deprecate
LineParameters.from_name_lv()in favor of the more genericLineParameters.from_geometry(). The method will be removed in a future release.PR142 GH136 Add
Bus.res_voltage_unbalance()method to get the Voltage Unbalance Factor (VUF) as defined by the IEC standard IEC 61000-3-14.PR141 GH137 Add
ElectricalNetwork.to_graph()to get anetworkx.Graphobject representing the electrical network for graph theory studies. Install with the"graph"extra to get networkx.ElectricalNetworkalso gained a newbuses_clustersproperty that returns a list of sets of IDs of buses that are connected by a line or a switch. This can be useful to isolate parts of the network for localized analysis. For example, to study a LV subnetwork of a MV feeder. Alternatively, to get the cluster certain bus belongs to, you can useBus.get_connected_buses().PR141 Add official support for Python 3.12. This is the last release to support Python 3.9.
PR138 Add network constraints for analysis of the results.
Buses can define minimum and maximum voltages. Use
bus.res_violatedto see if the bus has over- or under-voltage.Lines can define a maximum current. Use
line.res_violatedto see if the loading of any of the line’s cables is too high.Transformers can define a maximum power. Use
transformer.res_violatedto see if the transformer loading is too high.The new fields also appear in the data frames of the network.
PR133 GH126 Add Qmin and Qmax limits of flexible parameters.
PR132 GH101 Document extra utilities including converters and constants.
PR131 GH127 Improve the documentation of the flexible loads.
Add the method
compute_powersmethod to theFlexibleParameterclass to compute the resulting flexible powers for a given theoretical power and a list of voltage norms.Add the
plot_control_p,plot_control_qandplot_pqmethods to theFlexibleParameterclass to plot the control curves and control trajectories.Add the extra
plotto installmatplotlibalongsideroseau-load-flow.
PR131 Correction of a bug in the error message of the powers setter method.
PR130 Mark some internal attributes as private, they were previously marked as public.
PR128 Add the properties
z_line,y_shuntandwith_shuntto theLineclass.PR125 Speed-up build of conda workflow using mamba.
Version 0.5.0¶
PR121 GH68 Improvements of the
LineParametersconstructor:Delete the
LineModelclassSimplify the
from_dictmethodRename and refactor the method
from_lv_exactintofrom_geometry.Add documentation for the
LineParametersalternative constructors.Rename
InsulationTypeintoInsulatorType.Allow the letter “U” for “Underground” line type (only “S” for “Souterrain” in French was accepted). The same with the letter “O” for “Overhead” line type (only “A” for “Aérien” in French was accepted).
Remove the field
"model"from the JSON serialization ofLineParameters.
PR120 Fix phases of flexible power results.
PR119 Add explicit error message for singular jacobian.
-
Add a catalogue of three-phase MV/LV distribution transformers.
Remove the class method
TransformerParameters.from_name.
PR117 Add prettier to pre-commit
-
Add a catalogue of networks.
Add a plotting page to the documentation.
-
Reformat the tutorials in the documentation.
Split the “Advanced” tutorial in several smaller files.
Remove the Docker installation option.
PR114 Use Pint >=0.21 to have the percent unit.
PR113 Raise an error when accessing the results of disconnected elements.
PR112 Make the geometry serialization optional.
PR106 Improvements for non-euclidean projections.
PR104 Remove
roseau.load_flow.utils.BranchType.GH99 Add
Line.res_series_currentsandLine.res_shunt_currentsproperties to get the currents in the series and shunt components of lines. Also addedElectricalNetwork.res_linesthat contains the series losses and currents of all the lines in the network. The propertyElectricalNetwork.res_lines_losseswas removed.GH100 Fix the
Yztransformers.PR97 Add the model section to the documentation.
-
Add single-phase transformer.
Add center-tapped transformer.
Remove the
roseau.load_flow.utils.TransformerTypeenumeration.
PR93 Add short-circuit computation.
-
Add the changelog in the documentation.
Use Node.js 20 in the Dockerfile.
Correction of a dead link in the README.
Version 0.4.0¶
Version 0.3.0¶
Every network elements have an
idwhich must be unique among the same type of elements.The argument
n(number of ports) have been replaced by aphase(s)argument which can be for instancean,abc,abcn,ca, etc.The classes
SimplifiedLineandShuntLinehave been merged into a single classLinewhose behaviour depends on the providedLineParameters.The classes
DeltaDeltaTransformer,DeltaWyeTransformer,DeltaZigzagTransformer,WyeDeltaTransformer,WyeWyeTransformerandWyeZigzagTransformerhave been replaced by an uniqueTransformerclass whose behaviour depends on the providedTransformerParameter.The classes
LineCharacteristicsandTransformerCharacteristicshave been renamed intoLineParametersandTransformerParameters.The classes
AdmittanceLoadandDeltaAdmittanceLoadhave been removed. Please useImpedanceLoadinstead, with the desiredphasesargument.The classes
DeltaImpedanceLoadandDeltaPowerLoadhave been removed. Please use the classesImpedanceLoadandPowerLoadinstead withphases="abc".The class
FlexibleLoadhave been removed. Please use the newflexible_paramsargument of thePowerLoadclass constructor.The
VoltageSourceis not anymore a subclass of the classBus. It can now be connected to a bus just like a load.All elements are aware of the network they belong to. It helps the user to avoid mistakes (connecting elements from different networks). It also allows showing user warnings when accessing to outdated results.
All properties retrieving results are now prefixed by
res_.Additional results per elements:
res_potentials,res_voltages,res_series_losses,res_lie_losses, etc.Pandas Data frame results: now, every result can be retrieved in Pandas Data frame from the
ElectricalNetworkinstance. These methods are also prefixed byres_.Every physical input can be given as quantities (magnitude and unit) using the
Q_class.Every result (except Pandas data frame) are quantities (magnitude and unit).
Elements can all be serialized as JSON.
Results of an
ElectricalNetworkcan be serialized as JSON and read from a JSON file.The documentation has been improved.