PowerFlow: Calculate DC power flow

Description Usage Arguments Value Examples

View source: R/PowerFlow.R

Description

Calculates the PowerFlow from a graph that contains the following attributes, named edges, edgeweights, a balanced power generation and demand column. Writes a new edge attribute of power flow (existing attribute of the same name will be overwritten). The function outputs a a graph with the correct power flow values

Usage

1
2
3
4
5
6
7
8
9
PowerFlow(
  g,
  AZero,
  LineProperties,
  EdgeName = "Link",
  VertexName = "name",
  Net_generation = "BalencedPower",
  power_flow = "PowerFlow"
)

Arguments

g

An igraph object representing the power grid

AZero

A numeric matrix The transmission matrix of the original network

LineProperties

A numeric matrix. a diagonal matrix of the Y characteristic of the network

EdgeName

The variable that holds the edge names, a character string.

VertexName

The variable that holds the names of the nodes, to identify the slack ref. a character string

Net_generation

The name that the net generation data for each node is held in

power_flow

A character string. The name of the edge attribute that will hold the power flow information

Value

A graph with a PowerFlow attribute assigned to the edges

Examples

1
2
3
4
5
PowerFlow(g, AZero, LineProperties,
EdgeName = "Link",
VertexName = "name",
Net_generation = "BalencedPower",
power_flow = "PowerFlow")

JonnoB/PowerGridNetworking documentation built on Aug. 7, 2021, 3:04 a.m.