Skip to main content
. Author manuscript; available in PMC: 2014 Jan 29.
Published in final edited form as: IEEE Trans Dependable Secure Comput. 2012 Jan 17;9(3):332–344. doi: 10.1109/TDSC.2012.11

Algorithm 1.

Minimization of the network community profile

Input: DIS, a distance matrix
Output: k, the number of nearest neighbors
1: k ← |U| {Initialize to all possible neighbors}
2: for i = 1 to |U| do
3: N = { }
4: for j = 1 to |U| do
5:   NNinnj
  {the i-nearest neighbor network for user uj}
6: end for
7: for j = 1 to |U| do
8:   if ψ(gj, N, i) < k then
9:    ki {the conductance function}
10:   end if
11: end for
12: end for