Thank you for visiting nature.com. You are using a browser version with limited support for CSS. To obtain the best experience, we recommend you use a more up to date browser (or turn off compatibility mode in Internet Explorer). In the meantime, to ensure continued support, we are displaying the site without styles and JavaScript.

# Group mixing drives inequality in face-to-face gatherings

## Abstract

Uncovering how inequality emerges from human interaction is imperative for just societies. Here we show that the way social groups interact in face-to-face situations can enable the emergence of disparities in the visibility of social groups. These disparities translate into members of specific social groups having fewer social ties than the average (i.e., degree inequality). We characterize group degree inequality in sensor-based data sets and present a mechanism that explains these disparities as the result of group mixing and group-size imbalance. We investigate how group sizes affect this inequality, thereby uncovering the critical size and mixing conditions in which a critical minority group emerges. If a minority group is larger than this critical size, it can be a well-connected, cohesive group; if it is smaller, minority cohesion widens inequality. Finally, we expose group under-representation in degree rankings due to mixing dynamics and propose a way to reduce such biases.

## Introduction

Face-to-face interaction is a fundamental human behavior, shaping how people build and maintain social groups by segregating themselves from others1,2,3,4. This segregation can generate or exacerbate intergroup inequality in networks, producing unequal opportunities in different aspects of people’s lives, such as education, employment, and health5,6,7,8,9, especially when individuals tend to interact with similar others10. Though crucial to a just society, however, our understanding of the interplay between group dynamics and the emergence of inequalities in social gatherings remains limited and quantitatively unexplored.

With deep roots in sociology and anthropology1,2,3, the study of face-to-face interaction has advanced considerably in recent years, mainly because of new tracking devices providing fine-grained data on human interaction11,12,13,14,15. This data has enabled researchers to uncover several properties in the way people interact with others16,17,18,19,20,21. For example, in a social gathering, individuals tend to interact with an average number of individuals, a quantity that depends on the social occasion21. Though this number exhibits a trend across individuals in a gathering, the duration of each interaction lacks a central tendency—it might last from a few seconds to a couple of hours17,18,19. These two properties have been found universally in many distinct social situations, such as schools and workplaces, indicating the existence of fundamental mechanisms underlying face-to-face interaction.

Simple social mechanisms can explain these properties as a result of local-level decisions based on individuals’ attributes22,23,24,25. One crucial attribute in face-to-face situations is the so-called attractiveness. People with high attractiveness are more likely to stimulate interaction with others. This principle, together with individuals’ social activity, constitutes a mechanism that explains well the properties found in empirical data23 and has been extended to describe other features in face-to-face interaction, such as people’s tendency to engage in recurrent interaction22,25. However, focusing solely on individuals’ attractiveness neglects the crucial role of pairwise interactions and social groups. For example, an attractive individual might feel unwelcome in a community if this person is an outsider of that particular social group.

How social groups interact can define the position of individuals in networks, particularly when groups have unequal sizes. For instance, the smallest group (i.e., the minority group) in a network can have a systemic disadvantage of being less connected than larger groups, depending on the group mixing26. Having a lower number of connections poses several disadvantages to individuals, such as low social capital27, health issues28, and perception biases29. Yet, the mechanisms underlying group dynamics and their relation to degree inequality in social gatherings are still unexplored.

Here we show numerically, empirically, and analytically that degree inequality in face-to-face situations can emerge from group imbalance and mixing. We present a mechanism—the attractiveness–mixing model—that integrates mixing dynamics (i.e., pairwise preferences) with individual preferences, expanding the established attractiveness paradigm. While attractiveness is an intrinsic quality of the individual, mixing dynamics manifest between pairs of individuals; together, they form what we call social attractiveness. The mechanism reproduces the intergroup degree inequality found in six distinct data sets of face-to-face gatherings. With the analytical derivation of our model, we further demonstrate the impact of group imbalance on degree inequality, finding a critical minority group size that changes the system qualitatively. When the minority group is smaller than this critical value, higher cohesion among its members leads to higher inequality. Finally, we expose the under-representation of minorities in degree rankings and propose a straightforward method to reduce bias in rankings.

## Results

We study the dynamics of social gatherings using six different data sets30, four from schools11,19,31 and two from academic conferences14. Each data set consists of the individuals’ interactions captured via close-range proximity directional sensors that individuals wore during each gathering. With these data sets, we construct the social network of each gathering, where a node is an individual and an edge exists if two individuals have been in contact (i.e., face-to-face interaction) at least once during the study (Table 1). In these networks, the degree distributions exhibit a single peak at the center (see Supplementary Note 1). The data further contain gender information on individuals, which allows us to define two groups in each network; we refer to social groups as a group of people who share similar social traits32. In this paper, a social group refers to individuals who share the same gender. In all considered data sets, there are fewer female participants than male participants. We refer to the smallest group as the minority group, and we denote 0 as the label for the minority group and 1 for the majority. In our manuscript, we define group mixing as the systematic preference of group members to interact with individuals from specific social groups (including their same group).

