<< NARVAL_R_TreeN2N NARVAL NARVAL_S_ExtGcd >>

NARVAL >> NARVAL > NARVAL_R_TreeN2R

NARVAL_R_TreeN2R

Perform the path between a node and the root of a tree.

Calling Sequence

[p] = NARVAL_R_TreeN2R(n,r,pred)

Parameters

n :

node.

r :

root.

pred :

predecessor vector.

p :

path.

Description

NARVAL_R_TreeN2R performs the path p between the node n and the root r of the tree defined by its predecessor vector pred.

Examples

n=150;//network size
L=1000;//network square area side
dmax=100;//Locality radius
[g]=NARVAL_T_LocalityConnex(n,L,dmax);//generation of a topology in respect with the Locality method
[r,nind]=NARVAL_F_AleaVec(1:length(g.node_x));//selection of the root node
dw=5;//display parameter
ind=1;//window index
[ni,nind]=NARVAL_F_AleaVec(nind);//selection of source
[go,v,pred]=NARVAL_R_BFS(g,r,dw,ind);//performance of the tree
[path]=NARVAL_R_TreeN2R(ni,r,pred);//application of NARVAL_R_TreeN2R
r
ni
path

Authors

Foued Melakessou

Contact

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

Home Page


<< NARVAL_R_TreeN2N NARVAL NARVAL_S_ExtGcd >>