ACPF Contingency Analysis v25.5.13

A simple plugin to do AC power flow contingency analysis.

Download it here: acpf-contigency-analysis-plugin v25.5.13.zip (32.5 MB)

Screenshot:

Overview

This plugin expects the following SAInt project directory structure:

SAInt_Project/
├── *.enet  # SAInt electric network file for contingency analysis
├── *.esce  # N-0 SAInt Steady or QuasiDynamic ACPF electric scenario for contingency analysis
└── contingency_analysis_specs.xlsx  # Contingency specifications in Excel format

and will generate a file contingency_analysis_results.xlsx in this project directory with the results of the analysis.

Inputs

  • Select N-0 scenario, also defines default directory: Path to the N-0, base case, SAInt Steady or QuasiDynamic ACPF scenario.
  • Timestep for contigency (dd/MM/yyyy HH:mm, Optional if using Steady scenario): Timestep, within the N-0 QuasiDynamic scenario, for which the contingencies will be run. This is optional if a Steady scenario is specified.

Advanced Inputs (Optional)

  • Path to network file, if not in default directory: Path to SAInt electric network, if not in the same directory as N-0 scenario.
  • Path to contingency specification file, if not in default directory: Path to contingency specification file, if not in the same directory as N-0 scenario. This Excel file must contain the sheet Outage Contingencies which specifies which contingencies you want to run and a sheet Report Results which species the results that you want reported for each contingency. Download an example here: contingency_analysis_specs.xlsx (17.2 KB)
    or make your own following these examples:

Outage Contingencies (example):

Contingency Name (no white space!) Element 1
CT_RI LI.MARLBOROUGH_CT_TO_PROVIDENCE_RI
CCGT_Group EGRP.GAS

Report Results (example):

Name SAInt Command
Min Network Voltage Bus eminat(“ENO.%.VPU”)
Min Network Voltage (pu) emin(“ENO.%.VPU”)
Line Loading Above 95% (pu, line base) find(“LI.%.LLS>95.0”)
  • Results precision (decimal place rounding): The number of decimal places to which the results should be rounded.
  • Path to SAInt API DLL, if not regular install: The path to the SAInt-API.dll if not in C:/Program Files/encoord/SAInt-v3/SAInt-API.dll.
  • Logging level: Level of logging output. Options are either debug or info.

Example with ENET 39

The following is an example of running the plugin with the ENET 39 dataset.

What You Will Need

To start, please download:

  • The latest version of SAInt
  • This ACPF contingency analysis plugin. Unzip it and note the location of the download. For this example, the plugin will be placed in the Desktop at %USERPROFILE%\Desktop\acpf-contingency-analysis-plugin-v25.5.13\acpf-contingency-analysis-plugin and should contain at least:
acpf-contingency-analysis-plugin/
├── main.exe
├── form.yaml
(Other files)
  • A contingency specifications file for the ENET39 (contingency_analysis_specs.xlsx). Download it here: contingency_analysis_specs.xlsx (17.2 KB)

  • The ENET 39 dataset. Unzip it and note the location of the download. For this example, the dataset will be placed in my Desktop at %USERPROFILE%\Desktop\ENET39 v24.9.20\ENET39. Place the contingency_analysis_specs.xlsx in this directory.

To recap that directory should contain at least:

ENET39/
├── ENET39.enet
├── ACPF_PEAK_DEMAND_WEEK.esce
├── contingency_analysis_specs.xlsx
(Other files)

Running the Plugin

  1. Open SAInt
  2. Select Plugin In SAInt: Tools → Plugin → Select (select the folder containing the plugin)
  3. Execute Plugin: Tools → Plugin → Execute
  4. In the form enter:
    • Select N-0 scenario, also defines default directory: Using the file explorer, select the ACPF_PEAK_DEMAND_WEEK.esce scenario
    • Timestep for contingency (dd/MM/yyyy HH:mm): Using the datetime picker or text input, select 19/07/2023 16:00.
  5. Click submit

Understanding the Output

  1. Open the results file in %USERPROFILE%\Desktop\ENET39 v24.9.20\ENET39\contingency_analysis_results.xlsx.
    • The Summary sheet presents a general summary for each contingency execution, including results that return only a single object/value; the maximum voltage bus for the CT_RI contingency simulation is ENO.NEWHAVEN2_CT.
    • If a contingency simulation fails, the solution status will be ‘Failed’, and all other results remain blank.
    • The Conditional Results sheet presents all of the objects/values that meet a conditional criteria for each contingency simulation. For instance, the sixth contingency of the CCGT_Group (CCGT_Group_6) returns two lines that have an apparent power loading (LLS) greater than 95%.
  2. If a second contingency analysis is run without copying/removing the first set of results, two new tabs will be created within the first results file (Summary_2, Conditional Results_2).