Welcome to GElectrical’s documentation!

Introduction

General

GElectrical is a free and opensource electrical system analysis software for LV/MV electrical distribution networks. Following features are currently implemented.

  • Schematic capture.

  • Pandapower network generation from schematic.

  • Power flow time series analysis (Symmetric and Assymetric).

  • Power flow with diversity factors (Symmetric and Assymetric).

  • Voltage drop analysis.

  • Short circuit analysis (Symmetric and SLG).

  • Coordination analysis for power supply protection devices with support for CB and fuse protection curves; damage curves for transformers, cables and motors.

  • Support for daily load curves for load elements.

  • Support for arriving network parameters for custom geometry OH lines.

  • Support for modeling networks with mixed TN-S/ TN-C/ TT/ IT earthing systems.

  • Electrical rules check for checking conformity with IEC/ local electrical guidelines.

  • Print and export of drawings to pdf.

  • Generation of analysis reports.

Read before using …

Please note that the program is in active development and bugs are expected. Cross checking of generated calculations is reccomended. See Roadmap for current limitations.

Screenshots

Screencasts

See Screencasts for application screencasts

Properties display Results display Electrical rules check Protection curve display Load profile display Database display

Sample Files

Installation

Application can be installed for use on your OS as described below.

Font for schematic drawings

It is recommended to install osifont for schematic capture. This can be downloaded from https://github.com/hikikomori82/osifont/blob/master/osifont.ttf.

Binary

Windows

Use .EXE installation package available under the latest Release.

Linux

Application is published on Flathub repository at GElectrical.

It should be possible to install the application using the default package manager on most linux systems if flathub is setup. Please see https://flatpak.org/setup/ to setup flahub for your linux distribution.

Source

Linux

  • Install GTK3 from your distribution package manager.

  • Run pip install appdirs pycairo numpy numba scipy pandas mako networkx matplotlib pandapower jinja2 weasyprint openpyxl shapely.

  • Clone this repository git clone https://github.com/manuvarkey/GElectrical.git

  • Run gelectrical_launcher.py from cloned directory.

Windows

  • Install git, msys2, visualstudio2022-workload-vctools and gvs_build by folowing this link gvsbuild.

  • Setup GTK3 and PyGObject development envirnonment using gvs_build by running gvsbuild build --enable-gi --py-wheel gtk3 pygobject adwaita-icon-theme.

  • Add required environment variables as suggested in the above link. Please see Create and Modify Environment Variables on Windows for more information about setting up environment varables.

  • Run pip install appdirs pycairo numpy numba scipy pandas mako networkx matplotlib pandapower jinja2 weasyprint openpyxl shapely in powershell.

  • Clone this repository using git clone https://github.com/manuvarkey/GElectrical.git.

  • Run python gelectrical_launcher.py from the cloned directory.

Dependencies

  • Python 3 (v3.10+)

    • undo - Included along with distribution.

    • appdirs (v1.4.4) - Not included

    • openpyxl - Not included

    • mako - Not included

    • numba - Not included

    • pandapower (v2.10.1) - Not included

    • numpy - Not included

    • pandas - Not included

    • networkx - Not included

    • shapely - Not included

    • matplotlib (v3.5.1) - Not included

    • jinja2 - Not included

    • weasyprint - Not included

    • pycairo - Not included

    • PyGObject - Not included

  • GTK3 (v3.36+)

Getting Started

User Interface Overview

Main window

The application interface is divided into five components which are indicated by the numbered markers in the above figure. They are described below.

  1. Application toolbar:
    Toolbar containing buttons for accessing commonly used application level functionality.

  2. Project toolbar:
    Tool bar containing buttons for accessing commonly used project related functionality.

  3. Components side-bar:
    Sidebar allows insertion of elements into drawing view.

  4. Drawing View:
    Drawing view allows defining the electrical single line diagram for the project by addition and modification of schematic elements and defining connectivity between elements.

  5. Properties side-bar:
    Sidebar allows the following functions.

    1. Modification of properties of the selected elements.

    2. Viewing simulation results for the selected elements.

    3. Viewing messages output by analysis functions.

Application Toolbar

Application Toolbar

The items in the application toolbar provides access to application management related functionalities of GElectrical. User interface elements indicated by the numbered markers in the above figure are described below.

  1. Shows a popup widget to open an existing project. Recently opened project files are shown in the popup widget. Double clicking on the project name opens the selected project. If the required project file is not availabe in the selection list, a file browser can be openened by clicking on the Other Projects... button.

  2. Create a new project.

  3. Undo (Ctrl+z)/ Redo (Ctrl+Shift+z) actions performed by the user.

  4. Displays application name and project filename.

  5. Save project file (Ctrl+s).

  6. Show/ hide left/ right side-bars.

  7. Show Application Menu.