### Degree inequality and mixing in face-to-face interaction

To characterize the connectivity of the groups in the networks, we measure the average degree of individuals in each group, finding a systematic degree inequality among groups (Fig. 1a). The minority group exhibits a lower average degree than the majority group in School 1, School 2, and School 3, whereas the opposite occurs in Conference 2 and School 4, and both groups have the same average degree in Conference 1. Though this degree inequality arises in face-to-face situations, an intrinsic-attractiveness model of face-to-face interaction23 fails to explain the group differences (dashed line in Fig. 1a) because it ignores group mixing in social gatherings.

To understand how groups mix in the networks, we examine the inter- and intragroup ties by comparing them with the configuration model (see “Methods”). We find that individuals were more likely to interact with individuals from the same group, indicating that homophily33 plays a significant role in face-to-face situations. In most of the networks, our results show that intragroup ties are more frequent than what one would expect by chance (Fig. 1b).

However, this group mixing cannot emerge in the intrinsic-attractiveness paradigm because it lacks relational attributes. In this paradigm, systematic variations in individuals’ attributes can lead to group differences, but they fail to form mixing patterns as observed in data. For example, consider a social gathering in which the members of the minority group have lower intrinsic attractiveness than the majority group. In this scenario, according to the intrinsic-attractiveness paradigm, the minority group would tend to interact with the majority group, boosting the majority group average degree. This setting would explain group degree inequality. However, in this same setting, the members of the minority group would be less prone to interact with their own group—the opposite of what occurs in the data, where intragroup mixing is significant (Fig. 1b; see also Supplementary Note 2). In other words, variations in individuals’ attractiveness are insufficient to explain the degree inequality and group mixing observed in the data. To uncover the underlying mechanism of these social dynamics, we need to disentangle the individuals’ intrinsic attractiveness and the relational attributes in face-to-face interaction.

### Modeling mixing in social interaction

We present the attractiveness–mixing model that incorporates (i) intrinsic attractiveness of individuals and (ii) relational attributes between groups. We show that these ingredients are sufficient to explain the degree inequality observed in social dynamics with minority groups. In the model, each individual has an intrinsic attractiveness and belongs to a group. The members of a group share the same mixing tendency, which regulates the pairwise interactions. In general, individuals move across space and form social ties depending on their group membership and the composition of their surroundings (see Fig. 2a, b). In the attractiveness–mixing model, an individual i has three attributes: a group label bi [0, B − 1], where B is the number of groups; an intrinsic attractiveness ηi [0, 1]; and an activation probability ri [0, 1]. The mixing patterns in this system are encoded in the B × B mixing matrix H. Each row of H can be seen as a probability mass function that weighs the likelihood of group interaction. In this model, N individuals perform random walks in a two-dimensional L × L periodic space and move based on the composition of their vicinity. We define $${{{{{{{{\mathcal{N}}}}}}}}}_{i}(t)$$ as the set of individuals who are within radius d of individual i at time t. We denote nb as the size of a group b and fb = nb/N as the group fraction. The individuals move only probabilistically. At each time step t, each individual i moves with probability

$${\alpha }_{i}(t)=1-\mathop{\max }\limits_{j\in {{{{{{{{\mathcal{N}}}}}}}}}_{i}(t)}\{{\eta }_{j}\}$$
(1)

and a step of constant length v along a random direction of angle ξ (0, 2π]. With the complementary probability, individual i does not move and has the chance to interact with individuals in the vicinity depending on the group mixing likelihood. Precisely, individual i interacts with their neighbors of highest mixing likelihood with probability

$${\beta }_{i}(t)=\mathop{\max }\limits_{j\in {{{{{{{{\mathcal{N}}}}}}}}}_{i}(t)}\{{h}_{{b}_{i}{b}_{j}}\},$$
(2)

where $${h}_{{b}_{i}{b}_{j}}$$ is an element of H and denotes the mixing probability between bi and bj (see Supplementary Note 3 for pseudocode). Overall, an individual interacts with other individuals depending on their intrinsic attractiveness and social group mixing; together these two ingredients form the social attractiveness. Finally, individuals can be active or inactive; they only move and interact with others if they are active. An inactive individual i becomes active with probability ri, whereas an active but isolated individual i becomes inactive with probability 1 − ri. In this study, we assume that the intrinsic attractiveness ηi and the activation probability ri come from a continuous uniform distribution in [0, 1].

