Package | Description |
---|---|
com.net2plan.interfaces.networkDesign |
Provides a set of classes and interfaces for the network design tool.
|
com.net2plan.interfaces.simulation |
Provides a set of classes for the online simulator tool.
|
com.net2plan.libraries |
Provides a set of useful libraries to develop algorithms and reports.
|
Modifier and Type | Class and Description |
---|---|
class |
ProtectionSegment
This class contains a representation of a protection segment.
|
Modifier and Type | Method and Description |
---|---|
Link |
NetPlan.addLink(Node originNode,
Node destinationNode,
double capacity,
double lengthInKm,
double propagationSpeedInKmPerSecond,
Map<String,String> attributes,
NetworkLayer... optionalLayerParameter)
Adds a new link.
|
Link |
Demand.coupleToNewLinkCreated(NetworkLayer newLinkLayer)
Creates a new link in the given layer with same end nodes, and couples it to this demand.
|
Link |
Link.getBidirectionalPair()
If the link was added using
addLinkBidirectional() ,
returns the link in the opposite direction (if it was not previously removed). |
Link |
Demand.getCoupledLink()
Returns the link this demand is coupled to.
|
Link |
MulticastTree.getIngressLinkOfNode(Node n)
|
Link |
NetPlan.getLink(int index,
NetworkLayer... optionalLayerParameter)
Returns the link with the given index in the given layer.
|
Link |
NetPlan.getLinkFromId(long uid)
Returns the link with the given unique identifier.
|
Modifier and Type | Method and Description |
---|---|
Pair<Link,Link> |
NetPlan.addLinkBidirectional(Node originNode,
Node destinationNode,
double capacity,
double lengthInKm,
double propagationSpeedInKmPerSecond,
Map<String,String> attributes,
NetworkLayer... optionalLayerParameter)
Adds two links, one in each direction.
|
Pair<Link,Link> |
NetPlan.addLinkBidirectional(Node originNode,
Node destinationNode,
double capacity,
double lengthInKm,
double propagationSpeedInKmPerSecond,
Map<String,String> attributes,
NetworkLayer... optionalLayerParameter)
Adds two links, one in each direction.
|
Map<MulticastDemand,List<Set<Link>>> |
NetPlan.computeMulticastCandidatePathList(DoubleMatrix1D costs,
String solverName,
String solverLibraryName,
double maxSolverTimeInSecondsPerTree,
String... candidateTreeListParamValuePairs)
The same as
computeMulticastCandidatePathList for the default layer |
Map<MulticastDemand,List<Set<Link>>> |
NetPlan.computeMulticastCandidatePathList(NetworkLayer layer,
DoubleMatrix1D linkCosts,
String solverName,
String solverLibraryName,
double maxSolverTimeInSecondsPerTree,
String... candidateTreeListParamValuePairs)
Adds multicast trees specified by those trees that satisfy the options described below.
|
static Map<Demand,List<Pair<List<Link>,List<Link>>>> |
NetPlan.computeUnicastCandidate11PathList(Map<Demand,List<List<Link>>> cpl,
DoubleMatrix1D costs,
int disjointType)
Computes the list of disjoint path pairs for each demand.
|
static Map<Demand,List<Pair<List<Link>,List<Link>>>> |
NetPlan.computeUnicastCandidate11PathList(Map<Demand,List<List<Link>>> cpl,
DoubleMatrix1D costs,
int disjointType)
Computes the list of disjoint path pairs for each demand.
|
Map<Demand,List<List<Link>>> |
NetPlan.computeUnicastCandidatePathList(double[] costs,
String... paramValuePairs)
Adds traffic routes specified by those paths that satisfy the candidate path list options described below.
|
Map<Demand,List<List<Link>>> |
NetPlan.computeUnicastCandidatePathList(NetworkLayer layer,
double[] costs,
String... paramValuePairs)
Adds traffic routes specified by those paths that satisfy the candidate path list options described below.
|
Set<Link> |
MulticastDemand.coupleToNewLinksCreated(NetworkLayer newLinkLayer)
Creates new links in the given layer, from the demand ingress node to each one of the demand egress nodes, and couples these newly created links to the multicast demand.
|
Set<Link> |
SharedRiskGroup.getAffectedLinks()
Returns all the links affected by the SRG at all the layers: the links affected, and the input and output links of the affected nodes
|
Set<Link> |
SharedRiskGroup.getAffectedLinks(NetworkLayer layer)
Returns all the links affected by this SRG, but only those at a particular layer.
|
Set<Link> |
MulticastDemand.getCoupledLinks()
|
Map<Pair<Demand,Link>,Double> |
ProtectionSegment.getForwardingRules()
This method cannot be called for protection segments (raises an exception)
|
Map<Pair<Demand,Link>,Double> |
Link.getForwardingRules()
Returns the non zero forwarding rules that are defined in the link.
|
Map<Pair<Demand,Link>,Double> |
Demand.getForwardingRules()
Returns the non zero forwarding rules as a map of pairs demand-link, and its associated splitting factor (between 0 and 1).
|
Map<Pair<Demand,Link>,Double> |
Node.getForwardingRules(Demand demand)
Returns the set of forwarding rules of links initiated in the node and associated to the given demand (the links are then in the same layer
as the demand), that have a non-zero splitting factor
|
Map<Pair<Demand,Link>,Double> |
Node.getForwardingRules(NetworkLayer... optionalLayerParameter)
Returns the set of forwarding rules of links initiated in the node of the given layer,
which have a non-zero splitting factor.
|
Map<Pair<Demand,Link>,Double> |
NetPlan.getForwardingRules(NetworkLayer... optionalLayerParameter)
Returns the forwarding rules for the given layer.
|
Set<Link> |
Node.getIncomingLinks(NetworkLayer... optionalLayerParameter)
Returns the set of links ending in the node, in the given layer.
|
Set<Link> |
Node.getIncomingLinksAllLayers()
Returns the set of links ending in the node at any layer.
|
Set<Link> |
MulticastTree.getInitialLinkSet()
Returns the initial
Set of Links of the tree when it was created. |
List<Link> |
Route.getInitialSequenceOfLinks()
Return the sequence of links of the route when it was created (before any rerouting operation could be made).
|
Set<Link> |
SharedRiskGroup.getLinks()
Returns the set of links associated to the SRG (fail, when the SRG is in failure state).
|
List<Link> |
NetPlan.getLinks(NetworkLayer... optionalLayerParameter)
Return a list of all the links in the given layer.
|
Set<Link> |
SharedRiskGroup.getLinks(NetworkLayer layer)
Returns the set of links associated to the SRG (fail, when the SRG is in failure state), but only those belonging to the given layer.
|
Set<Link> |
NetPlan.getLinksAreBottleneck(NetworkLayer... optionalLayerParameter)
Returns the set of links that are a bottleneck, i.e the fraction of occupied capacity respect to the total (including the capacities in the protection segments)
is highest.
|
Set<Link> |
NetPlan.getLinksCoupledToMulticastDemands(NetworkLayer... optionalLayerParameter)
Returns the set of links that are coupled to a multicast demand in the given layer.
|
Set<Link> |
NetPlan.getLinksCoupledToUnicastDemands(NetworkLayer... optionalLayerParameter)
Returns the set of links that are couple to a unicast demand in the given layer.
|
Set<Link> |
NetPlan.getLinksDown(NetworkLayer... optionalLayerParameter)
Returns the set of links that are down in the given layer.
|
Set<Link> |
NetPlan.getLinksDownAllLayers()
Returns the set of links that are down in all layers.
|
Set<Link> |
MulticastTree.getLinkSet()
Returns the
Set of Links of the tree |
Set<Link> |
NetPlan.getLinksOversubscribed(NetworkLayer... optionalLayerParameter)
Returns the set of links oversuscribed: the total occupied capacity (including the traffic in the protection segments) exceeds the link capacity
(including the reserved capacity by the protection segments).
|
Set<Link> |
NetPlan.getLinksUp(NetworkLayer... optionalLayerParameter)
Returns the set of links that are up in the given layer.
|
Set<Link> |
NetPlan.getLinksUpAllLayers()
Returns the set of links that are up in all layers.
|
Set<Link> |
NetPlan.getLinksWithZeroCapacity(NetworkLayer... optionalLayerParameter)
Returns the set of links that have zero capacity in the given layer.
|
Set<Link> |
NetPlan.getNodePairLinks(Node originNode,
Node destinationNode,
boolean returnLinksInBothDirections,
NetworkLayer... optionalLayerParameter)
Gets the set of links at the given layer from the given nodes (if
returnLinksInBothDirections is true , also the reversed links are included). |
Set<Link> |
Node.getOutgoingLinks(NetworkLayer... optionalLayerParameter)
Returns the set of links initiated in the node, in the given layer.
|
Set<Link> |
Node.getOutgoingLinksAllLayers()
Returns the set of links initiated in the node in all layer.
|
Set<Link> |
MulticastTree.getOutputLinkOfNode(Node n)
|
List<Link> |
ProtectionSegment.getSeqLinks()
Returns the protection segment sequence of links.
|
List<Link> |
Route.getSeqLinksAndProtectionSegments()
Returns the route current sequence of traversed links and protection segments (which are subclasses of Link).
|
List<Link> |
Route.getSeqLinksRealPath()
Returns the route sequence of traversed links.
|
List<Link> |
MulticastTree.getSeqLinksToEgressNode(Node egressNode)
|
Modifier and Type | Method and Description |
---|---|
void |
SharedRiskGroup.addLink(Link link)
Adds a link to the SRG.
|
void |
Demand.coupleToUpperLayerLink(Link link)
Couples this demand to a link in an upper layer.
|
double |
NetPlan.getForwardingRuleCarriedTraffic(Demand demand,
Link link)
Returns the traffic that is carried using a forwarding rule, in the given layer.
|
double |
NetPlan.getForwardingRuleSplittingFactor(Demand demand,
Link link,
NetworkLayer... optionalLayerParameter)
Returns the splitting factor of the forwarding rule of the given demand and link.
|
int |
Route.getNumberOfTimesLinkIsTraversed(Link e)
Returns the number of times that a particular link (not a protection segment) is traversed in its real path (that when the traversed protection segments are expended in its links)
|
void |
SharedRiskGroup.removeLink(Link e)
Removes a link from the set of links of the SRG.
|
double |
NetPlan.setForwardingRule(Demand demand,
Link link,
double splittingRatio)
Adds a new forwarding rule (or override an existing one), to the layer of the demand and link (must be in the same layer).
|
Modifier and Type | Method and Description |
---|---|
MulticastTree |
NetPlan.addMulticastTree(MulticastDemand demand,
double carriedTraffic,
double occupiedLinkCapacity,
Set<Link> linkSet,
Map<String,String> attributes)
Adds a new traffic multicast tree.
|
void |
NetPlan.addMulticastTreesFromCandidateTreeList(Map<MulticastDemand,List<Set<Link>>> cpl)
Adds multiple multicast trees from a Candidate Tree list.
|
ProtectionSegment |
NetPlan.addProtectionSegment(List<Link> sequenceOfLinks,
double reservedCapacity,
Map<String,String> attributes)
Adds a new protection segment.
|
Route |
NetPlan.addRoute(Demand demand,
double carriedTraffic,
double occupiedLinkCapacity,
List<Link> sequenceOfLinks,
Map<String,String> attributes)
Adds a new traffic route
Important: Routing type must be
SOURCE_ROUTING . |
void |
NetPlan.addRoutesAndProtectionSegmentFromCandidate11PathList(Map<Demand,List<Pair<List<Link>,List<Link>>>> cpl11) |
void |
NetPlan.addRoutesAndProtectionSegmentFromCandidate11PathList(Map<Demand,List<Pair<List<Link>,List<Link>>>> cpl11) |
void |
NetPlan.addRoutesFromCandidatePathList(Map<Demand,List<List<Link>>> cpl)
Adds multiples routes from a Candidate Path List.
|
NetworkLayer |
NetPlan.checkContiguousPath(List<Link> links,
NetworkLayer layer,
Node originNode,
Node destinationNode)
Checks that the input sequence of links belong to the same layer and follow a contiguous path.
|
static Map<Demand,List<Pair<List<Link>,List<Link>>>> |
NetPlan.computeUnicastCandidate11PathList(Map<Demand,List<List<Link>>> cpl,
DoubleMatrix1D costs,
int disjointType)
Computes the list of disjoint path pairs for each demand.
|
void |
MulticastDemand.couple(Set<Link> links)
Couples this demand to the given
Set of Links in the upper layer. |
boolean |
NetPlan.isUp(Collection<Link> linksAndOrProtectionSegments)
Indicates whether or not a path, multicast tree or arbitrary collection of links (and/or protection segments) is up.
|
void |
NetPlan.setForwardingRules(Collection<Demand> demands,
Collection<Link> links,
Collection<Double> splittingFactors,
boolean includeUnusedRules)
Adds a set of forwarding rules (or override existing ones).
|
void |
MulticastTree.setLinks(Set<Link> newLinkSet)
Sets the new set of
Links of the multicast tree. |
void |
NetPlan.setLinksAndNodesFailureState(Collection<Link> linksToSetAsUp,
Collection<Link> linksToSetAsDown,
Collection<Node> nodesToSetAsUp,
Collection<Node> nodesToSetAsDown)
Changes the failure state of the links and updates the routes/trees/segments (they do not carry traffic nor occupy capacity), and hop-by-hop routing
(no traffic is forwarded in links down)
|
void |
NetPlan.setLinksAndNodesFailureState(Collection<Link> linksToSetAsUp,
Collection<Link> linksToSetAsDown,
Collection<Node> nodesToSetAsUp,
Collection<Node> nodesToSetAsDown)
Changes the failure state of the links and updates the routes/trees/segments (they do not carry traffic nor occupy capacity), and hop-by-hop routing
(no traffic is forwarded in links down)
|
void |
Route.setSeqLinksAndProtectionSegments(List<Link> seqLinksAndProtectionSegments)
Sets the new sequence of links and/or protection segments travsered by the route.
|
Modifier and Type | Field and Description |
---|---|
Link |
SimEvent.LinkRemove.link |
Link |
SimEvent.LinkModify.link |
Link |
SimEvent.LinkAdd.linkAddedToFillByProcessor |
Modifier and Type | Field and Description |
---|---|
Collection<Link> |
SimEvent.NodesAndLinksChangeFailureState.linksToDown |
Collection<Link> |
SimEvent.NodesAndLinksChangeFailureState.linksToUp |
List<Link> |
SimEvent.RouteAdd.seqLinks |
List<Link> |
SimEvent.RouteModify.seqLinks |
List<Link> |
SimEvent.SegmentAdd.seqLinks |
Constructor and Description |
---|
LinkModify(Link link,
double newCapacity)
Default constructor
|
LinkRemove(Link link)
Default constructor
|
Constructor and Description |
---|
NodesAndLinksChangeFailureState(Collection<Node> nodesToUp,
Collection<Node> nodesToDown,
Collection<Link> linksToUp,
Collection<Link> linksToDown)
Default constructor.
|
NodesAndLinksChangeFailureState(Collection<Node> nodesToUp,
Collection<Node> nodesToDown,
Collection<Link> linksToUp,
Collection<Link> linksToDown)
Default constructor.
|
RouteAdd(Demand demand,
List<Link> seqLinks,
double carriedTraffic,
double occupiedLinkCapacity)
Default constructor.
|
RouteModify(Route route,
List<Link> seqLinks,
double carriedTraffic,
double occupiedLinkCapacity)
Default constructor.
|
SegmentAdd(Set<Route> associatedRoutes,
List<Link> seqLinks,
double reservedLinkCapacity)
Default constructor.
|
Modifier and Type | Field and Description |
---|---|
List<Link> |
WDMUtils.LightpathModify.seqLinks |
List<Link> |
WDMUtils.LightpathAdd.seqLinks_backup |
List<Link> |
WDMUtils.LightpathAdd.seqLinks_primary |
Modifier and Type | Method and Description |
---|---|
static Triple<DoubleMatrix2D,Map<Link,Set<Node>>,Map<Node,Set<Link>>> |
WirelessUtils.computeInterferenceMap(List<Node> nodes,
List<Link> links,
boolean simultaneousTxAndRxPossible)
Given a wireless network where a node cannot simultanously receive signals from two different nodes (or a collision would be produced and no signal is correctly received), this function computes the cases in which a node transmission interferes with a link reception,
and returns this information in several structures.
|
static Triple<DoubleMatrix2D,Map<Link,Set<Node>>,Map<Node,Set<Link>>> |
WirelessUtils.computeInterferenceMap(List<Node> nodes,
List<Link> links,
boolean simultaneousTxAndRxPossible)
Given a wireless network where a node cannot simultanously receive signals from two different nodes (or a collision would be produced and no signal is correctly received), this function computes the cases in which a node transmission interferes with a link reception,
and returns this information in several structures.
|
static List<List<Link>> |
GraphUtils.getAllLooplessShortestPaths(List<Node> nodes,
List<Link> links,
Node originNode,
Node destinationNode,
Map<Link,Double> linkCostMap)
Returns all the loopless shortest paths between two nodes.
|
static List<Link> |
GraphUtils.getCapacitatedShortestPath(Collection<Node> nodes,
Collection<Link> links,
Node originNode,
Node destinationNode,
Map<Link,Double> linkCostMap,
Map<Link,Double> linkSpareCapacityMap,
double capacityGoal) |
static List<List<Link>> |
GraphUtils.getKLooplessShortestPaths(List<Node> nodes,
List<Link> links,
Node originNode,
Node destinationNode,
Map<Link,Double> linkCostMap,
int K,
double maxLengthInKm,
int maxNumHops,
double maxPropDelayInMs,
double maxRouteCost,
double maxRouteCostFactorRespectToShortestPath,
double maxRouteCostRespectToShortestPath)
Returns the K-loopless shortest paths between two nodes, satisfying some user-defined constraints.
|
static List<Set<Link>> |
GraphUtils.getKMinimumCostMulticastTrees(List<Link> links,
Node originNode,
Set<Node> destinationNodes,
DoubleMatrix2D Aout_ne,
DoubleMatrix2D Ain_ne,
DoubleMatrix1D linkCost,
String solverName,
String solverLibraryName,
double maxSolverTimeInSecondsPerTree,
int K,
int maxCopyCapability,
double maxE2ELengthInKm,
int maxE2ENumHops,
double maxE2EPropDelayInMs,
double maxTreeCost,
double maxTreeCostFactorRespectToMinimumCostTree,
double maxTreeCostRespectToMinimumCostTree)
Returns the K-minimum cost multicast trees starting in the originNode and ending in the set destinationNodes, satisfying some user-defined constraints.
|
static Set<Link> |
GraphUtils.getMinimumCostMulticastTree(List<Link> links,
DoubleMatrix2D Aout_ne,
DoubleMatrix2D Ain_ne,
DoubleMatrix1D linkCost,
Node originNode,
Set<Node> destinationNodes,
int maxCopyCapability,
int maxE2ENumHops,
double maxE2ELengthInKm,
double maxE2EPropDelayInMs,
String solverName,
String solverLibraryName,
double maxSolverTimeInSeconds,
String... solverParam) |
static List<Link> |
GraphUtils.getShortestPath(Collection<Node> nodes,
Collection<Link> links,
Node originNode,
Node destinationNode,
Map<Link,Double> linkCostMap)
Obtains the sequence of links representing the (unidirectional) shortest path between two nodes.
|
static List<List<Link>> |
GraphUtils.getTwoLinkDisjointPaths(Collection<Node> nodes,
Collection<Link> links,
Node originNode,
Node destinationNode,
Map<Link,Double> linkCostMap)
Returns the shortest pair of link-disjoint paths, where each item represents a path.
|
static List<List<Link>> |
GraphUtils.getTwoNodeDisjointPaths(Collection<Node> nodes,
Collection<Link> links,
Node originNode,
Node destinationNode,
Map<Link,Double> linkCostMap)
Returns the shortest pair of node-disjoint paths, where each item represents a path.
|
Modifier and Type | Method and Description |
---|---|
static int |
WDMUtils.getFiberNumWavelengths(Link fiber)
Returns the number of wavelengths for the given fiber.
|
static double |
IPUtils.getLinkWeight(Link link)
Returns the weight associated to a given link.
|
static void |
WDMUtils.setFiberNumWavelengths(Link fiber,
int numWavelengths)
Sets the number of wavelengths available on the given fiber.
|
static void |
IPUtils.setLinkWeight(Link link,
double linkWeight)
Sets the weight associated to the link.
|
Modifier and Type | Method and Description |
---|---|
static Route |
WDMUtils.addLightpathAndUpdateOccupancy(Demand demand,
List<Link> seqFibers,
double binaryRatePerChannel,
int[] seqWavelengths,
DoubleMatrix2D wavelengthFiberOccupancy)
Creates a new lightpath and updates the wavelength occupancy.
|
static Route |
WDMUtils.addLightpathAndUpdateOccupancy(Demand demand,
List<Link> seqFibers,
double binaryRatePerChannel,
int[] seqWavelengths,
int[] seqRegenerators,
DoubleMatrix2D wavelengthFiberOccupancy,
DoubleMatrix1D nodeRegeneratorOccupancy)
Creates a new lightpath and updates the wavelength occupancy.
|
static Route |
WDMUtils.addLightpathAndUpdateOccupancy(Demand demand,
List<Link> seqFibers,
double binaryRatePerChannel,
int wavelengthId,
DoubleMatrix2D wavelengthFiberOccupancy)
Creates a new lightpath and updates the wavelength occupancy.
|
static ProtectionSegment |
WDMUtils.addLightpathAsProtectionSegmentAndUpdateOccupancy(List<Link> seqFibers,
int[] seqWavelengths,
DoubleMatrix2D wavelengthFiberOccupancy)
Creates a new protection lightpath and updates the wavelength occupancy.
|
static ProtectionSegment |
WDMUtils.addLightpathAsProtectionSegmentAndUpdateOccupancy(List<Link> seqFibers,
int[] seqWavelengths,
int[] seqRegenerators,
DoubleMatrix2D wavelengthFiberOccupancy,
DoubleMatrix1D nodeRegeneratorOccupancy)
Creates a new protection lightpath and updates the wavelength occupancy.
|
static ProtectionSegment |
WDMUtils.addLightpathAsProtectionSegmentAndUpdateOccupancy(List<Link> seqFibers,
int wavelengthId,
DoubleMatrix2D wavelengthFiberOccupancy)
Creates a new protection lightpath and updates the wavelength occupancy.
|
static void |
WDMUtils.allocateResources(List<Link> seqFibers,
int[] seqWavelengths,
DoubleMatrix2D wavelengthFiberOccupancy,
int[] seqRegenerators,
DoubleMatrix1D nodeRegeneratorOccupancy)
Updates
wavelengthFiberOccupancy to consider that a new lightpath is occupying
a wavelength in each fiber. |
static void |
GraphUtils.checkRouteContinuity(List<Link> seqLinks,
Constants.CheckRoutingCycleType checkCycles)
Checks for validity of a given path (continuity and, optionally, no loops).
|
static DoubleMatrix2D |
IPUtils.computeECMPForwardingRules_fde(List<Node> nodes,
List<Link> links,
List<Demand> demands,
DoubleMatrix1D linkWeightVector) |
static DoubleMatrix2D |
IPUtils.computeECMPRoutingTableMatrix_fte(List<Node> nodes,
List<Link> links,
DoubleMatrix1D linkWeightVector)
Computes the routing table matrix according to an OSPF/ECMP scheme.
|
static Triple<DoubleMatrix2D,Map<Link,Set<Node>>,Map<Node,Set<Link>>> |
WirelessUtils.computeInterferenceMap(List<Node> nodes,
List<Link> links,
boolean simultaneousTxAndRxPossible)
Given a wireless network where a node cannot simultanously receive signals from two different nodes (or a collision would be produced and no signal is correctly received), this function computes the cases in which a node transmission interferes with a link reception,
and returns this information in several structures.
|
static DoubleMatrix2D |
WirelessUtils.computeInterferenceMatrixNaturalUnits(List<Link> links,
double interferenceAttenuationFactor_nu,
double pathLossExponent)
Computes the interference matrix in a network subject to soft interferences: a matrix with as many rows and columns as links, with the gain in natural units of the signal from origin of e1 to destination of e2.
|
static int[] |
WDMUtils.computeRegeneratorPositions(List<Link> seqFibers,
DoubleMatrix1D l_f,
double maxRegeneratorDistanceInKm)
Returns the list of nodes within the lightpath route containing a regenerator,
only following a distance criterium, assuming no wavelength conversion is required.
|
static int[] |
WDMUtils.computeRegeneratorPositions(List<Link> seqFibers,
int[] seqWavelengths,
DoubleMatrix1D l_f,
double maxRegeneratorDistanceInKm)
Returns the list of nodes within the lightpath route containing a regenerator,
only following a distance criterium, assuming wavelength conversion is required.
|
static DoubleMatrix2D |
WirelessUtils.computeSchedulingMatrix(List<Link> links)
Given a wireless network where a node cannot simultanously receive signals from two different nodes (or a collision would be produced and no signal is correctly received),
and cannot transmit and receive at the same time, this function computes the scheduling matrix, with one row per link, and one column for each VALID schedule:
in a valid schedule, all the links active (with a 1 in the associated row) could simultaneously transmit with no collision.
|
void |
GraphTheoryMetrics.configureLinkCostMap(Map<Link,Double> linkCostMap)
Re-configures link cost setting.
|
static Quadruple<DoubleMatrix2D,DoubleMatrix1D,DoubleMatrix1D,List<Constants.RoutingCycleType>> |
GraphUtils.convert_fde2xde(List<Node> nodes,
List<Link> links,
List<Demand> demands,
DoubleMatrix1D h_d,
DoubleMatrix2D f_de)
Given a forwarding rule mapping (fractions of traffic entering a node from demand 'd', leaving that node through link 'e'), and an offered traffic to the network,
it generates the resulting demand-link routing in the form x_de (amount of traffic from demand d, transmitted through link e).
|
static Quadruple<DoubleMatrix2D,DoubleMatrix1D,DoubleMatrix1D,List<Constants.RoutingCycleType>> |
GraphUtils.convert_fte2xde(List<Node> nodes,
List<Link> links,
List<Demand> demands,
DoubleMatrix2D f_te)
Given a destination-based routing in the form f_te (fractions of traffic in a node, that is forwarded through each of its output links), and an offered traffic to the network, it generates the resulting demand-link routing in the form x_de (amount of traffic from demand d, transmitted through link e).
|
static void |
GraphUtils.convert_fte2xp(List<Node> nodes,
List<Link> links,
List<Demand> demands,
DoubleMatrix1D h_d,
DoubleMatrix2D f_te,
List<Demand> d_p,
List<Double> x_p,
List<List<Link>> pathList)
Given a destination-based routing in the form f_te (fractions of traffic in a node, that is forwarded through each of its
output links), and an offered traffic to the network, it generates the resulting set of paths that are produced.
|
static void |
GraphUtils.convert_fte2xp(List<Node> nodes,
List<Link> links,
List<Demand> demands,
DoubleMatrix1D h_d,
DoubleMatrix2D f_te,
List<Demand> d_p,
List<Double> x_p,
List<List<Link>> pathList)
Given a destination-based routing in the form f_te (fractions of traffic in a node, that is forwarded through each of its
output links), and an offered traffic to the network, it generates the resulting set of paths that are produced.
|
static DoubleMatrix2D |
GraphUtils.convert_fte2xte(List<Node> nodes,
List<Link> links,
List<Demand> demands,
DoubleMatrix2D f_te,
DoubleMatrix1D h_d)
Given a destination-based routing in the form f_te (fractions of traffic in a node, that is forwarded through each of its output links), and an offered traffic to the network, it generates the resulting destination-based routing in the form x_te (amount of traffic targeted to node t, transmitted through link e).
|
static DoubleMatrix2D |
GraphUtils.convert_xde2fde(List<Node> nodes,
List<Link> links,
List<Demand> demands,
DoubleMatrix2D x_de)
Given a demand-link routing in the form x_de (amount of traffic from demand d, transmitted through link e), returns the equivalent forwarding rule mapping (fractions of traffic entering a node from demand 'd', leaving that node through link 'e').
|
static int |
GraphUtils.convert_xde2xp(List<Node> nodes,
List<Link> links,
List<Demand> demands,
DoubleMatrix2D x_de,
List<Demand> d_p,
List<Double> x_p,
List<List<Link>> pathList)
Converts the routing in the form x_de into a set of loopless routes.
|
static int |
GraphUtils.convert_xde2xp(List<Node> nodes,
List<Link> links,
List<Demand> demands,
DoubleMatrix2D x_de,
List<Demand> d_p,
List<Double> x_p,
List<List<Link>> pathList)
Converts the routing in the form x_de into a set of loopless routes.
|
static DoubleMatrix2D |
GraphUtils.convert_xde2xte(List<Node> nodes,
List<Link> links,
List<Demand> demands,
DoubleMatrix2D x_de)
Given a demand-link routing in the form x_de (amount of traffic from demand d, transmitted through link e), returns the equivalent forwarding rule mapping (fractions of traffic entering a node from demand 'd', leaving that node through link 'e').
|
static DoubleMatrix2D |
GraphUtils.convert_xp2fte(List<Node> nodes,
List<Link> links,
List<Demand> demands,
List<Route> routes)
Given a set of traffic routes and their carried traffic returns a destination-based routing in the form fte (fractions of traffic in a node, that is forwarded through each of its output links).
|
static DoubleMatrix2D |
GraphUtils.convert_xp2xde(List<Link> links,
List<Demand> demands,
List<Route> routes)
Given a path-based routing, returns the amount of traffic for each demand d traversing each link e.
|
static DoubleMatrix2D |
GraphUtils.convert_xp2xte(List<Node> nodes,
List<Link> links,
List<Demand> demands,
List<Route> routes)
Given a set of traffic routes and their carried traffic returns a destination-based routing in the form x_te (amount of traffic targeted to node t, transmitted through link e).
|
static DoubleMatrix1D |
GraphUtils.convert_xp2ye(List<Link> links,
List<Route> routes)
Returns the carried traffic per link.
|
static DoubleMatrix2D |
GraphUtils.convert_xte2fte(List<Node> nodes,
List<Link> links,
DoubleMatrix2D x_te)
Given a destination-based routing in the form of an array x_te (amount of traffic targeted to node t, transmitted through link e), it returns the associated destination-based routing in the form of fractions f_te (fraction of the traffic targeted to node t that arrives (or is generated in) node a(e) (the initial node of link e), that is forwarded through link e).
|
static double |
GraphUtils.convertPath2PathCost(List<Link> seqLinks,
DoubleMatrix1D linkCostMap)
Returns the total cost for a given path, which is equal to the sum of the cost of each traversed link.
|
static List<Double> |
GraphUtils.convertPathList2PathCost(List<List<Link>> pathList,
DoubleMatrix1D linkCostMap)
Returns the total cost for a given a list of paths.
|
static List<Node> |
GraphUtils.convertSequenceOfLinksToSequenceOfNodes(List<Link> seqLinks)
Converts a given sequence of links to the corresponding sequence of nodes.
|
static Set<SharedRiskGroup> |
SRGUtils.getAffectingSRGs(Collection<Link> links)
Returns a set of SRGs that are affecting the given links.
|
static List<List<Link>> |
GraphUtils.getAllLooplessShortestPaths(List<Node> nodes,
List<Link> links,
Node originNode,
Node destinationNode,
Map<Link,Double> linkCostMap)
Returns all the loopless shortest paths between two nodes.
|
static List<List<Link>> |
GraphUtils.getAllLooplessShortestPaths(List<Node> nodes,
List<Link> links,
Node originNode,
Node destinationNode,
Map<Link,Double> linkCostMap)
Returns all the loopless shortest paths between two nodes.
|
static DoubleMatrix2D |
GraphUtils.getBidirectionalMatrix(List<Node> nodes,
List<Link> linkMap)
Given a map of links representing a bidirectional topology, with the same number of links on each direction for each node pair, it bundles into opposite link pairs and computes the bidirectional matrix.
|
static List<Link> |
GraphUtils.getCapacitatedShortestPath(Collection<Node> nodes,
Collection<Link> links,
Node originNode,
Node destinationNode,
Map<Link,Double> linkCostMap,
Map<Link,Double> linkSpareCapacityMap,
double capacityGoal) |
static List<Link> |
GraphUtils.getCapacitatedShortestPath(Collection<Node> nodes,
Collection<Link> links,
Node originNode,
Node destinationNode,
Map<Link,Double> linkCostMap,
Map<Link,Double> linkSpareCapacityMap,
double capacityGoal) |
static List<Link> |
GraphUtils.getCapacitatedShortestPath(Collection<Node> nodes,
Collection<Link> links,
Node originNode,
Node destinationNode,
Map<Link,Double> linkCostMap,
Map<Link,Double> linkSpareCapacityMap,
double capacityGoal) |
static List<List<Link>> |
GraphUtils.getKLooplessShortestPaths(List<Node> nodes,
List<Link> links,
Node originNode,
Node destinationNode,
Map<Link,Double> linkCostMap,
int K,
double maxLengthInKm,
int maxNumHops,
double maxPropDelayInMs,
double maxRouteCost,
double maxRouteCostFactorRespectToShortestPath,
double maxRouteCostRespectToShortestPath)
Returns the K-loopless shortest paths between two nodes, satisfying some user-defined constraints.
|
static List<List<Link>> |
GraphUtils.getKLooplessShortestPaths(List<Node> nodes,
List<Link> links,
Node originNode,
Node destinationNode,
Map<Link,Double> linkCostMap,
int K,
double maxLengthInKm,
int maxNumHops,
double maxPropDelayInMs,
double maxRouteCost,
double maxRouteCostFactorRespectToShortestPath,
double maxRouteCostRespectToShortestPath)
Returns the K-loopless shortest paths between two nodes, satisfying some user-defined constraints.
|
static List<Set<Link>> |
GraphUtils.getKMinimumCostMulticastTrees(List<Link> links,
Node originNode,
Set<Node> destinationNodes,
DoubleMatrix2D Aout_ne,
DoubleMatrix2D Ain_ne,
DoubleMatrix1D linkCost,
String solverName,
String solverLibraryName,
double maxSolverTimeInSecondsPerTree,
int K,
int maxCopyCapability,
double maxE2ELengthInKm,
int maxE2ENumHops,
double maxE2EPropDelayInMs,
double maxTreeCost,
double maxTreeCostFactorRespectToMinimumCostTree,
double maxTreeCostRespectToMinimumCostTree)
Returns the K-minimum cost multicast trees starting in the originNode and ending in the set destinationNodes, satisfying some user-defined constraints.
|
static Set<Link> |
GraphUtils.getMinimumCostMulticastTree(List<Link> links,
DoubleMatrix2D Aout_ne,
DoubleMatrix2D Ain_ne,
DoubleMatrix1D linkCost,
Node originNode,
Set<Node> destinationNodes,
int maxCopyCapability,
int maxE2ENumHops,
double maxE2ELengthInKm,
double maxE2EPropDelayInMs,
String solverName,
String solverLibraryName,
double maxSolverTimeInSeconds,
String... solverParam) |
static List<Link> |
GraphUtils.getShortestPath(Collection<Node> nodes,
Collection<Link> links,
Node originNode,
Node destinationNode,
Map<Link,Double> linkCostMap)
Obtains the sequence of links representing the (unidirectional) shortest path between two nodes.
|
static List<Link> |
GraphUtils.getShortestPath(Collection<Node> nodes,
Collection<Link> links,
Node originNode,
Node destinationNode,
Map<Link,Double> linkCostMap)
Obtains the sequence of links representing the (unidirectional) shortest path between two nodes.
|
static List<List<Link>> |
GraphUtils.getTwoLinkDisjointPaths(Collection<Node> nodes,
Collection<Link> links,
Node originNode,
Node destinationNode,
Map<Link,Double> linkCostMap)
Returns the shortest pair of link-disjoint paths, where each item represents a path.
|
static List<List<Link>> |
GraphUtils.getTwoLinkDisjointPaths(Collection<Node> nodes,
Collection<Link> links,
Node originNode,
Node destinationNode,
Map<Link,Double> linkCostMap)
Returns the shortest pair of link-disjoint paths, where each item represents a path.
|
static List<List<Link>> |
GraphUtils.getTwoNodeDisjointPaths(Collection<Node> nodes,
Collection<Link> links,
Node originNode,
Node destinationNode,
Map<Link,Double> linkCostMap)
Returns the shortest pair of node-disjoint paths, where each item represents a path.
|
static List<List<Link>> |
GraphUtils.getTwoNodeDisjointPaths(Collection<Node> nodes,
Collection<Link> links,
Node originNode,
Node destinationNode,
Map<Link,Double> linkCostMap)
Returns the shortest pair of node-disjoint paths, where each item represents a path.
|
static boolean |
GraphUtils.isBidirectional(List<Node> nodes,
List<Link> links)
Checks whether the physical topology has the same number of links between each node pair in both directions (assuming multi-digraphs).
|
static boolean |
GraphUtils.isConnected(List<Node> nodes,
List<Link> links)
Check whether the physical topology is connected, that is, if it is possible to connect every node to each other, but only in a subset of nodes (subgraph).
|
static boolean |
WDMUtils.isNonConflictingRWA(List<Link> links,
int[] seqWavelengths,
DoubleMatrix2D wavelengthFiberOccupancy)
Returns
true if the given sequence of wavelengths has not been allocated in the given sequence of links, false otherwise. |
static boolean |
WDMUtils.isNonConflictingRWAPair(List<Link> linksPrimary,
int[] seqWavelengthsPrimary,
List<Link> linksBackup,
int[] seqWavelengthsBackup,
DoubleMatrix2D wavelengthFiberOccupancy)
Returns
true if the given pair of sequences of wavelengths has not been allocated in the given pair of sequences of links, false otherwise. |
static boolean |
WDMUtils.isNonConflictingRWAPair(List<Link> linksPrimary,
int[] seqWavelengthsPrimary,
List<Link> linksBackup,
int[] seqWavelengthsBackup,
DoubleMatrix2D wavelengthFiberOccupancy)
Returns
true if the given pair of sequences of wavelengths has not been allocated in the given pair of sequences of links, false otherwise. |
static boolean |
GraphUtils.isSimple(List<Node> nodes,
List<Link> links)
Check whether the physical topology is simple, that is, if it has at most one unidirectional link from a node to each other.
|
static void |
WDMUtils.releaseResources(List<Link> seqFibers,
int[] seqWavelengths,
DoubleMatrix2D wavelengthFiberOccupancy,
int[] seqRegenerators,
DoubleMatrix1D nodeRegeneratorOccupancy)
Updates
wavelengthFiberOccupancy to consider that a lightpath is releasing
used wavelengths. |
static DoubleMatrix2D |
GraphUtils.removeCyclesFrom_xde(List<Node> nodes,
List<Link> links,
List<Demand> demands,
DoubleMatrix2D x_de,
boolean xdeAsFractionRespecttoDemandOfferedTraffic,
String solverName,
String solverLibraryName,
double maxSolverTimeInSecondsPerDemand)
Removes open or closed cycles from the x_de routing matrix, for the given set of demands.
|
static DoubleMatrix2D |
GraphUtils.removeCyclesFrom_xte(List<Node> nodes,
List<Link> links,
DoubleMatrix2D trafficMatrix,
DoubleMatrix2D x_te,
String solverName,
String solverLibraryName,
double maxSolverTimeInSecondsPerDestination)
Removes open or closed cycles from the x_de routing matrix, for the given set of demands.
|
static String |
IPUtils.routingTableMatrixToString(List<Node> nodes,
List<Link> links,
DoubleMatrix2D f_te)
Outputs a given set of routing tables to a
String . |
static DoubleMatrix1D |
GraphUtils.simplifyLinkMap(List<Link> links,
DoubleMatrix1D linkCostMap)
Given a list of links that may contain multiple links between some node pairs, returns a matrix where appears, for each node pair, the link having the lowest weight (links whose weight is equal to
Double.MAX_VALUE are included). |
static int[] |
WDMUtils.WA_firstFit(List<Link> seqFibers,
DoubleMatrix2D wavelengthFiberOccupancy)
Wavelength assignment algorithm based on a first-fit fashion.
|
static Pair<int[],int[]> |
WDMUtils.WA_firstFitTwoRoutes(List<Link> seqFibers_1,
List<Link> seqFibers_2,
DoubleMatrix2D wavelengthFiberOccupancy)
Wavelength assignment algorithm based on a first-fit fashion.
|
static Pair<int[],int[]> |
WDMUtils.WA_firstFitTwoRoutes(List<Link> seqFibers_1,
List<Link> seqFibers_2,
DoubleMatrix2D wavelengthFiberOccupancy)
Wavelength assignment algorithm based on a first-fit fashion.
|
static Pair<int[],int[]> |
WDMUtils.WA_RPP_firstFit(List<Link> seqFibers,
DoubleMatrix2D wavelengthFiberOccupancy,
DoubleMatrix1D l_f,
DoubleMatrix1D nodeRegeneratorOccupancy,
double maxRegeneratorDistanceInKm)
Wavelength assignment algorithm based on a first-fit fashion assuming
full wavelength conversion and regeneration.
|
Constructor and Description |
---|
GraphTheoryMetrics(List<Node> nodes,
List<Link> links,
Map<Link,Double> linkCostMap)
Default constructor
|
GraphTheoryMetrics(List<Node> nodes,
List<Link> links,
Map<Link,Double> linkCostMap)
Default constructor
|
LightpathAdd(Demand demand,
List<Link> seqLinks,
int[] seqWavelengths,
double lineRateGbps)
Constructor to generate a new
LightpathAdd object. |
LightpathAdd(Demand demand,
List<Link> seqLinks_primary,
List<Link> seqLinks_backup,
int[] seqWavelengths_primary,
int[] seqWavelengths_backup,
double lineRateGbps)
Constructor to generate a new
LightpathAdd object. |
LightpathAdd(Demand demand,
List<Link> seqLinks_primary,
List<Link> seqLinks_backup,
int[] seqWavelengths_primary,
int[] seqWavelengths_backup,
double lineRateGbps)
Constructor to generate a new
LightpathAdd object. |
LightpathAdd(Node ingressNode,
Node egressNode,
NetworkLayer layer,
List<Link> seqLinks,
int[] seqWavelengths,
double lineRateGbps)
Constructor to generate a new
LightpathAdd object. |
LightpathAdd(Node ingressNode,
Node egressNode,
NetworkLayer layer,
List<Link> seqLinks_primary,
List<Link> seqLinks_backup,
int[] seqWavelengths_primary,
int[] seqWavelengths_backup,
double lineRateGbps)
Constructor to generate a new
LightpathAdd object. |
LightpathAdd(Node ingressNode,
Node egressNode,
NetworkLayer layer,
List<Link> seqLinks_primary,
List<Link> seqLinks_backup,
int[] seqWavelengths_primary,
int[] seqWavelengths_backup,
double lineRateGbps)
Constructor to generate a new
LightpathAdd object. |
LightpathModify(Route lp,
List<Link> seqLinks,
double carriedTraffic,
double occupiedLinkCapacity,
int[] seqWavelengths)
Constructor to generate a new
LightpathModify object. |