 
              Network Planning VITMM215 Markosz Maliosz 10/14/2015
Shortest Path – Link Weights  What should be the link weights? – physical distance? – delay on a link? – hop count (w=1)? – some arbitrary number?  Cisco’s default: – inversely proportional to its capacity – higher capacity links are “shorter” – drives traffic to higher capacity links – can lead to strange routing 2
Link weight setting example  Traffic: – q  t : 1 – 3  t : 1 – s  t : 1 – w  t : 1 3
Link Weights  The correct choice depends on objectives  Common goal: minimize delays – if propagation delay is dominant  minimize physical path distance  weight = link distance – if processing delay is dominant  minimize hop count, weight = 1 – if queuing delay is dominant  measure delays along links  calculate shortest path according to measured delay values 4
Tree Networks  Connects all nodes with minimum number of links  There is one and only one path between any node pairs  Example applications: – cable TV network: broadcast from one source to many – Ethernet Spanning Tree Protocol 5
Spanning Tree  Def.: subgraph, which is a tree and contains all nodes 6
Minimum spanning tree  link cost  edge weights  The minimum spanning tree is the minimum cost spanning tree among all spanning trees  If each link has a distinct weight, there will be a unique MST, otherwise the MST is not unique 7
Kruskal’s Algorithm  Greedy algorithm to find minimum spanning tree – create a forest F (a set of trees), where each node in the graph is a separate tree – At each step, take the minimum-weight edge  if it connects two different trees, then add to the forest  combine the two trees into a single tree  otherwise discard that edge – If there is only one tree, the problem is solved Animation: http://students.ceid.upatras.gr/~papagel/project /kruskal.htm 8
Prim’s Algorithm  Greedy algorithm to find minimum spanning tree – select an arbitrary node as initial element of the set – in each iteration, choose a minimum-weight edge ( u , v ), connecting a node v in the set to the node u outside of the set, then node u is brought into the set – this process is repeated until all the set will contain all nodes  When the algorithm terminates, the edges in the set form a minimum spanning tree Animation: http://students.ceid.upatras.gr/~papagel/project/p rim.htm 9
Calculating Spanning Tree 2 4 E C A 2 6 9 5 10 4 6 B D F Find the min-cost spanning tree in the graph! 10
Ethernet STP  An Ethernet network can have multiple possible paths for reliability  STP is intended to create a tree to avoid loops – broadcast storm  802.1D algorithm based on Dijkstra’s alg. – switches are assigned numerical priorities – switch with lowest priority becomes root switch  tie break is lowest MAC address (are unique) – each switch port is given a cost = link weight  based on bandwidth of the link 11
STP Port Costs  Default costs – old version based on 1 Gbps/(link bandwidth) – new version: arbitrary table  port cost: integer, >0 Link speed Old cost New cost 10 Mbps 100 100 100 Mbps 10 19 1 Gbps 1 4 10 Gbps 1 2 12
STP  Bridge Protocol Data Units are sent regularly – priority, cost information and state – flooded through network  Protocol finds min-cost path to root switch with Dijkstra’s algorithm in a distributed way – ports not on shortest path towards root bridge are blocked 13
STP  Optimization in STP – minimizes path length for each leafs to get to the root – link weights can be arbitrary! – with default weights: pushes traffic to higher bandwidth paths 14
Linear Programming 15
Linear Programming  Linear Programming is the optimization of an objective based on some set of constraints using a linear mathematical model  The word “programming” is used in the sense of “planning”  A Linear Program (LP) is a problem that can be expressed as – a linear objective function, – subject to linear equality and linear inequality constraints  Has many applications – transportation, telecommunications, manufacturing, business  e.g. maximizing profit in a factory that manufactures a number of different products from the same raw material using the same resources – engineering: planning, routing, scheduling, assignment, design  minimizing resources in network planning to satisfy user demands  maximizing performance of the network with a limited cost budget 16
Linear Program  Standard form: find the values of x j variables, that minimize (or maximize) the objective function z  subject to (satisfying the following constraints):  Notation: – objective function: z – variables to be determined, decision variables: x j – number of variables: n – coefficients: c j , a ij, b i – number of constraints: m – bounds for variables 17
Linear Program  Standard matrix form:   x  T max z c x 1     x      c: cost coefficients  T  c c c     x 1 n n – subject to:         a a b   11 1 n 1          A x b     A b                 a a   b m 1 mn m 18
LP Example  A company manufacturing two products: P1, P2  3 manufacturing units are required to manufacture both products: U1, U2, U3  During a week the maximum operating hours for the machines: – U1: 50 hours – U2: 35 hours – U3: 80 hours  To manufacture a product it has to be processed on all of the 3 manufacturing units with the following manufacture times in hours (the sequence does not matter): – U1 U2 U3 – P1 10 5 5 – P2 5 5 15  Price of P1: 100$  Price of P2: 80$  How many pieces should from P1 an P2 to be manufactured to achieve maximum income? 19
LP Example  The task is an optimization problem: find the maximum income  Variables to be determined: amount of P1 and P2 to be manufactured, denoted as: x1 and x2  Objective function – maximize income = max (100 x1 + 80 x2)  The limited working hours of the manufacturing units (U1, U2, U3) restrict the amount of products that can be produced during a week  constraints U1 U2 U3 Constraints: 10 x1 + 5 x2 ≤ 50 P1 10 5 5 5 x1 + 5 x2 ≤ 35 P2 5 5 15 5 x1 + 15 x2 ≤ 80 MWH 50 35 80 x1 ≥ 0 x2 ≥ 0 MWH= max. working hours 20
Finding the Solution  Feasible solutions – x vectors, which satisfy the constraints and bounds  Optimal solution – x is feasible and c T x is minimal (maximal)  Problem can be – infeasible – unbounded 21
Geometrical solution x 2 2D representation: Constraints: set of straight lines 10 F(x) = 100 x 1 + 80 x 2 = 800 (const) F(x) = 800 (a) 10x 1 + 5x 2  50 5 (b) 5x 1 + 5x 2  35 4 P 2 (c) 5x 1 + 15x 2  80 Sol: X 1 = 3 X 2 = 4 Extreme x 1 P 1 point P 0 c 3 5 10 15 a b 22
Geometrical Representation  Ax  b  Optimum: 23
Solving LP  Good general-purpose techniques exist for finding optimal solutions – All polynomial-size linear programs can be solved in polynomial time – Algorithms  Simplex  Barrier or Interior Point Method – Software  CPLEX  GNU Linear Programming Kit (GLPK)  lp_solve  etc. 24
Integer Linear Programming  Pure Integer Problem (IP or ILP) – Restriction: elements of vector x must be integers  searching the best integer solution  Mixed Integer LP (MIP or MILP) – Restriction: some elements of vector x must be integers  Binary or zero-one ILP – Restriction: elements of vector x must be 0 or 1 – many kinds of combinatorial and logical restrictions can be modeled through the use of zero-one variable  Much harder problems: NP-hard in general – solution time is much longer 25
Integer Linear Programming  Many real problems contain integer quantities, e.g.: – Set Covering Problem – Travelling Salesman Problem (TSP) – Knapsack problem  Solving ILP – Relaxation: variables are not constrained to be integers  if the continuous problem (LP) always has an integral optimal value (assuming c is integral), then this optimal value is the solution for the ILP too, and it can be found efficiently (as in the previous example for manufacturing)  if the solution is not integral, then finding the optimum is more difficult 26
ILP Relaxation – 2D Illustration 27
ILP Relaxation – 2D Illustration  Optimal value of LP is far from integral feasible solution: 28
Solving ILP  Branch and bound – Branch:  decomposition into subproblems based on possible variable settings recursively: forming nodes of a tree – Bound:  infeasible subproblems pruned  compute upper and lower bounds – by minimizaton: if the lower bound for some subproblem is greater than the upper bound for some other subproblem, then the former may be safely discarded from the search  Branch and cut – Eliminate non-integer solutions by adding cut constraints to LP 29
Minimum cost ring topology planning 30
Recommend
More recommend