Update a route manager in respect with an event on a pursued path.
[R] = NL_I_RouteManagerUpdate(R,Cl,Ca,E,K,I,J,N,M)
Route manager.
Modification factor of the route manager after a packet loss.
Modification factor of the route manager after a packet acknowledgement.
Event: loss or ack.
Route index.
Source node.
Destination node.
Network size.
Mode: 0:/* or 1:+-.
NL_I_RouteManagerUpdate modifies the route manager R in respect with events as packet loss (E=0) or acknowledgement (E=1) on the pursued path K between the nodes I and J of the network with size N. M is the change mode (0 for multiplicatif and 1 for additif).
[path]=NL_F_NLPath();//path to NARVAL module path=path+'/demos/';//folder path load(path+'RoutingTables_topo_100.dat','pt','rt1','rt2','rt3','rt4','rt5');//loading of the network routing tables load(path+'topo_100.graph','g');//loading of the network graph n=100;//network size bs=15;//constant buffer size [nd,nf]=NL_F_RandIntNiNj(n);//generation of connection extreme nodes L=1000;//network square area side t=1;//current time closs=0.9; cack=0.1; [probroute]=NL_I_RouteManagerInit(rt1,rt2,rt3,rt4,rt5,pt,n,L);//initialization of the route manager e=1;//packet acknowledgement ri=1;//on the first route m=0;//multiplicatif mode k=(nd-1)*n+nf;//line index of the connection location inside the route manager probroute(k,:)//initial state of the path selection between nd and nf [probroute]=NL_I_RouteManagerUpdate(probroute,closs,cack,e,ri,nd,nf,n,m);//application of NL_I_RouteManagerUpdate probroute(k,:)//new state after an acknowledgement on the path ri | ![]() | ![]() |