Application Menu

The application menu provides access to less frequently used functionality of GElectrical. The items in the menu are described below.

Slno.

Menu Item

Description

1

Save As

Save the current project to a new project file.

2

Print

Allows prinitng of schematic drawings. The pages to be printed and printing options may be selected by the user.

3

Project Preferences

Show project preferences dialog. These settings will be applicable only for the current project.

4

Program Settings

Show program settings dialog. These settings are application wide and will be applicable to all projects.

5

Help

Opens a browser window showing the application documentation.

6

Keyboard Shortcuts

Shows a dialog listing out the keyboard shortcuts supported by the application.

7

About GElectrical

Show information relating to GElectrical.

8

Quit

Quit application

Project toolbar

Project Toolbar

The items in the project toolbar provides access to most of the project related functionality of GElectrical. Their contents are listed and described below. Contextual help is also available for these functions in the form of tooltips which can be viewed by placing the mouse cursor over the toolbar buttons.

  1. Add a new drawing sheet.

  2. Draw a wire interconnecting element ports.

    1. Left Mouse Button adds a new point.

    2. Clicking on an element port or double clicking Left Mouse Button finishes drawing of wire.

    3. Right Mouse Button cancels the drawing of wire.

  3. Group selected elements into an assembly (Ctrl+g).
    Assemblies may be used for panels, enclosures or any other logical grouping of elements. This option may be used for adding or modifying assembly of elements as described below.

    1. Add new assembly:
      Select the elements to be grouped and click on the toolbutton.

    2. Edit existing assembly:
      Select the new elements to be grouped, existing assembly elements, existing assembly and click on the toolbutton.

  4. Assign reference numbers to elements.
    Reference numbers helps to identify elements. Numbering can be carried out for selected elements only/ new elements only/ for all elements.

  5. Link cross reference element.
    Cross reference elements allows connecting different parts of the scheme within/ across sheets. This option opens a dialog for linking the selected cross reference element with other cross reference element(s) within the project.

  6. Zoom-in/ Zoom-out Drawing View.

  7. Cut/ Copy/ Paste elements in Drawing View.

  8. Add/ edit daily load profiles.
    Daily load profiles can be assigned to load elements or static generation elements. This can be used in time series power simulation to model variation of load/ power generation over the day.

  9. Protection coordination.
    Allows viewing and editing element parameters for protection coordination. Select breakers/ fuses, lines, transformers, motors or node elements and select this option to view protection coordination dialog window.

  10. Run analysis.
    Runs diagnostics on scheme to identify common issues, power flow (with diversity factors/ without diversity factors/ time series), short circuit (symmetric/ line to ground).
    Results of the analysis will be displayed in the results tab of the right pane for each element. Results may also be exported to a PDF report.

  11. Run electrical rules check.
    Checks the scheme for violations of common wiring rules like loading limits, protection coordination between elements, automatic disconnection of supply etc. Powerflow and shortcircuit (symmetric and line to ground) analysis functions should be run before running this module. Results of the rules check will be displayed in the messages tab of the right pane.

  12. Export drawing to PDF.

  13. Clear analysis results and node elements that were inserted during analysis.

  14. Delete selected elements.

  15. Delete currently selected drawing sheet.

Components side-bar

_images/components_side_bar.png

Components side-bar allows insertion of elements into drawing view. On selecting an element in components side-bar, the insertion mode is activated and a floating model is enabled which follows the cursor on the drawing view. This floating model can be added to the drawing view by clicking the Left Mouse Button. Multiple models may be added by pressing down Shift while clicking the Left Mouse Button. To cancel the insertion of the model, use the Right Mouse Button. The components side-bar also incorporates a search bar for filtering the list of available elements.

During insertion of the element, the components side-bar is replaced by the insertion view. This view allows manipulation of the element being inserted. Selecting Rotate (R), rotates the floating model from vertical to horizontal or vice versa. Selecting Cycle Port (C) selects the point of attachment (relative to the cursor) of the floating model.

Insertion may also display fields which can be modified to modify the behaviour of the floating modal for certain elements like Bus Bar or Text Display Element.

Drawing View

_images/drawing_view.png

Drawing view allows defining the electrical single line diagram for the project by addition and modification of schematic elements and defining connectivity between elements. The elements are added into the drawing view using the components side-bar. The properties of the inserted elements can be viewed in the properties side-bar by selecting the element in the drawing view. Selected elements can be deleted by pressing the Delete button or by selecting the function available in the project toolbar.

