資源簡介
介數中心性 matlab介數中心性 matlab介數中心性 matlab
代碼片段和文件信息
function?BC=betweenness_bin(G)
%BC=betweenness_bin(G);?betweenness?centrality?BC?for?a?binary?directed?graph?G
%
%Betweenness?may?be?normalised?to?[01]?via?BC/[(N-1)(N-2)]
%
%Algorithm?of?Kintali?generalised?to?directed?and?disconnected?graphs
%http://www.cc.gatech.edu/~kintali/papers/bc.pdf
%
%Mika?Rubinov?UNSW?2007?(last?modified?July?2008)
n=length(G);????????????????%number?of?nodes
I=eye(n)~=0;????????????????%logical?identity?matrix
d=1;????????????????????? %path?length
NPd=G;??????????????????????%number?of?paths?of?length?|d|
NSPd=NPd;?????????????????? %number?of?shortest?paths?of?length?|d|
NSP=NSPd;?NSP(I)=1;???????? %number?of?shortest?p
- 上一篇:matlab下編寫的勞斯判據
- 下一篇:kalman濾波的語音降噪matlab程序
評論
共有 條評論