The mixing matrix H and the group sizes have a significant impact on the model dynamics, affecting the connectivity of individuals, especially when groups have different sizes. For example, in a system having two groups, a minority group with proportional size f0 = 0.2 and a majority group with f1 = 0.8, the mixing dynamics lead the system to different regimes that affect the groups’ average degree (Fig. 2c). When intragroup interaction is less likely than intergroup interaction (i.e., h < 0.5), the system is in a heterophilic regime, and the minority group has a higher degree than the majority. This degree disparity arises because of the majority group favoring interaction with a small number of people (i.e., the minority group), thereby reducing the majority group connectivity. The opposite occurs in a homophilic regime, where intragroup interaction is more likely than intergroup interaction (i.e., h > 0.5), which results in the minority having a low average degree.

To investigate group degree inequality, we derive the model analytically to uncover the impact of mixing dynamics and group sizes on inter- and intragroup edges. Without loss of generality, we focus on the case of two groups, B = 2, finding the closed-form expressions for the normalized group edge matrix, ers = Ers/E, and the mixing matrix H (see “Methods” for details). The normalized intragroup edges are given by

$${e}_{00}=\frac{{f}_{0}^{2}(1-{h}_{01}^{2})}{{f}_{0}^{2}(1-{h}_{01}^{2})+2{f}_{0}{f}_{1}(1-{h}_{00}{h}_{11})+{f}_{1}^{2}(1-{h}_{10}^{2})}$$
(3)

and

$${e}_{11}=\frac{{f}_{1}^{2}(1-{h}_{10}^{2})}{{f}_{0}^{2}(1-{h}_{01}^{2})+2{f}_{0}{f}_{1}(1-{h}_{00}{h}_{11})+{f}_{1}^{2}(1-{h}_{10}^{2})},$$
(4)

and similar expressions exist for the intergroup edges (see “Methods”). With these expressions, not only can one study the model dynamics, but one can also estimate the mixing matrix from empirical networks and assess the model’s ability to explain data.

### Estimating the mixing matrix from data

To compare the attractiveness–mixing model with the empirical data, we simulate the model with the parameters as estimated from the data. Our results show that the model reproduces the average degree inequality observed in the networks (Fig. 1a). We use Eq. (3) and Eq. (4) to estimate the mixing matrix H from the data (Fig. 1c; see “Methods”). This matrix tells us the tendency of groups to interact among themselves in each face-to-face opportunity. With the estimated matrices, we simulate the model using the same number of nodes and group sizes in each data set. We show that mixing dynamics and group imbalance enable the emergence of the group disparities observed in the data by using Kolmogorov–Smirnov test (see Supplementary Note 5). In addition, the model reproduces other properties found in face-to-face gatherings such as the distributions of interaction duration, inter-interaction time, and weight distribution (see Supplementary Note 6).

We highlight that the degree inequality can favor the minority or majority group. For example, in the School 4 and Conference 2 data sets, the smallest group tends to have more connections than the largest group. The model exhibits the same tendency. From a model perspective, this phenomenon can occur because of the asymmetry in the group mixing. To understand such cases better, we delve into the model and its regimes.

### Mixing dynamics, asymmetry, and minority size

To uncover the regimes and scenarios of group inequality in the model, we characterize the impact of mixing and group sizes on average group degree. First, we study the trivial symmetrical mixing when h00 = h11 = hrr, and then we examine the impact of mixing asymmetry (i.e., h00 ≠ h11) on the social dynamics. In the asymmetrical case, we define the intergroup mixing as the complementary probabilities h01 = 1 − h00 and h10 = 1 − h11.

In the symmetrical case, we find that homophily and heterophily manifest themselves as two distinct regimes determining the position of the minority group in the network. We analyze the average degree of the groups given different values of group mixing hrr and minority fraction f0. First, we simulate the model and measure the average degree of the minority 〈k0〉 and majority 〈k1〉 groups (see “Methods”). Then, we separately compare 〈k0〉 and 〈k1〉 to the average degree 〈k〉 of the whole network using their z scores (Fig. 3a). Our results show that the members of the minority group have an advantage or disadvantage depending on the model parameters.

Homophily (i.e., hrr > 0.5) leads the minority group to be decoupled from a substantial part of the network. In this case, minority group members have a lower average degree compared to the average. In the heterophilic regime (i.e., hrr < 0.5), the minority group has high visibility, which leads its members to have a higher degree than average. The existence of these two contrasting regimes implies that the very interpretation of a minority group depends on the group mixing in the network. When studying a minority group, one has to account for inter- and intragroup dynamics to understand its position in a network.

To characterize the impact of asymmetrical mixing on degree inequality, we examine the whole parameter space of the mixing matrix H numerically. We find that the majority mixing h11 substantially contributes to degree inequality. First, we estimate the average minority degree for different values of h00 and h11, given specific minority fraction values f0. Then, we measure the distance of the minority group degree to the overall average degree using z scores, denoted k0 − 〈k〉 (see Fig. 3b). Our results show that the majority mixing h11 explains much of the variance of k0 − 〈k〉. While adjusting h11 can change the position of the minorities from advantage to disadvantage, modifying h00 can attenuate this inequality only slightly.

