Introduction

Pain is a complex, multidimensional, and subjective experience. Neuroimaging and neurophysiological studies have shown that noxious stimuli activate an extensive network of cortical brain areas, which has been termed the pain matrix1,2,3,4. Historically, this functional pain network has been divided into sensory-discriminative and cognitive-affective systems5,6,7. The sensory-discriminative system, which includes the lateral thalamus and primary and secondary somatosensory cortices (SI and SII, respectively), is thought to process information related to nociceptive inputs, including intensity, localization, and quality8,9. The cognitive-affective system, which comprises brain regions such as the anterior insula (AI) and anterior cingulate cortex (ACC), is believed to mediate psychological aspects of pain4,10,11,12. The concept of the pain matrix implies that there is no single “pain center” in the brain, and that the activity pattern of this functional network could serve as a reliable and objective indicator of painful experience, including in pathophysiological pain states in which pain may occur in the absence of any nociceptive stimulus13,14,15. However, recent studies suggest that the pain matrix activation is a response to salient sensory stimuli rather than perceptual qualities unique to pain16,17,18. Therefore, it’s crucial to include additional brain areas, especially subcortical brain regions within ascending and descending pain pathways that participate in nociceptive information transmission, processing, and modulation, to study pain at the network level.

Graph theory, a branch of mathematics concerning the formal description and analysis of graphs, provides a powerful method to characterize network structure and function19. Using graph-theoretical tools, pain networks can be modeled as a set of functional or structural interactions. In these models, nodes, denoting brain areas, are linked by edges, representing structural or functional connections between them. In previous studies, researchers in the pain field have built functional pain networks using data from noninvasive neuroimaging and neurophysiology techniques, detecting altered resting network topology in patients with chronic pain disorders20,21,22,23. However, functional pain networks lack reciprocal connection information between different brain regions24,25, and are typically unable to include deep brain structures due to technical limitations. Thus, the structural topological properties of pain networks and how these properties support multidimensional pain remain elusive. To overcome these limitations, we sought to construct a structural pain network that comprises both superficial and deep brain areas involved in pain perception and use anatomical reciprocal axon connections as edges preserving the direction information.

We utilized the Allen Mouse Brain Connectivity Atlas, a comprehensive open-access online database containing high-resolution images of traced axonal projections from defined mouse brain regions and cell types26,27, to generate a directed and weighted pain network. In this network, we included all brain areas that, according to our literature search, may play a role in pain. Graph theory analysis of this structural pain network revealed that: (1) 63% of brain areas in the pain network share reciprocal connections; (2) clustering analysis indicated that brain areas in the pain network tend to cluster together; (3) community detection successfully identified and separated the two known systems for the sensory and affective components of pain, respectively; (4) the assortativity coefficient reflects an assortative pain network; and (5) robustness evaluation showed that the pain network displays a high degree of error tolerance but is vulnerable to attacks.

Results

Brain areas included in the structural pain network

Precisely which regions constitute the pain matrix has yet to be conclusively and consistently defined4. Thus, to create a comprehensive brain network for pain, we conducted a literature search in an effort to include all brain areas that have been reported to participate in pain perception (Table S1). In addition, considering that the pontine nuclei (PG) and inferior olivary nuclei (IO) mediate communication between the cerebral cortex and cerebellum, which critically contribute to pain processing28, we included both the PN and IO in this network. In total, this pain network comprises 49 major brain subdivisions based on the Allen Reference Ontology29. Among them, 18 brain structures are located in the cerebrum (CH), 21 in the brain stem (BS), and 10 in the cerebellum (CB).

Noxious stimulation activates all brain areas in the network

To confirm that brain areas in this structural pain network participate in pain perception, we used mutant TRAP2 (FosCreERT2);Ai14 mice to genetically label neurons that are active during noxious pinpricks with tdTomato (Fig. 1a). Neurons expressing tdTomato were widely distributed throughout the brain (Fig. 1b). Although the number of TRAPed neurons in each brain area varied, we detected tdTomato-positive neurons in every brain area in this structural pain network (Fig. 1c). Among the CH group, the retrosplenial cortex (RSP), somatosensory cortex (SS), motor cortex (MO), and anterior cingulate cortex (ACC) displayed extensive tdTomato labeling (Fig. 1c,d), consistent with their critical roles in pain perception. From the BS group, the paraventricular nucleus of the thalamus (PVT), nucleus raphe pontis (RPO), periaqueductal gray (PAG) and parabrachial nucleus (PB), all of which are intensively investigated in the pain field, showed the highest density of tdTomato-positive neurons (Fig. 1c,d). Besides, we also observed a wide distribution of tdTomato-positive neurons in the cerebellar cortex and nuclei (Fig. 1c,d), in line with accumulating evidence suggesting that the cerebellum participates in pain processing30.

