The gravity centrality (also known as the gravity \(k\)-shell metric) is inspired by Newton’s law of gravitation. In this measure, the \(k\)-shell value of a node is regarded as its mass, while the shortest path length between two nodes represents their distance [2].
Let \(\mathcal{N}^{(\leq l)}(i)\) denote the set of nodes within the \(l\)-hop neighborhood of node \(i\). The gravity centrality \(c_{\text{Gravity}}(i)\) of node \(i\) is defined as
\begin{equation*}
c_{\text{Gravity}}(i) = \sum_{j \in \mathcal{N}^{(\leq l)}(i)} \frac{k_s(i)\,k_s(j)}{d_{ij}^2},
\end{equation*}
where \(d_{ij}\) is the shortest path distance between nodes \(i\) and \(j\) and \(k_s(i)\) denotes the \(k\)-shell value of node \(i\). To reduce computational complexity, Ma et al. [2] set \(l = 3\), meaning that only the nearest neighbors, next-nearest neighbors, and third-order neighbors of node \(i\) are considered.

References

[1] Shvydun, S. (2025). Zoo of Centralities: Encyclopedia of Node Metrics in Complex Networks. arXiv: 2511.05122 https://doi.org/10.48550/arXiv.2511.05122
[2] Ma, L. L., Ma, C., Zhang, H. F. & Wang, B. H. Identifying influential spreaders in complex networks based on gravity formula. Physica A 451, 205-212 (2015). doi: 10.1016/j.physa.2015.12.162.