fnss.netconfig.capacities.set_capacities_eigenvector_gravity

set_capacities_eigenvector_gravity(topology, capacities, capacity_unit='Mbps', max_iter=1000)[source]

Set link capacities proportionally to the product of the eigenvector centralities of the two end-points of the link

Parameters:
topology : Topology

The topology to which link capacities will be set

capacities : list

A list of all possible capacity values

capacity_unit : str, optional

The unit in which capacity value is expressed (e.g. Mbps, Gbps etc..)

max_iter : int, optional

The max number of iteration of the algorithm allowed. If a solution is not found within this period

Raises:
RuntimeError : if the algorithm does not converge in max_iter iterations