How to calculate delta Q (modularity increase matrix) in graphs?


I’ve been trying to implement the Three-stage Algorithm to compare its results with our new proposed algorithm with different datasets than those mentioned in the article. I’ve succeeded in implementing the first two stages.

The third stage, however, is what I couldn’t understand. To be precise, I couldn’t understand how the ΔQ matrix is computed. There was no mention of its equation in the article:

A screenshot from the article:

enter image description here

I’ve contacted one of the co-authors of this paper it’s been almost two weeks but they didn’t reply.

Is the third stage the same as the Louvain method?
I’ve found different equations on the internet but they all belonged to the Louvain method.