Skip to content

User Interface Guide

Comprehensive guide to navigating and using the KPG Run graphical interface.

Interface Layout

User Interface Guide - Interface Layout

Main Components

1. Header Bar

  • Application title
  • Light, dark and system (auto) themes selector
  • Settings
  • Current status indicator

2. Configuration Panel

  • Data Source
  • Problem Setup
  • Solver

3. Main Workspace

  • Editor
  • Network Data
  • Time Series
  • Console
  • Results

Configuration Panel

Use the Configuration panel to select the optimization model and define its basic settings.

Data Source

  • Select Test System Folder set to be used for the run.
    • Change Folder button opens a file dialog to navigate to the desired folder.
    • Set directory path containing KPG 193 test system files.
  • Data validation checker verify that all required and optional files are present in the test system folder. (Expandable)

Problem Setup

Problem Type:

  • ED: (simplest)
  • UC: (temporal)
  • DC-OPF: (network)
  • AC-OPF: (most complex)
  • Custom Solver

Problem Settings:

  • Day (1-365): Selects the day of year for which to run the optimization.
  • Batch Mode (Multiple Days): Enables solving across multiple consecutive days when supported. (Planned)
  • Period (days): Sets the number of consecutive days to include in the optimization horizon. (UC only)

Solver

Solver Engine

  • Solver-specific options additional fields appear depending on the chosen solver (for example, maximum iterations and print level for AC OPF).
  • Solve button starts the optimization with the current configuration.

Solver Options

  • Time Limit (sec): A maximum time limit for the solver to run.
  • Threads: Number of CPU threads to allocate to the solver. (UC only)
  • Output Level: Verbosity of solver output in the console.
  • Advanced Options:
    • Max Iterations: Maximum number of iterations before termination.
    • Presolve: Enable or disable presolve routines. (UC only)

Buttons

Solve Button

  • Starts optimization
  • Disabled during solving
  • Changes to Stop when running

Stop Button

  • Appears during solving
  • Terminates solver

Editor Tab

User Interface Guide - Interface Layout

When the Editor tab is active:

  • File Explorer (left pane)
    • Displays the loaded Data Folder (e.g., network, profile, renewables_capacity) and available Julia Solvers (ed.jl, opf_dc.jl, uc.jl, etc.).
    • Selecting a file from the explorer opens it in the editor pane on the right.
  • Editor Pane (center)
    • Shows the contents of the currently selected file.
    • Supports standard editing operations and keyboard shortcuts (e.g., Cmd/Ctrl + S to save, Cmd/Ctrl + W to close the current tab).
    • Multiple files can be opened simultaneously, each in its own tab.
  • File Path Bar (bottom)
    • Shows the full path of the file currently open in the editor (e.g., ed.jl).
    • Helps users verify which file is being edited when working with multiple solver or data files.
  • Console Panel
    • Displays real-time output from the solver when an optimization is running.
    • Can be toggled using the Cmd/Ctrl + J or the button in the upper-right corner

Network Data Tab

User Interface Guide - Interface Layout

The Network Data tab provides a structured view of the input data for the selected test system. It is used to inspect and edit buses, generators, transmission lines, and DC lines before running an optimization.

  • View selector controls how network data are displayed
    • Single view (1x1)
    • Two columns (1x2)
    • Two rows (2x1)
    • Grid (2x2)
  • Object tabs switch between Buses, Generators, Lines, and DC Lines. Each tab label shows the number of records currently loaded (for example, Buses 193).
  • Data table displays the fields for the selected object type (such as BUS ID, NAME, etc.). Cells can be edited directly to modify network parameters.

Editing and file operations

The values in this table are editable. When a cell is modified, the change is highlighted in yellow. You can either apply the pending edits to the network data or revert them to their original values. Network data can also be imported from, or exported to, CSV files.

  • Save Changes apply the edits in the table to the currently loaded network data.
  • Revert to Original discards unsaved edits and restores the data to the state loaded from the test system folder.
  • Import CSV replaces the current table with data loaded from a CSV file that matches the expected schema.
  • Export CSV writes the current table contents to a CSV file for external analysis or version control.

Time Series Tab

User Interface Guide - Interface Layout

The Time Series tab provides an overview of load and renewable generation profiles used by the selected test system. It allows you to inspect how demand and resource availability evolve over time before running an optimization.

Time Range Controls

  • Time Range mode choose whether to select data by Day of Year or by Calendar date.
  • From / To specify the start and end date/time for the time window to be displayed.
  • Load button applies the selected time range and reloads the plot and table.

View Modes

  • Chart displays a time-series line chart of the selected data series (e.g., Demand, Solar, Wind, Hydro).
  • Table shows the same data in tabular form for precise inspection or export.

Chart Interactions

  • Hover tooltips hover over the chart to view the value of each active series (MW) at the time under the cursor.
  • Time Scale switch between Hourly, Daily, and Weekly aggregation.
  • Data Series panel toggle individual series (Demand, Solar, Wind, Hydro) on or off to focus on specific resources.

Console

Solver Output

  • Displays the raw log output from the currently running or most recent optimization (for example, Gurobi progress, convergence information, and final status).

  • Messages are streamed in real time while a solve is in progress.

  • Use Clear to remove the current log contents and prepare for a new run.

Julia REPL

  • Provides an Julia prompt inside KPG Run, where you can enter Julia code for custom exploration.
  • Use Restart button to reset the REPL session, or Clear button to clear the visible output without restarting the process.

The text field at the bottom of the view is the input line; press Enter to execute the current command.

Results Tab

After an optimization run finishes, its results are displayed in the Results tab. Here, you can review the problem configuration, solution status, objective value, and other summary information. The available sub-tabs depend on the selected solver and provide detailed views of the corresponding results.