Figure 1
figure 1

Noxious pinprick stimulation activates neurons in diverse brain areas. (a) Experimental timeline to label neurons active during noxious pinprick stimulation. (b) Overview of tdTomato-expressing neurons in various brain areas. The size of each circle (red) was scaled based on the density of labeled neurons. (c) Representative photomicrographs of tdTomato-expressing neurons in several brain areas. Scale bars, 200 µm. (d) Quantification of tdTomato-expressing neurons across brain areas in the pain network (one-way ANOVA with Holm-Sidak post hoc tests; data from 3 mice in control and 3 mice in pinprick groups). Bars represent mean ± SEM; *P < 0.05, **P < 0.01, and ***P < 0.001.

Ipsilaterally dominated and distance-dependent connectivity

To build a structural pain network, we queried the normalized projection volumes, defined as the total volume of segmented pixels (EGFP signal) in the target normalized by the injection site volume, of each brain area to other regions of the pain network from the Allen Mouse Brain Connectivity Atlas using the API (http://help.brain-map.org/display/mouseconnectivity/API). We restricted our analysis to wildtype mice and only included data from mutant mice when data from wildtype mice was not available for 6 brain structures (for details, please see the Materials and Methods). Connectivity strengths between brain areas in this pain network span a greater than 105-fold range (Fig. 2), suggesting that the quantitative physical connections between brain areas in the pain network must be considered in order to understand, interpret and discriminate its activity patterns during pain perception26,31. In addition, the connectivity matrix shows prevalent bilateral projections between brain areas in the network, with generally stronger ipsilateral projections than contralateral (total normalized projection volumes are 3.5:1 between the ipsilateral and contralateral hemispheres). Of all possible connections above the minimal true positive level of 10–426, 59% project ipsilaterally, while 41% project contralaterally.

Figure 2
figure 2

Connectivity matrix of brain areas in the pain network. Each row shows the quantitative projection signals from one of the 49 brain areas to other brain areas (in columns) in the right (ipsilateral) and left (contralateral) hemispheres. Brain areas are displayed in ontological order. Color maps indicate log10-transformed projection strength. All values less than 10–3.5 are shown in blue to minimize false positives. All values greater than 10–0.5 are shown in red to reduce the dominance of projection signals in certain large regions26.

Brain areas in the CH and BS groups are extensively inter- and intraconnected, whereas CB brain areas show sparse intraconnection (Fig. 3a). The limited connection between cerebellar subareas is consistent with the lobular anatomical organization of the cerebellum32,33. In addition, the lack of direct connections between the CB and brain areas in the CH and BS groups reflects the indirect nature of cortico-cerebellar and cerebello-cortical connectivity34,35. Furthermore, connection strengths between brain areas in the pain network display a hemisphere-correlated distance dependence (Fig. 3b,c). In the ipsilateral hemisphere, connection strength between two brain areas decreases as the distance between them increases. However, in the contralateral hemisphere, we found no clear correlation (Fig. 3b,c). These findings mirror the anatomy of the somatosensory pathways, in which each side of the body is represented contralaterally in the brain.

Figure 3
figure 3

Distance-dependent connections between brain areas in the pain network. (a) Distance matrix of all brain areas (ipsilateral) in the pain network. Color map indicates the normalized distance between brain areas based on injection coordinates. Black circle indicates a projection strength larger than 0.01. Brain areas are displayed in ontological order and divided into anatomical groups: CH, BS, or CB. (b) Scatter plot of the projection strength from the dorsal part of the anterior cingulate area (ACAd) to other brain areas in the pain network as a function of the distance between them. Data points were fit by linear regression (red line). (c) Violin plot of the correlation coefficient between projection strength and distance of each brain area to other brain areas (ipsilateral and contralateral) in the pain network.

Homogenous connection pattern between brain areas in the network

Nodes with similar connection patterns in a network tend to exhibit similar functionality36. Thus, we analyzed the similarity in connection patterns of different brain areas in the pain network. We compared the similarity of outgoing projections originating from two brain areas (source correlation) and the similarity of incoming projections terminating in these two areas (target correlations). Heatmaps of both source (Fig. 4, left) and target correlations (Fig. 4, right) indicated two clusters: one belonging to the CH and BS groups, and the other belonging to the CB group (Fig. 3a). Among these two clusters, a large number of brain areas in the pain network showed both strong incoming and outgoing projection correlations (Fig. 3a), indicating a homogenous connection pattern between brain areas in the network.

Figure 4
figure 4

Correlation coefficients of projection strengths between areas. Comparison of the correlation coefficients of projection strengths between brain areas in the pain network, defined as the common source for projection to other regions (left) and as the common target of projection from other regions (right). Color maps indicate the correlation coefficient value. Brain areas are displayed in ontological order and divided into three anatomical groups: CH, BS or CB.

Overview of the pain network architecture

To investigate the topological properties of this structural pain network, we generated a directed and weighted network according to the axonal connections between brain areas (Fig. 5a). The pain network contains 49 nodes and 632 edges, yielding a network density (indicative of how efficiently a network transmits information) of 27%. The pain network has a diameter (the shortest distance between the two most distant nodes) of 7 nodes. Network diameter determines how quickly information could spread through a network37. In addition, 63% of nodes in the pain network share reciprocal connections, compared to 26% in a generated random network with the same density (Table 2). These results indicate that brain areas in the pain network are densely interconnected.

Figure 5
figure 5

Topological properties of the pain network. (a) Graphical layout of the pain network. The position of each vertex corresponds to its injection site coordinates scaled to a two-dimensional plane. Node size is scaled according to the degree centrality of each node. Color indicates the group to which a vertex belongs to. (b) Community detection of the pain network using random walks. (c) Vertex degree distribution of the pain network, compared against the corresponding Erdős-Rényi random graph model, the Watts-Strogatz small-world model and the Barabási-Albert model. (d) Similar to (b), comparison of the vertex clustering coefficient of each network model. (e) Lorenz concentration curve showing the degree distribution among the four network models.

Hub nodes in the pain network

Hub nodes, which connect with many other nodes of a network, typically contribute more to network function than relatively isolated nodes19. To identify the hub nodes of this pain network, we conducted centrality analysis using three different methods (Table 1 and Table S2). Degree centrality, which assesses the number of edges belonging to each node, revealed that the caudoputamen (CP), secondary motor cortex (MOs) and mediodorsal nucleus of thalamus (MD) share the highest number of direct connections with other nodes of the pain network. Closeness centrality measures the average shortest distance from each node to each other node, while betweenness centrality determines the likelihood that a node sits between other nodes in networks. Notably, the parabrachial nuclei (PB) display both the highest closeness centrality and betweenness centrality in the pain network, supporting the notion that PB is a hub for pain38.

Table 1 Top three vertices in different centrality analysis.

Communities for sensory and affective pain

To test whether graph theory analysis could detect the known subsystems for the sensory-discriminative and affective-motivational components of pain, we conducted community detection using the Walktrap algorithm39. In total, this algorithm detected 13 communities in the pain network (Fig. 5b and Table S3). Remarkably, based only on the projection data, this algorithm clearly separated the respective networks critical for the sensory and affective components of pain5,6,7. In addition to the somatosensory cortex and lateral thalamic nuclei, which play a crucial role in sensory pain processing40,41,42,43, the Walktrap algorithm included the primary motor cortex (M1), but not the secondary motor cortex (M2), in this community. For the community mediating the affective dimension of pain, other than the well-established ACC, agranular insular area (AI), mediodorsal nucleus of the thalamus (MD) and BLA11,44,45,46,47, the algorithm further identified the periaqueductal gray (PAG), retrosplenial area (RSP), zona incerta (ZI) and red nucleus (RN) as belonging to this community.

Pain network appears assortative

To further understand the global structure of this pain network, we compared its topological properties with three mathematical models of networks with the same density: the Erdős-Rényi random graph model37, the Watts-Strogatz small-world model48 and the Barabási-Albert model49 (scale-free model; Fig. 5c–e and Table 2). Graph theory analysis revealed that the pain network has the highest mean clustering coefficient (0.65) among these four networks (Table 2). The node degree distribution of a small-world network model resembles that of the pain network (Fig. 5b); however, its clustering coefficient distribution aligns poorly (Fig. 5c). The degree distribution of the pain network is right-skewed compared to the random graph model and small-world model (Fig. 5b,e), indicating that a substantial portion of the edges are concentrated on a small number of highly connected nodes. The scale-free model also shows a right-skewed degree distribution but does not closely fit the pain network.

Table 2 Topological properties comparison between networks.

To test whether the pain network is assortative or disassortative, we conducted assortativity analysis. Biological networks tend to be disassortative50,51. In these networks, a strong effective repulsion between highly connected nodes increases the specificity of functional modules and stability against random network error52,53. However, the pain network displays a positive assortativity coefficient (Table 2), indicating that, unlike most biological networks, the pain network is assortative.

Error and attack tolerance of the pain network

Many complex systems, including the World Wide Web, the Internet, social networks and the cells, display a high-degree of error tolerance at the expense of attack vulnerability54. To assess how the pain network would respond to random failure and attack, we removed a fraction (\(f)\) of either nodes randomly or hub nodes from the pain network54. The removal of any node generally increases the distance between the remaining nodes, as it can eliminate some paths that contribute to the interconnectedness of the system54. By examining the mean distance (the average length of the shortest path between any two nodes) of remaining nodes, we found that the pain network displays a high degree of error tolerance: the ability of their nodes to communicate is barely affected (Fig. 6a), even at a high failure rate (removing 20% nodes in the pain network randomly). However, removing hub nodes from the pain network substantially increases the mean distance, indicating that the pain network is vulnerable to attacks (Fig. 6a).

Figure 6
figure 6

Pain network displays tolerance against both random failure and attack. (a) Change in the mean distance of the pain network as a function of the fraction \(f\) of the removed random nodes (Random, cyan) or hub nodes (Attack, red). (b) The relative size of the largest cluster \(S\) as a function of the fraction \(f\) of the removed random nodes (Random, cyan) or hub nodes (Attack, red) for the pain network (circle) and a scale-free network with the same density (triangle). (c) The average size of the isolated clusters as a function of the fraction \(f\) of the removed random nodes (Random, cyan) or hub nodes (Attack, red) for the pain network (circle) and a scale-free network with the same density (triangle).

Removing nodes from a network can induce network fragmentation because clusters of nodes whose links to the system may be cut off54. To assess the impact of random failures and attacks on network fragmentation of the pain network, we measured the size of the largest cluster, \(S\), shown as a fraction of the total system size, when a fraction, \(f\), of the nodes is removed either randomly or in an attack. We found that, when removing nodes randomly, as \(f\) increases, \(S\) remains stable. In contrast, \(S\) decreases dramatically during attacks, behaving similarly to a disassortative scale-free network with the same number of nodes and edges (Fig. 6b). Nevertheless, the pain network behaves differently than a scale-free network when assessing the average size of isolated clusters (all clusters except the largest one), < s > . We found that < s > remains stable for the pain network during random failure while it increases during attacks (Fig. 6c), suggesting that the remaining nodes form new clusters. Taken together, these results indicate that the pain network, like other complex systems, displays a high degree of tolerance against random failure, and the pain network is vulnerable to attacks, but responds differently than typical scale-free networks.

Materials and methods

Animals

This Study is reported in accordance with ARRIVE guidelines. Specifically, all procedures followed animal care guidelines approved by the Institutional Animal Care and Use Committee of the University of North Carolina at Chapel Hill, and by the International Association for the Study of Pain. Mice were housed at a maximum of 5 per cage and maintained on a 12-h light/dark cycle in a temperature-controlled environment with ad libitum access to food and water. TRAP2 (FosCreERT2) mice were purchased from Jackson Laboratory (Stock #: 030323).

Determining pain-related brain areas

To generate a comprehensive pain network, we conducted a literature search via Google Scholar (https://scholar.google.com/) and Pubmed (https://pubmed.ncbi.nlm.nih.gov/), aiming to include all brain areas reportedly involved in pain. We defined brain areas according to the Allen Reference Atlas ontology. Search keywords included “pain,” “nociception,” “chronic pain” and “neuropathic pain.” If a general brain region was reported to participate in pain, its functional subdivisions were included as individual nodes of the pain network.

Drugs

4-OHT (H6278, Sigma) was prepared in absolute ethanol and Kolliphor EL (C5135, Sigma) and administered intraperitoneally (50 mg/kg).

Pinprick to TRAP neurons active during pain

Mice were habituated in a cylinder for at least 30 min before the experiment. We then delivered noxious pinprick (25-G needle) stimuli to the plantar surface of the hindpaw of TRAP2 (FosCreERT2);Ai14 mice. In total, we administered 20 stimuli at 30 s intervals. After stimulation, mice were allowed to remain in the cylinders for an additional 2 h before receiving 4-OHT (50 mg/kg) injection subcutaneously. After 4-OHT injection, mice were allowed to remain in the cylinders for another 1 h before being returned to their homecages. Two weeks later, we perfused the mice and dissected the brains to verify tdTomato expression.

Histology

Animals were transcardially perfused with phosphate-buffered saline (PBS) followed by 4% formaldehyde in PBS. Brains were then dissected, post-fixed in 4% formaldehyde, and cryoprotected in 30% sucrose. Tissues were then frozen in Optimum Cutting Temperature compound (OCT; product code: 4583, Tissue Tek) and sectioned using a cryostat (Leica). Brains were sectioned at 40 μm and stored in PBS at 4 °C if used immediately. For longer-term storage, tissue sections were placed in glycerol-based cryoprotectant solution and stored at − 20 °C.

Imaging and cell counting

For imaging, sections were mounted on slides using Fluoromount-G (SouthernBiotech) and left at room temperature overnight for proper polymerization. Images were collected using a Carl Zeiss LSM 780 confocal microscope and processed with ImageJ (NIH). Cells expressing tdTomato were counted both manually and automatically using the “analyze particle” toolbox.

Projection data query from Allen Brain Atlas

After determining which brain areas participate in the pain network, we queried the projection data of each brain area via the Allen Brain Atlas API (Application Programming Interface) using R 4.0.2 software (The R Project for Statistical Computing). Projection data of most brain areas in the pain network were queried from wildtype mice. For six brain areas (CLA, VPL, MH, PG, RPO, IO) with no experiments performed in wildtype mice, we used the projection data from mutant mice. If multiple experiments were returned for one brain area, the projection intensity to other brain areas was calculated by averaging the projection intensity from all experiments. The injection coordinates of each brain area were collected and used to calculate the distance between brain areas (Fig. 2).

Visualization

All figures were generated using R 4.0.2. The position of each vertex was based on the injection coordinates for each brain area. We first calculated the distance between each brain area, then scaled it to two-dimensional coordinates using the “cmdscale” function from the “stats” package. The edge width of each vertex was determined by the projection strength. For better visualization, we performed a log transformation and scaled it down 5 times.

Network measures

In graph theory, a network consists of nodes (or vertices) connected by edges (or lines). A brain network can be represented as either a directed (edges extend from one vertex to another) or an undirected (edges connecting the vertices have no direction) graph. Notably, both structural and functional brain networks can manifest as either directed or undirected forms. Numerous measures exist to quantitatively describe graph topology, some of which are described below:

Node degree, distribution, and assortativity

A node's degree refers to the number of edges it shares with the overall network. Node degree is a foundational network metric, with most other measures having some connection to it. For random networks, in which every connection has an equal chance of forming, this distribution is Gaussian and symmetrically balanced. In contrast, complex networks typically exhibit non-Gaussian degree distributions, which often lean heavily towards higher degrees. In scale-free networks, degree distribution aligns with a power law. Assortativity measures correlation between the degrees of connected nodes. A positive assortativity indicates that nodes with a high number of connections tend to link with others of a similar degree.

Clustering coefficient and network motifs

When a node's immediate neighbors are directly connected, they form a cluster. The clustering coefficient measures the extent of these connections between a node's neighbors relative to the maximum possible connections they could have. In random networks, the average clustering is typically low, whereas complex networks tend to exhibit high clustering. This high clustering coefficient in complex networks often correlates with efficient local information transfer and resilience. The interactions among neighboring nodes can be further examined by quantifying the presence of small groups of interconnected nodes, known as motifs. Analyzing the distribution of various motif types in a network sheds light on the local interactions the network can facilitate.

Path length and network efficiency

Path length refers to the fewest edges needed to connect one node to another. Both random and complex networks typically exhibit short average path lengths, indicating an efficient global information transfer. In contrast, regular lattices tend to have longer average path lengths. Although efficiency is the reciprocal of path length, it is often simpler to use efficiency when gauging topological distances for graphs in which not all elements are connected.

Hubs and node centrality

Hubs are nodes with particularly high degree or pronounced centrality. The centrality of a node reflects how often the node appears in the shortest paths connecting all possible pairs of other nodes in the network. Nodes with significant centrality play pivotal roles in ensuring efficient communication within the network. To determine the value of a particular node to the network's efficiency, one can remove it and then compare the performance of the resulting compromised network.

Network robustness

Network robustness pertains to the stability and resilience of a network when subjected to disturbances or alterations. Specifically, it gauges the network's ability to maintain its overall structure and function despite the removal of nodes or edges, or when faced with external challenges.

General features analysis

Using the projection data of each brain area, we created an adjacency list and converted it into a directed graph using the “graph.data.frame” function from the “igraph” package55 (https://igraph.org) running on R. To exclude weak and/or spurious connections, brain areas with projection values of < 0.01 were not considered to be connected26. To visualize the network in 2D, the distances between brain areas are embedded into a 2D plane using multidimensional scaling.

Using the “igraph” package, we calculated the graph-theoretical metrics to evaluate the following general network properties: density, diameter, and reciprocity. The “edge_density” function was used to calculate the density of the pain network. The density of a graph is the ratio of the number of edges to the number of possible edges, \(D = \frac{|E|}{|V|*(|V|-1)}\). We used the “diameter” function to calculate the diameter of the pain network. The diameter of a graph is the length of the longest geodesic. We used the “reciprocity” function to measure the proportion of nodes in the pain network that share reciprocal connections.

Network centrality analysis

Using the functions from the “igraph” package, we evaluated the centrality of the pain network with three common measures: degree centrality, closeness centrality and betweenness centrality (Table 1 and Table S2). We used the “degree” function to determine the number of adjacent edges for each node in the network. The pain network we constructed is a directed network; thus, we analyzed the total degree, which is the sum of the in- and out-degree of each node. We used the “closeness” function to measure closeness centrality, an indicator of how close each node is to every other node in a network. Finally, we used the “betweenness” function to measure node betweenness, defined by \(g(v) = {\sum }_{s\ne v\ne t}\frac{{\sigma }_{st}(v)}{{\sigma }_{st}}\), where \({\sigma }_{st}\) is the total number of shortest paths from node \(s\) to node \(t\), and \({\sigma }_{st}(v)\) is the number of those paths that pass through \(v\). Betweenness indicates the likelihood that a node sits between each pair of other nodes in the network.

Community detection

We used the “cluster_walktrap” function to detect the communities of the pain network (Fig. 5b and Table S3). This function uses the Walktrap community finding algorithm39 to identify densely connected subgraphs.

Random network models

We generated three random network models to compare against the pain network. We used the “erdos.renyi.game” function to generate a random network with an identical number of nodes and edge density. Next, we used the “sample_smallworld” function to create a small-world network by setting the argument “size” equal to the number of nodes in the pain network, “nei” equal to the average number of edges each node has in the pain network, and the \(p\)(wiring probability) at 0.05. Finally, we generate a scale-free network using the “sample_pa” function. The argument “n” equals the number of nodes in the pain network, “power” at 0.5, using the “psumtree-multiple” algorithm.

Robustness analysis

We assessed the error tolerance of the pain network against random failure and attack by continuously evaluating its diameter while removing a small fraction \(f\) of the nodes54. To test tolerance against random failure, we removed nodes at random; to measure tolerance against attack, we specifically removed hub nodes. For each value of \(f\), we repeated this process 100 times.

To evaluate the fragmentation process while removing nodes from the pain network, we measured the size of the largest cluster, \(S\), shown as a fraction of the total system size, when a fraction \(f\) of the nodes were removed either at random or in an attack54. We also measured the changes in average size < \(s\)> for all clusters except the largest, when a fraction \(f\) of the nodes were removed either at random or in an attack mode. For each \(f\), we repeated this process 100 times.

Discussion

Using projection data from the Allen Brain Connectivity Atlas, we built a structural pain network and analyzed it using graph theory. We found that brain areas in this pain network display extensive reciprocal connections, and these connections show ipsilateral distance dependence. Based solely on projection data, community detection clearly identified and separated the two systems for the sensory versus affective component of pain (Fig. 5b and Table S3). Compared with three common random models, the pain network has a positive assortativity coefficient (Table 2), indicating that this pain network is assortative. Finally, robustness analysis indicated that the pain network shows a high degree of error tolerance but is vulnerable to attacks (Fig. 6). The attack vulnerability of the pain network opens up the possibility of alleviating pain by targeting hub brain nodes.

Structure–function relations of the pain network

Physical connection strength between brain areas in this structural pain network varies widely (Fig. 2). This is in line with the diverse functional connectivity strength between brain areas determined by pairwise correlation analysis of their activity during pain23,56. However, a high functional correlation between brain areas does not necessarily entail a strong physical connection57,58, because additional factors contribute to functional correlation, such as the quantity, strength (e.g., synaptic efficiency), and dynamic modulation (e.g., short- and long-term synaptic plasticity) of the physical connections59. Network-level factors also play a role. For example, two brain areas without any direct connection can show highly correlated activity via one or more intermediate brain areas60,61. How physical connections lead to the functional correlation between brain areas during pain, and the mechanisms by which structural and functional connectivities change during chronic pain are interesting subjects for future study.

Several brain areas in the cerebral cortex, including the ACC, motor cortex and somatosensory cortex show strong interhemispheric connections (Fig. 2). Previous studies have shown that interhemispheric communication of the dorsolateral prefrontal cortex (DLPFC) influences pain tolerance and discomfort by modulating interhemispheric inhibition62,63. In addition, unilateral optogenetic stimulation of pyramidal neurons in the somatosensory cortex can prevent or reduce mechanical hypersensitivity bilaterally64. Thus, additional studies are still needed to elucidate the role of cortical interhemispheric connections in pain processing.

Hubs of the pain network

Hub nodes facilitate information integration by occupying a highly connected and functionally central position in the network65. Hubs can be identified using several forms of centrality analysis, such as degree-based, strength-based, and path-based66. However, all of these measures have limitations when identifying the hubs of functional networks generated using data from brain imaging techniques66,67. We conducted topological centrality analysis of our structural pain network using degree, betweenness and closeness centrality (Table 1 and Table S2). Degree centrality analysis indicated that the CP, MOs and MD are the most highly connected nodes in this pain network, consistent with their critical roles in pain perception68,69,70,71. Betweenness and closeness centrality (path-based measures) identified the PB, which has been recognized as a sensory hub for both pain and aversion38,72, as the topological center of the pain network.

Communities for multi-dimensional pain

Pain is a multidimensional experience with sensory-discriminative and affective-motivational components1,6,7,73. The sensory-discriminative component determines the spatiotemporal characteristics and qualia of pain, while the affective-motivational component mediates pain unpleasantness74. Although there remain debates as to the separability of these two components73, two pain systems, the lateral and medial, have been proposed to contribute to the sensory and affective dimensions of pain, respectively. Remarkably, our community detection of the pain network clearly separated these two systems using only the physical projection data (Fig. 5b and Table S3). Importantly, our analysis suggested several brain areas in the network that may contribute differently to the sensory or affective component of pain. For example, the red nucleus (RN) and zona incerta (ZI) were detected in the medial pain system, pointing to a role for these brain areas in affective pain (Fig. 5b and Table S3). Interestingly, our community detection suggests that the primary motor cortex (MOp) contributes to the sensory component of pain, while the MOs processes the affective component (Fig. 5b and Table S3). Motor cortex stimulation (MCS), primarily of the MOp, has been used clinically to treat neuropathic pain75,76. Thus, it may prove interesting to investigate the effects of MOs stimulation.

Further, community detection revealed several previously unidentified communities (Fig. 5b and Table S3). One intriguing community comprises the hippocampal formation (CA1, CA3 and DG) and the habenular nuclei (MH and LH). The hippocampus critically contributes to learning and memory77,78, while the lateral habenula plays a role in aversive learning and memory79,80. Pain, particularly chronic pain, shares several commonalities with learning and memory, and has been characterized as a “painful memory”81,82,83. Thus, this novel community could prove an exciting target for future investigations aiming to elucidate the role of learning and memory in pain, especially in pain catastrophizing.

Pain network assortativity and robustness

Network topology determines both the efficiency84,85,86 and strength of the entire system54,87. In this study, we compared the topology of this structural pain network to three random network models with identical density: the Erdős-Rényi random graph model, the Watts-Strogatz small-world model and the Barabási-Albert scale-free model. None of these models perfectly fits all characteristics of the pain network, which shows a right-skewed degree distribution (Fig. 5c) and the highest clustering coefficient (Fig. 5d).

The pain network shows a positive assortativity coefficient (Table 2), indicating that it is assortative. Assortative networks are rare among complex biological networks, which tend to be disassortative50,51. In contrast, assortative networks abound in social science, in which individuals tend to bond with others who share similar characteristics88,89. Assortativity facilitates cooperation in social activities90 and promotes information distribution91. Thus, the positive assortativity coefficient of the pain network indicates that brain areas in the network share similarity in connectivity, which may facilitate pain processing.

In addition, our analysis indicates that this assortative pain network shows a high degree of error tolerance to random failures (Fig. 6). The error tolerance of the pain network provides a possible structural network mechanism underlying the intractability observed in some cases of chronic pain92. However, unlike assortative networks which are resilient, the pain network is vulnerable to attacks, behaving similarly to disassortative scale-free networks50,54.

Attack vulnerability of the pain network

Most social and technological networks display an unexpected degree of error tolerance. For instance, we rarely experience global network outages despite frequent rooter issues. However, the error tolerance of these networks comes at the expense of attack survivability: removing the most connected node substantially changes the connectivity of a network. Attacking search engines nowadays, such as Google, would significantly affect our ability to surf and locate information on the web.

Interestingly, the assortative pain network is vulnerable to attacks (Fig. 6). The attack vulnerability of the pain network indicates that the pain network could be damaged by targeting hub brain nodes. Indeed, deep brain stimulation in the striatum93, motor cortex94,95 and thalamus96,97, the densely connected nodes in the pain network (Table 1 and Table S2), has been used for pain control in clinics. While such treatments confer particularly effective pain relief98, they have primarily been empirical. Our study provides a network-level explanation for the effectiveness of these applications, potentially paving the way for the development of new therapies that target hub nodes in the pain network to enhance their efficacy further.

Limitations of the study

The primary limitation of this study concerns the inclusion of all pain-related brain structures in our structural pain network. First, our analysis is limited by the connectivity metrics available in the Allen Brain Atlas. While the atlas offers a comprehensive whole-brain connectivity matrix, it lacks detailed sub-region data for certain areas, such as the insular cortex. Second, although the TRAP2 mutant mouse line is a valuable tool for identifying brain areas involved in pain perception by labeling neurons active during pain experiences, it lacks a perfect control. This is due to the inherently painful experience caused by 4-OHT injections. Therefore, we identified the brain structures in this structural pain network through literature searches and further validated them using TRAP2. However, it is possible that some brain areas involved in pain sensation were not included.

Moreover, it remains unclear whether the network features we identified are specific to pain processing or might represent a more general characteristic of sensory systems. For instance, the central nervous system is equipped with well-defined sensation-specific regions, such as the visual cortex for processing light and the auditory cortex for interpreting sound. However, similar to pain, both visual and auditory stimuli can also elicit responses of discomfort, unease, or negative reactions. Furthermore, emotional states are known to significantly influence sensory processing across these modalities, suggesting an intricate interplay between cognitive-emotional factors and sensory perception. This raises the possibility that the network features observed in pain processing may have parallels in the networks of other sensory modalities. Comparing these network features could provide valuable insights into the shared and distinct neural pathways involved in pain and other sensations. However, such a comparison requires a multidisciplinary approach, combining expertise in pain neurobiology with a deep understanding of other sensory modalities, which extends beyond the focus of this study. Nevertheless, this limitation opens an exciting avenue for future research.

In conclusion, our graph theory analysis revealed an assortative pain network in the brain for pain processing. The pain network displays a high degree of tolerance against random failure but is vulnerable to attacks. This structural pain network reflects the hierarchical organization of the functional pain network and may underlie the diverse and persistent activity patterns during acute and chronic pain. Combined with functional neuroimaging, neurophysiology techniques and machine learning, graph theory analysis of the pain network could provide a novel way to objectively diagnose, at the system level, both acute and chronic pain. Most importantly, this deeper understanding of the pain network could lead to novel therapeutic methods for pain management.

Data and code availability

The R code used to query projection data from Allen Brain Institute, pain network analysis and visualizations is provided at https://github.com/chenchong446337/pain_netwrok. The projection data from each brain area to others in the pain network are also included.