The elements inserted in the drawing view can be selected using the Left Mouse Button. Pressing down Shift while selecting allows multiple elements to be selected.

Box selection mode can be entered by clicking Left Mouse Button on a blank area of the drawing view. A box selection is shown which follows the mouse cursor. The selection can be finished by clicking Left Mouse Button. The elements in the area bounded by the box selection will become selected.

While some elements are selected, clicking on a blank area of the drawing view or pressing Escape clears all selection.

All the sheets available in the project can be accessed using the tab bar at the bottom of the drawing view. Functions for addition and deletion of sheets can be accessed using the project toolbar. Sheets can be rearranged by clicking and dragging the tabs.

Properties Side-bar

_images/properties_sidebar.png

This sidebar has three tabs which are described below.

  1. Properties: Modification of properties of the selected elements.

  2. Results: Viewing simulation results for the selected elements.

  3. Messages: Viewing messages output by analysis functions.

The Properties tab displays the properties of the currently selected element in the Drawing View. If multiple elements of the same kind are selected, common fields assosiated with these elements will be visible. If no elements are selected, it shows properties of the selected sheet. Each property has a caption followed by a text field for entering/ viewing values assosiated with the property. After editing these fields, the values can be saved by pressing Enter (Ctrl+Enter for multiline fields).

Contextual help is available for the fields in the form of tooltips which can be viewed by placing the mouse cursor over the corresponding field.

The Results tab displays the results of various analysis run by the user. By default, this tab will be blank. It will become populated once various analysis options are run.

The Messages tab displays messages that are output by certain analysis functions like Diagnosis and Electrical Rules Check. If certain elements are referenced by these messages, these elements can be selected by double clicking (Left Mouse Button) those message fields.

Features Overview

This section displays the various features available in GElectrical for the analysis/ documentation of electrical networks.

Add/ edit daily load profiles

Load profile editor

Daily load profiles are used in Time series power analysis to model variation of load/ power generation over the day. Load profiles are supported by all load elements and static generation elements.

Protection coordination

Protection coordination

Protection coordination provides a convinient interface to view and edit parameters for acheiving protection coordination between elements. For using this module, select breakers/ fuses, lines, transformers, motors or node elements which are involved in the co-ordination problem and click on the toolbar button for this option in project toolbar to view the protection coordination dialog window as given above.

The interface is divided into three sections which are indicated by the numbered markers in the above figure. These are described below.

  1. This combobox allows switching between Line Protection and Ground Protection coordination curves for breaker elements.

  2. This view displays the time-current co-ordination curves for the selected elements. The various curves displayed are enumerated below.

    1. Breaker/ fuse time-current operation curves. Below the hatched portion, the device will not operate. Above the hatched portion, the device will operate. Inside the hatched portion, the device may or may not operate.

    2. Cable damage curve. The operating point should be below the damage curve to prevent damage to the cable.

    3. Motor/ transformer starting and damage curves. During motor/ tranformer starting, to prevent nuisance tripping, the protection curve should be above the starting curve. To prevent damage to the device, the operating point should be below the damage curve.

    4. Maximum disconnection time for automatic disconnection of supply.

    5. Maximum and minimum fault current values for the selected node elements.

  3. This pane allows the modification of protection related parameters of the selected elements so as to acheive co-ordination between elements.

Run analysis

_images/run_analysis.png

This module allows various analysis functions to be run for simulating the behaviour of the electrical network at various conditions. Results of the analysis will be displayed in the results tab of the right pane for each element. Results may also be exported to a PDF report. The various options available are listed below.

Slno.

Option

Description

1

Run diagnostics

Runs diagnostics on the electrical scheme to identify common issues that may affect simulations.

2

Enable assymetric power flow calculation

Allows assymetric elements to be used in power flow. Note that all elements may not be supported while using this mode.

3

Run power flow

Runs power flow for the network. The type of power flow to be run will be decided by the option given by the user.

4

Run symmetric short circuit calculation

Run symmetric short circuit calculation as per IEC-60909.

5

Run line to ground short circuit calculation

Run line to ground short circuit calculation as per IEC-60909.

6

Power flow method

This option selects the type of powerflow analysis to be run. These are described below.

7

Export results of simulation

Export the simulation results to the selected folder. The exported files include pdf drawing, pdf report detailing the electrical network & simulation results, pandapower html report, connectivity html graph and pandapower json network definition file.

8

Export folder

Folder to which the results of the simulation are to be exported.

