How can i add code for a service called "Area Multicast send" in my program along with mentioned parameters

1 view (last 30 days)
Multicasting: a set of data sent by one computer across a computer network to many users at the same time.
in this below program how can i add code for " AreaMulticastSend (position, radius, deadline, packet)"
Area multicast send is a service that identifies a destination area by its center position and radius. It guarantees that every node inside that area will receive a copy of the sent packet within the specified end-to-end deadline. so how can i do this , the output (figure) is also given below plz help me in adding this service to my below program. there are total 10 nodes(sensors) shown in figure so how can i multicast a packet from one node to others, (in short how can i implement speed real time protocol in matlab).
Note: if some cann't implement this service along with its parameters so just do it without parameters, means a bit of work/improvement in it would also be appreciated.
plz be confident to contact me for further questions about this program. thanks
clear All
Close All
clc
rand('state',0);
xx=rand(1,10)*10;
yy=rand(1,10)*10;
R=6;
nodearray=[xx;yy]';
for i=1:10
hold on
% x=nodearray(n,1);
%y=nodearray(n,2);
plot(xx,yy,'O');
text(xx(i),yy(i),num2str(i));
hold on
title('Speed');
for j=1:10
d=sqrt((xx(i)-xx(j))^2+(yy(i)-yy(j))^2); //finding euclidean distance
if d<=R //checking the node if it comes in the range or not.(finding neighbors in range)
line([xx(i) xx(j)],[yy(i) yy(j)])
end
end
axis([0 10 0 10])
end

Answers (0)

Categories

Find more on WLAN Toolbox in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!