Perform the modified Dijkstra's algorithm on a network topology between two nodes in respect with given links weights.
[P1,P2,P3,P4,P5] = NARVAL_M_DijkstraMP(n,h,t,we,nd,nf,w)
network size.
links head vector.
links tail vector.
links weight vector.
source node.
destination node.
weight.
first path.
second path.
third path.
fourth path.
fifth path.
NARVAL_M_DijkstraMP performs the modified Dijkstra's algorithm in order to find multiple paths between the source node nd and the destination node nf on the network topology defined by n, h, t and we (WIKIPEDIA). The weight of links is assumed to be stored inside the vector we. The generation of new paths is made according to iterative applications of the Dijkstra's algorithm on a changing topology where weights of links belonging to the current shortest path are changed to larger values (wlink=wlink+w).
n=80;//network size L=1000;//network square area side dmax=100;//locality radius [g]=NARVAL_T_LocalityConnex(n,L,dmax);//generation of a random topology in respect with the Locality method. [ni,nj]=NARVAL_F_Random_i_j(length(g.node_x));//selection of connection nodes ind=1;//window index f=NARVAL_G_ShowNodesIndex(g,ind);//graph visualization [P1,P2,P3,P4,P5]=NARVAL_M_DijkstraMP(length(g.node_x),g.head,g.tail,g.edge_length,ni,nj,L);//application of NARVAL_M_DijkstraMP P1 P2 P3 P4 P5 | ![]() | ![]() |
Dr. Foued Melakessou
Research Associate
Interdisciplinary Centre for Security, Reliability and Trust
Room F106
University of Luxembourg
6, rue Coudenhove Kalergi
L-1359 Luxembourg-Kirchberg
E-mail: foued.melakessou@uni.lu
Tel: (+352) 46 66 44 5346