Previous topic


Next topic


This Page


AttributeStateProcess.edgeUpdateRule(edge, srcNetwork, dt)

Perform local edge change.

This method is called for each edge in the network during each time step of the simulation. The state of edge and srcNetwork is that of the previous simulation iteration. This method is expected to make any update to edge and return it in its new state. Overload this method when constructing a process.

Parameters :

edge : networkx edge, Structure (<node id 1>, <node id 2>, <attribute dict>)

This is a copy of the current edge in the simulation and will be the target of any changes.

srcNetwork : networkx.Graph

The network where the edge lived during last iteration. Should be treated as constant.

dt : float

Time differential since last iteration.

Returns :

edge : networkx edge, edge with changes.