Private Functions

Private Functions

Distances

haversine{T<:Real}(c1::Tuple{T,T}, c2::Tuple{T,T})

Compute distance between two pairs of latitude and longitude using the haversine formula.

source
haversine(b1::Bus, b2::Bus)

Compute distance between two buses from their latitude and longitude using the haversine formula.

source
subs_dist(inds1, inds2, buses, b_dist)

Compute distance between two substations using equation 1 from the REFERENCE.

REFERENCE: Birchfield, Adam B., et al. "Grid Structural Characteristics as Validation Criteria for Synthetic Networks." IEEE Transactions on Power Systems (2016).

source

Topology building

SyntheticGrids.twst!Function.
twst!(grid, k)

Execute Tunable Weight Spannning Tree algorithm for the grid using weight 'k'.

REFERENCE: Soltan, Saleh, and Gil Zussman. "Generation of synthetic spatially embedded power grid networks." arXiv:1508.04447 [cs.SY], Aug. 2015.

source
reinforce!(grid, m, a, b, g, t, N)

Execute the Reinforcement procedure to increase robustness of a grid.

Arguments:

  • m: total number of connections

  • a, b, g, t: paramaters of the model (see REFERENCE)

  • N: number of nearest neighbors in the average distance computation

REFERENCE: Soltan, Saleh, and Gil Zussman. "Generation of synthetic spatially embedded power grid networks." arXiv:1508.04447 [cs.SY], Aug. 2015.

source
connect_buses!(grid)

Create reference links between buses that are connected according to the connectivity matrix of the grid.

source
connect_subs!(grid)

Determine which substations are connected to each other through their buses.

source
cluster_loads!(grid,nload)

Execute aglomerative clustering of all load buses into 'nload' substations using geographic distances as metric.

source
fill_gen!(sub, gens, MW)

Group generators ('gens') into substations ('subs') by geographic proximity until generation threshold 'MW' is reached.

source
cluster_load_gen!(grid, nboth)

Create 'nboth' substations with both load and generation, chosen randomly.

source
cluster_gens!(grid, ngen)

Execute aglomerative clustering of generators into 'ngen' substations.

source

Graphs

laplacian(con_mat::AbstractMatrix{<:Real})

Return the Laplacian matrix for a graph defined by adjacency matrix con_mat.

source
dijkstra(con_mat::AbstractMatrix{<:Real}, v1)

Compute minimum distances to each node in the network with connectivity matrix con_mat, starting from node v1, using Dijkstra's algorithm.

source
floyd_warshall(weights::AbstractMatrix{<:Real})

Compute minimum distances to each node in the network using Floyd-Warshall's algorithm. Here we assume that the weigths matrix is symmetric.

source

Transmission Line properties

linear_imped(a::Bus, b::Bus)

Return an impedance value for a transmission line connecting buses a and b, using a simple linear approximation. This value is loosely based on the two references below. Values based on resistances for dc currents at 50C and 350kV lines.

REF 1: Electric Power Research Institute (EPRI). Transmission Line Reference Book, 345 kV and Above. Palo Alto, CA: The Institute, 1975. REF 2: J. Glover, M. Sarma and T. Overbye, Power System Analysis and Design. Stamford, CT: Cengage Learning, 2012.

source
rand_imped(a::Bus, b::Bus)

Return an impedance value for a transmission line connecting buses a and b, using a simple linear approximation with a randomly chosen coefficient. The range we adopted is based on the values for ACSR cables from the ref: J. Glover, M. Sarma and T. Overbye, Power System Analysis and Design. Stanford, CT: Cengage Learning, 2012.

source
volt_cap(a::Bus, b::Bus)

Return a current carrying capacity value for a transmission line connecting buses a and b based on their operating voltages. This value is loosely based on the reference: Electric Power Research Institute (EPRI). Transmission Line Reference Book, 345 kV and Above. Palo Alto, CA: The Institute, 1975.

source