### Strategies for minority groups to alleviate degree inequality

To uncover the ways the minority group can attenuate inequality, we investigate how k0 − 〈k〉 varies with changes in the minority mixing h00. We find that the size of the minority group modifies the system qualitatively, revealing that changes in the minority mixing can have opposite impacts on degree inequality. For instance, given a constant value of h11 = 0.5, increasing h00 can reduce or accentuate degree inequality, depending on the minority fraction f0 (see Fig. 3c). To characterize this transition, we examine the derivative of k0 − 〈k〉 with respect to h00 as a function of f0 (Fig. 3d). Precisely, we are interested in the zero of this function, which tells us the critical minority fraction $${f}_{0}^{* }$$ at which the qualitative transition occurs. We find that this transition depends on the mixing dynamics of the system; its analytical form is given in Supplementary Note 7. Because the exact analytical form is too intricate, we approximate it by assuming that the values of h00 and h11 are not at their extremes, finding that:

$${f}_{0}^{* }=\frac{{h}_{11}}{2({h}_{01}+{h}_{11})}.$$
(5)

This equation demonstrates the control of the majority mixing over the minority group. The critical minority fraction $${f}_{0}^{* }$$ delineates two regimes where k0 may either increase or decrease with a raise of h00, given a fixed h11 (see Fig. 3e).

These regimes translate into two strategies to increase the minority average degree, which depends on the minority group size. First, when the minority group corresponds to more than $${f}_{0}^{* }$$ of the network, increasing h00 leads to an increase in the average minority degree. In this scenario, a more cohesive minority group is beneficial to its average degree. Second, in the case of a smaller minority group, increasing h00 decreases its degree; a more cohesive minority comes with the cost of a less connected minority. In this case, decreasing h00 helps in increasing the average degree of the minority group.

To find when increasing minority homophily is always beneficial to the minority group, we characterize the upper limit of $${f}_{0}^{* }$$. This upper limit, denoted as $$\overline{{f}_{0}^{* }}$$, represents the smallest minority size in which the minority group can increase its homophily without detriment to its average degree, regardless of the majority mixing. We note that $$\overline{{f}_{0}^{* }}$$ is equivalent to the critical size $${f}_{0}^{* }$$ when h11 = 1 (see Fig. 3e), so its exact analytical form is:

$$\overline{{f}_{0}^{* }}=\frac{1}{2-{h}_{00}+\sqrt{3+2\,({h}_{00}-2){h}_{00}}}.$$
(6)

For example, in the case of h00 = 0.5, when the minority represents more than 36.7% of the population, the group increases its average degree by being more homophilic, regardless of how the majority group mixes.

### Emergence of ranking misrepresentation

From the model’s viewpoint, mixing dynamics can inflate individuals’ degrees because these dynamics tune individuals’ intrinsic attributes. We show that group mixing can also lead social groups to be misrepresented in degree ranking. This misrepresentation is evident when we compare individuals’ degrees with their intrinsic attractiveness in heterophilic, neutral, and homophilic symmetrical regimes (see Fig. 4). Systematically, degree centrality disguises intrinsic attractiveness in nonneutral regimes. In a heterophilic scenario, minority members with low intrinsic attractiveness tend to have a higher degree than members of the majority group. In a homophilic situation, highly attractive minority members tend to have a lower degree than their majority counterparts. Because intrinsic attractiveness is hidden behind degree centrality, group members can be misrepresented in degree rankings.

To characterize minority representation in rankings, we compare degree-based rankings against rankings based on intrinsic attractiveness. We show that minority members are underrepresented in homophilic regimes, whereas they are overrepresented in heterophilic regimes. First, we rank individuals separately by degree and intrinsic attractiveness, and then we measure the minority percentage in each ranking as we increase the rank length (i.e., the top-k rank; see Fig. 5a for a homophilic network). In the case of intrinsic attractiveness, we expect that the number of minority members in the top-k rank is proportional to the minority size, since intrinsic attractiveness is uniformly distributed. This ranking displays this exact behavior (Fig. 5a). In the case of the degree ranking, however, the minority group has a substantially lower chance of appearing in the top ranks than what we expect from their attractiveness. These results indicate that degree ranking incorporates the mixing dynamics of the system (see Supplementary Note 8 for a heterophilic case). This effect raises the question of how to decrease ranking misrepresentation. This type of ranking adjustment would be valuable, for example, when algorithms are used to rank and recommend individuals; the minority’s visibility could be penalized in rankings despite their potential high intrinsic attractiveness.

### Decreasing ranking misrepresentation

