fully connected graph formula