Types of power flow analysis options available are described below.

  1. Power flow:
    This is a regular power flow analysis. The diversity factors (DF) specified for the Bus Bar elements are negleted. The Load Profiles specified for load and static generation elements are also negleted.

  2. Power flow with diversity:
    This is a regular power flow analysis but considering diversity factors specified for the Bus Bar elements. The upstream power flow at each Bus Bar element with diversity factor (DF) is reduced by the selected factor. This is internally achived by adding phantom static generation elements at Bus Bar elements to inject the difference in power flow to be reduced. The Load Profiles specified for load and static generation elements are negleted.

  3. Time series:
    This is a time series power flow analysis with power flow solutions obtained for each hour of the day. Each of the individual power flow analysis is performed similar to the first option but by adjusting the various loads and static generation elements according to the Load Profiles selected for these elements.

Run electrical rules check

This module checks the scheme for violations of common wiring rules like loading limits, protection coordination between elements, automatic disconnection of supply etc. The supported rules are described in detail below.

Powerflow and shortcircuit (symmetric and line to ground) analysis functions should be run before running this module. Results of the rules check will be displayed in the messages tab of the right pane.

Rules for Lines

Slno.

Rule

Description

1

Line loading % < 100%

Checks whether lines are loaded within the permissible limit.

2

Line loss % < X %

Checks whether the maximum line loss (as a percentage of power transmitted) is within the limit specified in Project Settings -> Rules Check.

3

Line protection by upstream breaker

Checks whether all lines are protected satifactorily by upstream breaker/ fuse elements. A line is considered as protected if the damage curve of the line is lying above the breaker operating curve upto the available value of fault current.

4

Automatic disconnection time of line < X s

Checks whether the automatic disconnection of lines are acheived by upstream breakers within the time limit specified in Project Settings -> Rules Check.

5

CPE conductor sized for fault current

Checks whether the CPE (Circuit Protective Earthing) conductors of lines are adequetly sized to carry fault currents available at the line downstream nodes.

Rules for Transformers

Slno.

Rule

Description

1

Transformer loading % < 100%

Checks whether tranformers are loaded within the permissible limit.

2

Transformer protection by upstream breaker

Checks whether transformers are protected satifactorily by upstream breaker/ fuse elements. A transformer is considered as protected if the damage curve of the transformer is lying above the breaker operating curve upto the available value of fault current.

3

Transformer inrush current coordination with upstream breaker

Checks whether the upstream breaker/ fuse element of tranformers do not operate during transformer startup. This is considered satisfied if the starting curve of the transformer is lying below the breaker operating curve.

Rules for Motors

Slno.

Rule

Description

1

Motor protection by upstream breaker

Checks whether motors are protected satifactorily by upstream breaker/ fuse elements. A motor is considered as protected if the damage curve of the motor is lying above the breaker operating curve upto the available value of fault current.

2

Motor inrush current coordination with upstream breaker

Checks whether the upstream breaker/ fuse element of motors do not operate during motor startup. This is considered satisfied if the starting curve of the motor is lying below the breaker operating curve.

Rules for Breakers

Slno.

Rule

Description

1

Breaker short circuit current < Fault level

Checks whether the short circuit current rating specified for breakers are less than the available fault current at the breaker downstream node.

2

Breaker coordination with upstream

Checks whether breakers/ fuses co-ordinate fully with the upstream breakers/ fuses. This is considered satisfied if the breaker operating curve of the downstream device is fully lying below the breaker operating curve of the upstream device.

Rules for Loads

Slno.

Rule

Description

1

Automatic disconnection time of load < X s

Checks whether the automatic disconnection of loads are acheived by upstream breakers within the time limit specified in Project Settings -> Rules Check.

2

Voltage drop < X %

Checks whether the maximum voltage drop at the load is within the limit specified in Project Settings -> Rules Check.

Rules for checking connectivity issues

Slno.

Rule

Description

1

Three phase load connected to three phase line

Checks whether three phase load elements are connected to three phase lines.

How-to Guides

TODO…

Troubleshooting

  1. Unable to save value of fields in Properties tab. A symbol is displayed when field is modified.

When a field is edited, it is not immedietly saved. After editing any field, the value can be saved by pressing Enter (Ctrl+Enter for multiline fields).

  1. While inserting certain elements like Grid, Generator, Load etc, the Cycle Port option do not seem to have any effect.

These elements are single port elements. Hence cycle ports will not change the attachment point. This behaviour is expected.

Frequently Asked Questions

  1. What is GElectrical ?

GElectrical is a free and opensource electrical system analysis software for LV/MV electrical distribution networks.

  1. Does GElectrical do automatic sizing of elements ?

GElectrical do not currently support automatic sizing of elements. However GElectrical has an Electrical Rules Check to identify common design issues.