To adjust the degree ranking, we need to account for the group sizes and mixing. Given that group mixing affects groups’ average degree, we must compare only the degrees of individuals of the same group, thereby excluding the influence of group mixing. We show that this approach can balance degree rankings to contain a representative number of group members. First, we calculate the z score degree of each individual with respect to their average group degree; then, we rank all individuals based on their z score. Our results reveal that the adjusted degree ranking better represents the minority group, similar to what we would expect in the attractiveness ranking (Fig. 5a). Furthermore, the adjusted ranking also helps expose misrepresentation in degree rankings in different regimes. To that end, we compare individuals’ positions in each ranking (Fig. 5b). As expected, heterophily promotes minority members to higher positions in the degree ranking, whereas homophily pushes the minority down. To characterize this misrepresentation, we analyze the correlation between the intrinsic attractiveness and the adjusted and degree rankings. We measure the Spearman correlation between the rankings and intrinsic attractiveness of nodes in different regimes (Fig. 5c). We find that the adjusted ranking tends to agree with attractiveness except in the extreme cases of hrr = 0 and hrr = 1. With the adjusted degree ranking, we decrease the misrepresentation bias in rankings.

## Discussion

Face-to-face interaction is arguably a primary mechanism for the transmission and affirmation of culture3. When people interact with others, they construct a social world and participate in shaping the identity of social groups. In this work, we show that systemic degree inequality emerges in social gatherings from the way group members interact in imbalanced scenarios. Previous research has overlooked this inequality, suggesting that mainly the individuals’ intrinsic attractiveness governs their connectivity. Our results indicate, however, that group dynamics modulate individuals’ intrinsic attractiveness, forming what we have called social attractiveness in face-to-face situations.

In social gatherings, social attractiveness entangles with space and time variables, which restricts opportunities for face-to-face interaction, leading to systemic degree inequality. To interact, individuals must have opportunity availability (i.e., available place and time) and space–time convergence (i.e., individuals must agree on where and when to interact). In confined situations, such as conferences and workplaces, spatiotemporal constraints are critical to interaction opportunities. For example, there exists a limited number of opportunities for interaction at conferences (e.g., coffee breaks). When an individual uses an opportunity to interact with someone, fewer opportunities remain for interacting with other individuals. In imbalanced scenarios, when a majority member interacts with someone from the majority, fewer opportunities remain for this individual to interact with minorities, thereby decreasing minority connectivity. Such a decrease means that in the majority group position, creating homophilic ties comes at the cost of promoting inequality in group connectivity.

From a group-level perspective, mitigating this inequality depends primarily on the mixing of the majority group and its size—the minority group can only slightly reduce inequality, exhibiting a qualitative transition in the strategy for this reduction. Our results show that the majority group mixing explains most of the variance in connectivity inequality. To attenuate inequality, the minority group needs to follow a strategy that depends on its size. When the minority size is below a critical proportion of the network, homophilic minority interaction decreases minority connectivity. However, if the minority group size is sufficiently large, homophilic minority interaction helps in increasing minority connectivity. In this case, the minority group has proportionally enough individuals to interact with and decrease the disparity between groups. This critical mass allows the minority group to be a strong, tightly connected group; without this critical mass, a stronger minority implies higher inequality. This result is somewhat related to the critical mass for social change, as recently shown34, in which committed groups with size higher than 25% are sufficient to change social conventions.

To summarize, we have investigated numerically, empirically, and analytically the emergence of group inequality in social gatherings. In contrast to previous works, our mechanistic model captures the properties of face-to-face dynamics while reproducing degree inequalities found in empirical data. The model is distinct from network models, such as stochastic block models or Barabási–Albert model, in that we consider the spatiotemporal constraints in social gatherings, which leads to the emergence of fundamental properties in face-to-face interaction. Our approach creates research opportunities to understand face-to-face situations. For example, the model can be used to explore how group mixing affects dynamic processes in social gatherings. Further research will help clarify dynamic aspects of group inequality as well as latent groups in data. Likewise, the spatial aspect of social gatherings will be better understood when richer data containing spatial information is available. Moreover, though we have focused on a binary attribute, our model can also be used to investigate multiple and continuous-valued attributes. In the future, it would also be interesting to empirically estimate the model parameters, such as the activation probability and intrinsic attractiveness, which would enable researchers to understand the role of these individual-level properties in social gatherings.

In this article, we understand the concept of minority quantitatively: A minority group is the smallest group in a social gathering. Nevertheless, in the social sciences, the concept is often associated with the critique of inequality, deprivation, subordination, marginalization, and limited access to power and resources35. Performing a quantitative analysis of the structural mechanisms of mixing, exclusion, and interaction by no means implies ignorance about these issues. This work sheds light on how inequality can emerge from social interaction, building computational opportunities to understand and alleviate disparities in our society.

## Methods

### Group mixing analysis

