/* * "...At each time-step, we chose NpR0 pairs of vertices uniformly * at random from the network to meet. If a pair meet who do not have * a pre-existing connection, and if neither of them already has the * maximum z* connections then a new connection is established * between them...." */ private void randomMeeting() { int nPairs = (numNodes * (numNodes - 1)) / 2; int numPicks = (int) Math.round(nPairs * Rsub0); for (int n = 0; n < numPicks; n++) { int index = Random.uniform.nextIntFromTo(0, numNodes - 1); JinGirNewNode iNode = (JinGirNewNode) agentList.get(index); iNode.meetRandom(agentList, maxDegree); } }