This function simulates an attack on the power grid using the parameter settings you choose the outut of the function is a nested list of igraph objects.
attack_the_grid( g, AttackStrategy, g0 = NULL, TotalAttackRounds = 1000, CascadeMode = TRUE, Demand = "demand", Generation = "generation", EdgeName = "edge_name", VertexName = "name", Net_generation = "net_generation", power_flow = "power_flow", edge_capacity = "edge_capacity", target = "nodes" )
g | An igraph object. The graph that will be attacked the network list is simply list(list(g)). |
---|---|
AttackStrategy | A function that calculates which node to delete the function is is in "quo" form and embedded in an attack type. |
g0 | The grid that will be used to test the largest component against if NULL it uses the given network. |
TotalAttackRounds | The maximum number of nodes to be removed before the process stops. |
CascadeMode | Whether the power flow equations will be used to check line-overloading or not. |
Demand | the name of the node Load variable. A character string. |
Generation | the name of the node generation variable. A character string. |
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. This value indicates the name of the edge attribute that holds power flow, the default is "PowerFlow" |
edge_capacity | A character string. This value indicates the name of the edge attribute that holds the edge limit, the default is "Link.Limit" |
target | A character string. This value defines the columns of the returned it must match the target element of the attack strategy or an error will be thrown if the number of columns of the matrix is exceeded. modularising the function call to attack strategy would solve this, but it is a low priority. |
AttackTheGrid(NetworkList, AttackStrategy, SubstationData, EdgeData, g0 = NULL)#> Error in AttackTheGrid(NetworkList, AttackStrategy, SubstationData, EdgeData, g0 = NULL): could not find function "AttackTheGrid"Out <- AttackTheGrid(NetworkList, AttackStrategy, g0 = NULL, TotalAttackRounds=100, CascadeMode = TRUE, CumulativeAttacks = NULL)#> Error in AttackTheGrid(NetworkList, AttackStrategy, g0 = NULL, TotalAttackRounds = 100, CascadeMode = TRUE, CumulativeAttacks = NULL): could not find function "AttackTheGrid"