Page whose size is the number of members) and online ISIS communities (each is a VKontakte Group whose size is the number of members). Their empirical growths (symbols) differ and occur over different timescales, yet they follow the same mathematical equation that incorporates individual user heterogeneity into the online social aggregation process (solid lines). For visual clarity, only a few of the communities are shown in the main plots. Our data collection follows previous work 17, 18, 19, 20, 21 and focuses on communities (Pages, Groups) since these play a greater role in nurturing narratives than platforms like Twitter which have no pre-built community tool. C: Schematic of our mathematical theory showing predicted onset times for example F values (see SM). D: Predicted curves from our theory (arbitrary units) show how onset can be delayed and the curve flattened by nudging F and hence nudging the collective chemistry.
Our mathematical theory of aggregation-with-heterogeneity (Fig. 1C ) makes specific predictions: (1) There is a single equation that governs the emergence and evolution of each individual extremist community (Fig. 1A,B) and also an entire extremist movement ( Fig. 2A,B) . It is a generalized shockwave equation (3) Each community in Fig. 1 and the entire movement in Fig. 2 , is predicted to have its own tipping
which signals the onset of a macroscopic swell in online support. This tipping point is, in the limit of large *, a dynamical phase transition. (4) The community size distribution at the onset 3 -./0$ (see Fig. 2 insets) is predicted to be a powerlaw with exponent − 5 2 ⁄ = −2.5. The onset times 3 -./0$ and growth curves 1(3) for each Boogaloo community and ISIS community in Figs. 1A,B, and for the movements as a whole in Fig. 2A ,B, are well described by these mathematical predictions. Moreover, Fig. 2A ,B insets show that the individual community sizes at 3 -./0$ exhibit the predicted power-law exponent −2.5. Since the theoretical formulae are derived for * very large, the predicted onsets are too sharp: but at the expense of losing the closed-form formulae, we can extend the theory to account for finite * as in the empirical data. The transition then becomes smooth like the empirical data, with the size at the onset varying as [*] ,+/2 as opposed to being strictly zero.
The inferred membership heterogeneity is similar for each movement (Figs. 2A,B) with both $ values being statistically indistinguishable from 1 3 ⁄ = 0.33, which is the value predicted mathematically for aggregation favoring diversity in a population with uniformly distributed {" ⃗ ! } (see SM). This would suggest that each movement develops by aggregating diverse sets of supporters from the global online user pool, instead of some particular pre-polarized population. The Fig. 1A inset shows that the membership heterogeneities $ of individual Boogaloo communities are also close to 1 3 ⁄ which suggests that individual Boogaloo community formation is also driven by the same preference for diversity as the entire Boogaloo movement. This is consistent with the eclectic mix of memes and ideas that we observe in the content of each Boogaloo community, and the lack of any increase in topic coherence that we observe from our dynamic Latent Dirichlet Allocation topic analysis of their narratives (see SM). By contrast, individual ISIS communities have $ values closer to 2 3 ⁄ (Fig. 1B  inset) which suggests that once inside the ISIS movement, its supporters form into communities which are each internally homogenous and have a well-defined narrative flavor. Overall, this suggests that while Boogaloo and ISIS recruits join the overall movements driven by diversity, Boogaloos continue with this diversity driver when forming and joining an individual community, while ISIS supporters prefer a community to have a single narrative flavor.
By incorporating the interplay between individual human heterogeneity and connective action 22 online (Figs. 1, 2) , our mathematical theory has placed these extremist movements' evolutions on the same footing --akin to a single equation in physics explaining the different trajectories of a plane taking off vs. landing in terms of uplift vs. gravity. While there will always be different trajectories for different movements and different communities within each movement, this identification of a shared mathematical order 23, 24, 25, 26, 27 opens the door to a common set of mitigation strategies.
An immediate example is the mathematical theory's prediction that online extremism can be mitigated by nudging the online collective chemistry. Slightly decreasing $ at the level of the entire movement or individual communities (Fig. 1D ) delays the onset (since 3 -./0$ ∝ 1 $ ⁄ ) and flattens the growth curve 1(3): specifically, −∆$ $ ⁄ = ∆3 -./0$ 3 -./0$ ⁄ . This could be achieved by biasing the interaction of dissimilar individuals such that aggregation favors dissimilar " ⃗ ! 's, by injecting their online space (e.g. Facebook Page) with more diverse material, or by nudging the composition of the overall pool of potential recruits (see SM). Alternatively, by nudging smaller (and hence potentially less robust) communities, the power-law distribution at the onset can be disrupted (see SM) which in turn disrupts the dynamical phase transition and hence delays the onset of support. These approaches, while significant challenges in practice, are preferable to blanket shutting down of all communities: the latter would rely on them all being found, risks claims of freedom-of-speech, and could ignite new support.
Explaining why the Boogaloos have suddenly emerged requires deeper social, political and economic debate. However, our mathematical analysis offers a quantitative answer by extending the heterogeneity-driven aggregation toward a generalized version of the sociological Seceder Model of Dittrich et al. and Halpin-Healy et al. 28, 29, 30 (Fig. 3 , SM) which features a competition between the pressure to conform and the desire to dissent. Such a competition is consistent with the Boogaloos' eclectic mix of fads (e.g. memes) and fashions and the lack of any increasing topic coherence in their narratives (see SM). This model correctly predicts the emergence of 3 stable movements (Fig. 3) and it could even be used to estimate the number of new extremist 'branches' to expect in the future. Among potential limitations of our study, is the fact that our mathematical analysis will always be an approximation and hence the theoretical predictions in Figs. 1 and 2 are not perfect. While the smooth onset of the empirical growth curves can be reproduced at the expense of a loss of closed-form formulae as discussed earlier, there are still unexplained bumps and jumps. However, these can also be reproduced if we allow for an online influx of potential recruits and hence * becomes a function of time. We also need to study future extremist movements as they emerge over time online, to check the generality of our findings. However, the Boogaloos and ISIS are certainly movements of high current importance --and the SM shows that their hidden mathematical order reported here, does not arise for other online human aggregation behaviors. Finally, we stress that our mathematical analysis is targeted at complementing current analyses in the social sciences, not to replace them.