Simplifying expression for delta modularity (Louvain algorithm). For details, see here: https://www.youtube.com/watch?v=0zuiLBOIcsw The Louvain method for community detection is a method to extract communities from large networks created by Blondel et al.[1] from the University of Louvain (the source of this method's name). The method is a greedy optimization method that appears to run in time {\displaystyle O(n\cdot \log n)}O(n\cdot \log n) if {\displaystyle n}n is the number of nodes in the network.[2]