To characterize how groups mix, we compare the inter- and intragroup edges in data with the configuration model. This approach enables us to assess whether the mixing patterns found in data would occur just by chance. With the configuration model, we generate random networks that preserve the degree of each node in a given network and reshuffle the links, which we can use to compare against the actual data36. For each data set, first, we generate 500 random instances of the network and count the number of edges $${E}_{rs}^{\prime}$$ between groups r and s in each instance; then, we count the actual number of edges Ers in the data; finally, we compare Ers to $${E}_{rs}^{\prime}$$ via z scores, defined as $${z}_{sr}=({E}_{sr}-{\overline{E}}_{sr}^{\prime})/s\,[{E}_{sr}^{\prime}]$$, where $${\overline{E}}_{sr}^{\prime}$$ and $$s\,[{E}_{sr}^{\prime}]$$ are, respectively, the mean and standard deviation of $${{E}^{\prime}}_{sr}$$ over the 500 instances. The z score zsr reveals the number of standard deviations by which Ers differs from the random case (see also Supplementary Note 1).

### Model and simulation analysis

To analyze the symmetrical case of the attractiveness–mixing model, we first simulate the model with different values of hrr and f0 and then measure the average degree of the whole network 〈k〉 and the average group degree of the minority, denoted as 〈k0〉, and majority, 〈k1〉. We compare each group r with the whole network using z scores, defined as (〈kr〉 − 〈k〉)/s[k], where s[k] is the standard deviation of k. In the simulations, we used the following parameters: L = 100, d = 1, v = 1, and N = 200. In the case of the simulations using the data estimates, we run the model until the total number of edges is the same as the number of edges in the data. In all analyses, we average the results over 50 different simulations of our model.

### Analytic derivation of the model

Here we derive the attractiveness–mixing model analytically for the case of two groups, B = 2, denoted as group 0 and group 1. We show that we can calculate the normalized group edge matrix analytically. To simplify the derivation, we assume a situation of low spatial density of agents; thus, almost all situations of potential interaction involve only two individuals, and non-pairwise interactions are negligible (i.e., dilute system hypothesis). Due to the activation process, the average number of active nodes at one time t is $${N}_{a}= < {r}_{i} > N$$, since we do not expect a correlation between ri and the presence of isolated individuals. Therefore, the number of active nodes in each group is N0 = f0Na and N1 = f1Na. We note that the attractiveness–mixing model generates a temporal network in which nodes are the individuals and interactions between them are edges that are created and destroyed as time passes. Let E be the number of edges created during a time step Δt. Since the interaction mechanism is time-independent, the total number of edges in the network after a time T is given by ET = E × Tt.

To express the number of new edges created at time t in each component, first, we focus on edges between two individuals from group 0. The probability p0 to find an individual j from group 0 in the vicinity of individual i relates to the surface of the vicinity and the density ρ0 of individuals from group 0 on the field, expressed by:

$${p}_{0}={\rho }_{0}S=\frac{{N}_{0}}{{L}^{2}}\pi {d}^{2}=\,\frac{{f}_{0}{N}_{a}}{{L}^{2}}\pi {d}^{2}=\,{f}_{0}{\rho }_{a}\pi {d}^{2},$$
(7)

where ρa is the density of active individuals. To have an interaction, both individuals must be available and not move away. In our case, the probability for one individual to be available is the attractiveness of the other individual; thus, the probability of having both is the product ηiηj, whose average value is a constant $$\gamma = < {\eta }_{i}{\eta }_{j} >$$. We note that three situations can lead to the creation of an edge between an individual i and an individual j: (1) only individual i initiates the creation, (2) only individual j initiates the creation, or (3) both individuals initiate the creation. Therefore, the probability for the edge to appear is thus:

$${p}_{ij}={p}_{i\to j}+{p}_{j\to i}+{p}_{i\leftrightarrow j}.$$
(8)

In the case of two individuals from the group 0, this probability is on average:

$$\begin{array}{rc}{p}_{ij,00}&={f}_{0}{\rho }_{a}\pi {d}^{2}\times \gamma \times \left[{h}_{00}(1-{h}_{00})+(1-{h}_{00}){h}_{00}+{h}_{00}^{2}\right]\\ &={f}_{0}{\rho }_{a}\pi {d}^{2}\gamma \left(1-{h}_{01}^{2}\right).\end{array}$$
(9)

Thus, the number of intragroup edges created during one time step for group 0 is:

$${E}_{00}=\frac{{N}_{a}^{2}\pi {d}^{2}}{2{L}^{2}}\gamma {f}_{0}^{2}\left(1-{h}_{01}^{2}\right),$$
(10)

where the 1/2 factor takes into account double counting. With a similar approach, we find that

$${E}_{11}=\frac{{N}_{a}^{2}\pi {d}^{2}}{2{L}^{2}}\gamma {f}_{1}^{2}\left(1-{h}_{10}^{2}\right).$$
(11)

Furthermore, this procedure also enables us to find that

$${E}_{10}=\frac{{N}_{a}^{2}\pi {d}^{2}}{{L}^{2}}\gamma {f}_{1}{f}_{0}\left(1-{h}_{00}{h}_{11}\right)$$
(12)

