### Model Descriptions

We used NetLogo to simulate the impact of economic freedom and equality on controlling the COVID-19 pandemic. The spread of COVID-19 in the population is considered consistent with the SEIRD model [35]. “S” refers to susceptible, which is not infected and can become infected after contact with an infected person. “E” refers to the exhibit, who was infected with COVID-19 but did not fall ill. “I” refers to the sick, showing symptoms. ‘R’ refers to Recovered. People who have recovered will no longer be infected with COVID-19, nor will they be contagious. Finally, ‘D’ refers to the Dead. Different SEIRD states are represented by different agent colors in the model. Transitions between states are probability events. An agent representing a susceptible individual has three possible outcomes (uninfected, recovered from infection, and dead) to describe the different outcomes of individuals in the real world. Various agents move around in a simulated environment. When the susceptible has intensive contact with the exposed or ill, the susceptible can become the exposed, thus entering the incubation period and beginning to have the ability to infect other susceptible agents. After the incubation period, the Exposed enter the appearing period and become the Diseased. The onset period refers to the time between the onset of illness and recovery or death. The sick person can become cured or dead at the end of the onset period.

In constructing the SEIRD model of COVID-19, we considered the embodiment of economic freedom and equality in the model. According to the results of the aforementioned real-world study, economic freedom has a positive effect on the speed of controlling the COVID-19 pandemic, and this positive effect depends on high equality. Since different individuals in society have unequal possession of resources (such as wealth) and countries with high economic freedom can efficiently allocate resources during a crisis, we chose resources as the starting point for modeling. Resources are embodied by all the attributes that help protect agents from harm. For example, agents with high resources tend to be less likely to be infected, receive more treatment after infection, and are less likely to die. Before the pandemic, the initial resources occupied by individuals in society basically followed a normal distribution, showing some gap between rich and poor. To distinguish countries with different resource equalities, we choose to keep the same mean of the normal distribution and modify the standard deviation. The larger the standard deviation, the greater the gap between rich and poor in the country. The reason for controlling the same mean is that the goal of the manipulation is the degree of equality of society rather than the degree of wealth. Economic freedom is reflected in the rate at which the total available resources are allocated to all agents during the simulation.

### Rules of behavior

Among the simulations of COVID-19, the agents maintain their behaviors which are characterized by six simple rules and influenced by all the interaction between them (see details in supplementary materials). The six rules apply to all agents and occur in order (Figs. S5-S6).

### First rule: move

Agent travel behavior rules refer to Cuevas settings [36]. Cuevas postulated that the movement of individuals in the context of COVID-19 is probabilistic behavior. The probability of staying put must be greater than the probability of walking around, and the probability of moving short distances must be greater than the probability of moving long distances. The daily probability of movement for all agents obeys a uniform distribution: *P*_{Moving}~U(0.2, 0.4).

### Rule two: infect

In Gharakhanlou & Hooshangi’s space-time simulation for COVID-19 infection [37]they fix the number of days of incubation as a parameter obeying a normal law: Incubation∼ N(8, 2^{2}) We follow their approach and give the same incubation period to yellow agents that represented an infected state. The trigger condition for green agents to be infected by infected agents is close contact. Taking the position of a green agent as the center and in a circle with a radius of 1 unit, if there is an infected agent, then the green agent will enter the judgment if infected. The probability of being infected follows a normal distribution whose mean and standard deviation are related to CumuResource and Inequality, namely:

$$ left{begin{array}{c}mu =left(-0.002times mathrm{CumuResource}+0.1right)times left(-0.1times mathrm{Inequality}+1.5 right)+0.2 {}sigma =frac{left(-0.002times mathrm{CumuResource}+0.1right)times left(-0.1times mathrm{Inequality}+1.5right )+0.2}{10} {}{P}_{mathrm{BeingInfected}}sim mathrm{N}left(mu, {sigma}^2right)end{array} to the right. $$

CumuResource influences the probability of infection, suggesting that agents with high cumulative resources are less likely to be infected. Inequality modifies the impact of CumuResource on the probability of being infected. *P*_{get infected} in our simulation refers to the practice of Cuevas [36], which sets the probability of being infected between 0.1 and 0.3. After being deemed infected, a green agent will change to a yellow agent representing an infected state and enter the incubation period.

### Rule three: be detected

Rule three simulates the process of detecting infected agents, where detection is a likely event and will be affected by CumuResource. Each yellow agent can be detected every day during its incubation period. The detection formula is: *P*_{be detected}= 0.00998 × CumuResource + 0.001 Once detected, the corresponding yellow agent will turn purple, which means that as a known infected agent, it will receive a slightly higher allocation proportion than the yellow agent in resource allocation (see rule six). Purple Agents continue to pass the incubation period and infect Green Agents just as Yellow Agents do.

### Fourth rule: get sick

Khalili et al. conducted a meta-analysis of studies describing the epidemiological characteristics of COVID-19 published between December 1, 2019 and March 1, 2020 [38]. The fourth rule takes real-world statistics and uses them in our simulation. Yellow agents and purple agents at the end of the incubation period will make a judgment to distinguish whether the end result is healing or death. The formula to execute is: *P*_{Pass away}= − 0.0004 × CumuResource + 0.041. When a fatal event occurs, the yellow/purple agent turns red, indicating that it is in the beginning period, and its end result is death. The period of appearance of red agents obeys the normal distribution, which is expressed by the formula: ( mathrm{Start}sim mathrm{N}left(0.02times mathrm{CumuResource}+15,{left(frac{0.02times mathrm{CumuResource}+15}{10} right)}^2right) ) This reflects the fact that economically superior individuals in the real world may take more forms of treatment when the disease is severe and achieve the outcome of death later. When a death event does not occur, the agent that has passed the incubation period turns orange, meaning its end result is recovery. The appearance period of Agent Orange also obeys the normal distribution:

$$ mathrm{Start}sim mathrm{N}left(-0.02times mathrm{CumuResource}+19.5,{left(frac{-0.02times mathrm{CumuResource}+19.5}{10 }right)}^2right) $$

Such a framework reflects the fact that economically advantaged people can benefit from more and better treatments and achieve faster recovery.

### Rule 5: display results

Red and orange agents will enter different states after the start period. Red agents will turn white, representing the state of death. Agents white will not perform the Rule 1 movement or Rule 6 resource allocation. Agents Orange will finally turn blue, a state denoting recovery. Blue agents represent individuals who acquired antibodies after recovering from COVID-19; thus, they will no longer be infected.

### Rule Six: Allocate Resources

A society with high economic freedom has high resource allocation capabilities and can provide a large amount of resources for supply in a short time. [8, 9]. In this study, the economic freedom in the model is reflected in the speed of resource allocation provided that the total amount of resources remains equal. The purpose of controlling the total amount of resources is to distinguish between high and low economic freedom, rather than large and small amount of overall resources. Economic freedom is expressed by the number of days allocated to resources (EconomicNotFreedom = {200,500}). Faster resource allocation speed means more resources available per day. As a result, the average amount of resources that can be allocated per day is: ( mathrm{ResourcePerDay}=frac{mathrm{TotalResource}}{mathrm{EconomicNotFreedom}} )Resources are then allocated to the different agents according to two principles: the first is the principle of demand, and the second is the principle of inequality. Agents in different states have different resource demands; thus, we use *r* to represent their allocation weight in the resource allocation process. The principle of inequality is represented by the Matthew effect. Wealth or resource-based benefits will be further enhanced; that is, the rich get richer and the poor get poorer. Agents with higher initial resources will be allocated more resources each day. Therefore, we first calculate the relationship between the unit resources of the total initial resources and the daily available resources and allocate the resources to the agents based on their initial resources and their weights. The relationship is as follows:

$$ mathrm{ResourcePerInitial}=frac{mathrm{ResourcePerDay}}{sum {mathrm{InitialResource}}_{

The cumulative resources of an agent on day n+1 are:

$$ {mathrm{CumuResource}}_{nkern0.5em +kern0.5em 1}={mathrm{CumuResource}}_n+mathrm{ResourcePerInitial}times mathrm{InitialResource}times kern0.5em r$$

### Analytical techniques

Economic freedom was high when EconomicNotFreedom was set to 200, and economic freedom was low when EconomicNotFreedom was set to 500. Equality was high when inequality was set to 5, and equality was low when inequality was set to 10. This study focused on the speed of fighting the pandemic. Consistent with real-world study treatments, the overall rate of control is obtained by adjusting the cumulative number of infected agents over time. Next, we calculate the stage 1 control speed and the stage 2 control speed based on the turn of the pandemic control. We used interval estimation (95% confidence interval, 95% CI) of dependent variable values under different conditions to reveal whether the effect existed. Non-overlapping confidence intervals imply statistical significance (at the 0.05 level).