All solvers return the optimal active-power dispatch after solving.

For OPF models that include network constraints, line flows and bus angles are reported. Among the four built-in solvers, only the AC-OPF model, which considers the full AC network, also provides bus voltage magnitudes and reactive power (Q) outputs. Unit commitment schedules are available only for the UC model.

For more information on these model differences, refer to the Formulation section.

To save results, use the Save to Folder or Download ZIP buttons. These actions export the results in CSV, JSON, and GeoJSON formats to a user-selected location.

Summary View:

  1. Solved problem
  2. Test system
  3. Day
  4. Solution status
  5. Objective value

Detailed Results

Tabs within Results:

  1. Dispatch Table
  2. Network Flows (DC/AC-OPF only)
  3. Commitment Schedule (UC only)
  4. Export Options

Dispatch Table View

User Interface Guide - Interface Layout

Table Columns:

  • Gen: Identifier of each generator.
  • Type: Fuel type of the generator.
  • Bus: Bus name to which the generator is connected.
  • H1–H24: Time periods included in the analysis.

Features:

  • Generator Dispatch plot displays a stacked time-series of active power dispatch (MW) by fuel type over all hours.
  • Hover tooltips hover over the plot to see a pop-up with the hour under the cursor and the dispatched power (MW) for each fuel type at that hour.
  • Fuel-type filter limit the table to selected fuel types.

Network Flows View (OPF Only)

User Interface Guide - Interface Layout

Optimal Power Flow (OPF) solves the optimization problem on a network model and computes power flows on each transmission line. This allows operators to identify which lines are congested. When the flow on a line exceeds its rating, corrective actions are required to relieve the overload.

In KPG Run, the Line Flows tab provides a spreadsheet and a time-series plot showing how power flows evolve over time for each line.

Table Columns:

  • Line: Identifier of each transmission line.
  • From / To: Sending and receiving buses for each line.
  • Rating: Flow limit (thermal rating) of the line.
  • H1–H24: Time periods included in the analysis.

Features:

  • Top Line Flows plot shows a stacked time-series of power flows (MW) for the highest flowing lines over all hours.
  • Hover tooltips hover over the plot to display a pop-up with the hour under the cursor and the power flow for each displayed line at that time.
  • Line-loading filter filters the table by line-loading category:
    • all Lines
    • lines whose loading never exceeds 50% at any hour,
    • lines whose loading exceeds 80% at least once, and
    • all remaining lines (with loading between 50% and 80%).

Line Loading (% of rating):

  • 🔴 Congested (80-100%)
  • 🟡 Heavily loaded (50-80%)
  • 🟢 Normal (0-50%)

Commitment Schedule (UC Only)

User Interface Guide - Interface Layout

Table Columns

  • Gen: Identifier of each transmission line.
  • Type: Sending and receiving buses for each line.
  • Bus: Flow limit (thermal rating) of the line.
  • H1–H24: Time periods included in the analysis.

Features:

  • Commitment markers show the on/off status of each generator for every time period.
  • Hover tooltips hover over the Unit Commitment plot to see the number of online units by fuel type at each hour.
  • Fuel-type filter limit the table to selected fuel types.

Parameter Guide

Day Selection

Input: Day number (1-365)

InputDescription
1January 1
15Mid-January (mid-winter)
75Mid-March (spring)
200Mid-July (mid-summer)
290Mid-October (fall)
365December 31

Validation:

  • Red border if invalid (< 1 or > 365)
  • Tooltip shows valid range
  • Auto-corrects on focus loss

Hour Description

Critical hours:

HourTimeTypical Usage
32-3 AMMinimum load
1211 AM-12 PMMidday, peak solar
141-2 PMPeak load (summer)
185-6 PMEvening peak
207-8 PMWinter evening peak

Results Export

Export Buttons

Both buttons open a dialog to select a directory to store the results data.

  • Save to Folder:
    • Saves result files (CSV, JSON, GeoJSON) to the chosen folder.
  • Download ZIP:
    • Creates a ZIP archive of all result files.

Export Formats

CSV (Tabular data):

A CSV (Comma-Separated Values) file is a plain-text tabular format where each line is a row and fields are separated by a delimiter (typically a comma).

KPG Run exports result data in CSV format. For each model (solver) and feature, results are stored in CSV files with a structure defined for each type, so users can analyze outputs.

Features:

  • Buses
  • Generators
  • Branches
  • DClines

JSON (Structured data):

The JSON format contains a basic summary of the simulation results and the structure of the result files. The format is as follows:

{
"snapshots": [
{
"hour": 1,
"filename": "geojson/snapshot_t01.geojson",
"index": 1,
},
...
{
"hour": 24,
"filename": "geojson/snapshot_t24.geojson",
"index": 24,
}
],
"files": {
"generators": "generators_timeseries.csv",
"branches": "branches_timeseries.csv",
"dclines": "dclines_timeseries.csv",
"buses": "buses_timeseries.csv",
},
"simulation": {
"start_time": "2025-12-16T14:30:00",
"day": "200",
...
"type": "UC",
"system": "KPG193"
}
}

GeoJSON (For KPG View):

Optimization results are stored in GeoJSON format for visualization in KPG View. For each time snapshot, the file contains location and information for buses, generators, and branches, as well as ratings, optimization outputs, feature group information, and some summary values.

{
"features": [
{
"geometry": {
"coordinates": [
Longitude,
Latitude
],
"type": "Point"
},
"id": "Bus_1",
"properties": {
"num_buses": 1,
...
"Hydro_Pmax":0.0
},
"type": "Feature"
},
...
}
]
},
"type": "FeatureCollection",
}

Next Steps