and

$${E}_{01}=\frac{{N}_{a}^{2}\pi {d}^{2}}{{L}^{2}}\gamma {f}_{0}{f}_{1}\left(1-{h}_{00}{h}_{11}\right),$$
(13)

where the 1/2 factor is not required in these cases because they do not have double-counting. Finally, since E = E00 + E01 + E10 + E11 by definition, the share of intragroup edges for group 0 is given by:

$${e}_{00}=\frac{{E}_{00}}{E}=\frac{{f}_{0}^{2}\left(1-{h}_{01}^{2}\right)}{{f}_{0}^{2}\left(1-{h}_{01}^{2}\right)+2{f}_{0}{f}_{1}\left(1-{h}_{00}{h}_{11}\right)+{f}_{1}^{2}\left(1-{h}_{10}^{2}\right)}.$$
(14)

By following analogous procedure, we can find e11 as written in Eq. (4). In addition, e01 and e10 can be written as

$${e}_{10}={e}_{01}=\frac{{f}_{0}{f}_{1}\left(1-{h}_{00}{h}_{11}\right)}{{f}_{0}^{2}\left(1-{h}_{01}^{2}\right)+2{f}_{0}{f}_{1}\left(1-{h}_{00}{h}_{11}\right)+{f}_{1}^{2}\left(1-{h}_{10}^{2}\right)}.$$
(15)

We verify that these equations predict the model behavior well by comparing them with simulations (see Supplementary Note 4). In order to assess group mixing in empirical data, we use Eq. (4), Eq. (3), and Eq. (15) to estimate h00 and h11 from data via numerical optimization. First, we calculate the empirical share of intra- and intergroup edges in the networks, then we use an optimization algorithm to find the corresponding values for h00 and h11.

## Data availability

The sources of all empirical data used in our analyses are described in Supplementary Note 1.

## Code availability

All relevant code used in this study is available at https://github.com/macoj/face_to_face_minority_dynamics and its respective Zenodo repository37.

## References

1. Goffman, E. Interaction Ritual: Essays On Face-to-face Interaction (Aldine, 1967).

2. Kendon, A., Harris, R. M. & Key, M. R. (eds). Organization of Behavior in Face-to-face Interaction (Mouton Publishers, 1975).

3. Duncan, S. & Fiske, D. W. Face-to-face Interaction: Research, Methods, and Theory (Lawrence Erlbaum Associates, 1977).

4. Bargiela-Chiappini, F. & Haugh, M. (eds). Face, Communication and Social Interaction (Equinox Publishing Ltd, 2009).

5. Finneran, L. & Kelly, M. Social networks and inequality. J. Urban Econ. 53, 282–299 (2003).

6. Calvó-Armengol, A. & Jackson, M. O. The effects of social networks on employment and inequality. Am. Economic Rev. 94, 426–454 (2004).

7. Curran, S. R., Garip, F., Chung, C. Y. & Tangchonlatip, K. Gendered migrant social capital: evidence from Thailand. Soc. Forces 84, 225–255 (2005).

8. DiMaggio, P. & Garip, F. How network externalities can exacerbate intergroup inequality. Am. J. Sociol. 116, 1887–1933 (2011).

9. Stadtfeld, C., Vörös, A., Elmer, T., Boda, Z. & Raabe, I. J. Integration in emerging social networks explains academic failure and success. Proc. Natl Acad. Sci. USA 116, 792–797 (2019).

10. DiMaggio, P. & Garip, F. Network effects and social inequality. Annu. Rev. Sociol. 38, 93–118 (2012).

11. Fournet, J. & Barrat, A. Contact patterns among high school students. PLoS ONE 9, e107878 (2014).

12. Watanabe, J.-i, Ishibashi, N. & Yano, K. Exploring relationship between face-to-face interaction and team performance using wearable sensor badges. PLoS ONE 9, e114681 (2014).

13. Barrat, A. & Cattuto, C. in Social Phenomena 37–57 (Springer International Publishing, 2015).

14. Génois, M., Zens, M., Lechner, C., Rammstedt, B. & Strohmaier, M. Building connections: how scientists meet each other during a conference. Preprint at https://arxiv.org/abs/1901.01182 (2019).

15. Schaible, J., Oliveira, M., Zens, M. & Génois, M. in Handbook of Computational Social Science Vol. 1 (Routledge, 2021).

16. Hui, P. et al. Pocket switched networks and human mobility in conference environments. in Proceeding of the 2005 ACM SIGCOMM Workshop on Delay-tolerant Networking - WDTN ’05, 244–251 (ACM Press, 2005).

17. Salathe, M. et al. A high-resolution human contact network for infectious disease transmission. Proc. Natl Acad. Sci. USA 107, 22020–22025 (2010).

