![]() |
Matlab,找到不参与边的节点?
在下面的Matlab代码中,节点为N=10 ,您将获得随机选择的节点,概率为P= .25标记为红色节点。
nodeN = []; nodeM = []; N=input('No. of Nodes:'); P=input('probability of cluster head : '); R=input('range of cluster head: ') data = rand(N,2) % Randomly generated n no. of nodes x = data(:,1); y = data(:,2); plot(x,y,'b*') hold on index = (rand(N,1) |
所有时间均为北京时间。现在的时间是 01:07。 |
Powered by vBulletin
版权所有 ©2000 - 2025,Jelsoft Enterprises Ltd.