Connect new neighbor nodes around a central node.
[ge] = NARVAL_G_CirclePlace(n,d,g,i)
quantity of neighbor nodes.
maximal radius from the central node.
initial network graph.
central node index.
output graph.
NARVAL_G_CirclePlace connects n nodes around the central node of index i within the original graph g. They are randomly placed inside a disc of radius d centered around the node i. The distance between any new nodes and the central node belongs to the range [d/2,d].
In the previous picture, 4 new nodes have been attached to the node N16.
n=150;//original 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 gn=length(g.node_x);//real network size i=NARVAL_F_Random(gn);//selection of the central node N=10;//quantity of new nodes d=100;//disc radius [ge]=NARVAL_G_CirclePlace(N,d,g,i);//application of NARVAL_G_CirclePlace ge.edge_color=[ones(1,length(g.head)) 5*ones(1,N)];//display the output graph ge.edge_width=[2*ones(1,length(g.head)) 5*ones(1,N)]; ge.node_color=[ones(1,length(g.node_x)) 5*ones(1,N)]; ge.node_color(i)=2; ge.node_border=[2*ones(1,length(g.node_x)) 5*ones(1,N)]; ge.node_border(i)=10; ind=1;//window index f=NARVAL_G_ShowGraph(ge,ind);//graph visualization | ![]() | ![]() |
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