18. Cattuto, C. et al. Dynamics of person-to-person interactions from distributed RFID sensor networks. PLoS ONE 5, 1–9 (2010).

19. Stehlé, J. et al. High-resolution measurements of face-to-face contact patterns in a primary school. PLoS ONE 6, e23176 (2011).

20. Takaguchi, T., Nakamura, M., Sato, N., Yano, K. & Masuda, N. Predictability of conversation partners. Phys. Rev. X 1, 011008 (2011).

21. Isella, L. et al. What’s in a crowd? Analysis of face-to-face behavioral networks. J. Theor. Biol. 271, 166–180 (2011).

22. Zhao, K., Stehlé, J., Bianconi, G. & Barrat, A. Social network dynamics of face-to-face interactions. Phys. Rev. E 83, 056109 (2011).

23. Starnini, M., Baronchelli, A. & Pastor-Satorras, R. Modeling human dynamics of face-to-face interaction networks. Phys. Rev. Lett. 110, 1–5 (2013).

24. Zhang, Y.-Q., Cui, J., Zhang, S.-M., Zhang, Q. & Li, X. Modelling temporal networks of human face-to-face contacts with public activity and individual reachability. Eur. Phys. J. B 89, 26 (2016).

25. Flores, M. A. R. & Papadopoulos, F. Similarity forces and recurrent components in human face-to-face interaction networks. Phys. Rev. Lett. 121, 1–23 (2018).

26. Karimi, F., Génois, M., Wagner, C., Singer, P. & Strohmaier, M. Homophily influences ranking of minorities in social networks. Sci. Rep. 8, 11077 (2018).

27. McDonald, S. What’s in the “old boys” network? Accessing social capital in gendered and racialized networks. Soc. Netw. 33, 317–330 (2011).

28. Haas, S. A., Schaefer, D. R. & Kornienko, O. Health and the structure of adolescent social networks. J. Health Soc. Behav. 51, 424–439 (2010).

29. Lee, E. et al. Homophily and minority-group size explain perception biases in social networks. Nat. Hum. Behav. 3, 1078–1087 (2019).

30. SocioPatterns. http://www.sociopatterns.org/ (2022).

31. Mastrandrea, R., Fournet, J. & Barrat, A. Contact patterns in a high school: a comparison between data collected using wearable sensors, contact diaries and friendship surveys. PLoS ONE 10, e0136497 (2015).

32. Tajfel, H. Social Identity and Intergroup Relations Vol. 7 (Cambridge University Press, 2010).

33. McPherson, J. M. & Smith-Lovin, L. Homophily in voluntary organizations: Status distance and the composition of face-to-face groups. Am. Sociol. Rev. 52, 370–379 (1987).

34. Centola, D., Becker, J., Brackbill, D. & Baronchelli, A. Experimental evidence for tipping points in social convention. Science 360, 1116–1119 (2018).

35. Van Amersfoort, H. ‘Minority’ as a sociological concept. Ethn. Racial Stud. 1, 218–234 (1978).

36. Maslov, S. & Sneppen, K. Specificity and stability in topology of protein networks. Science 296, 910–913 (2002).

37. Oliveira, M. et al. Group mixing drives inequality in face-to-face gatherings. https://doi.org/10.5281/zenodo.6394477 (2022).

## Acknowledgements

We thank Lisette Espín-Noboa, Haiko Lietz, Diego Pinheiro, and Diogo Pacheco for helpful feedback on the manuscript. Fariba Karimi was supported by the Austrian research agency (FFG) (project number 873927).

## Author information

Authors

### Contributions

M.O. and F.K. proposed the core idea of the project. M.O., F.K., M.Z., J.S., M.G., and M.S. contributed to the scientific discussions of the work. M.O. wrote code and analyzed numerical and empirical data. M.O., F.K., and M.G. carried out the analytical analysis. M.O. wrote the first draft, and F.K., M.Z., and M.G. reviewed the first draft. All authors reviewed the final manuscript.

### Corresponding authors

Correspondence to Marcos Oliveira or Fariba Karimi.

## Ethics declarations

### Competing interests

The authors declare no competing interests.

## Peer review

### Peer review information

Communications Physics thanks Marco Antonio Rodriguez Flores, Rui Luo and the other, anonymous, reviewer(s) for their contribution to the peer review of this work. Peer reviewer reports are available.

Publisher’s note Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.

## Rights and permissions

Reprints and Permissions

Oliveira, M., Karimi, F., Zens, M. et al. Group mixing drives inequality in face-to-face gatherings. Commun Phys 5, 127 (2022). https://doi.org/10.1038/s42005-022-00896-1

• Accepted:

• Published:

• DOI: https://doi.org/10.1038/s42005-022-00896-1

By submitting a comment you agree to abide by our Terms and Community Guidelines. If you find something abusive or that does not comply with our terms or guidelines please flag it as inappropriate.