input: : Vertices
input: : Edges
input: : density of cluster
begin
 initialize empty list of clusters C;
 count 0;
 cluster construct_dsubg( , , );
while cluster     count < max_count do
  size ;
  if size min_size then
    add cluster to C;
    count 0;
  else
    count count + 1;
  end
  set to without nodes of cluster;
  set to without edges within cluster;
  cluster construct_dsubg( , V, E);
end
end
Algorithm 1: createClusters.