A modern approach to economic analysis is agent based modeling.
It assumes that behavior of an economic system is determined by interactions between a number of agents, each of whom optimizes their actions based on limited information about their local environment.
Good example of this approach is Robert Axtell's model of the labor market. In this model, agents are employees of private firms. Each agent regularly collects information about other firms from their small social network with the purpose to choose the best firm for the next employment. Each agent's choice between staying at their present firm and switching to a new one is based on optimization of an individual criterion balancing agent's willingness to work with compensation received. Performance of a firm (and employee compensation) depends nonlinearly on the number of employees, meaning that every agent's move between firms affects the entire system.
Starting from a random state, the system eventually reaches a dynamic equilibrium where the distribution of firms over number of employees fluctuates around a stable pattern. By adjusting variation ranges of a handful of the model parameters, one can reproduce many statistical properties of real labor markets.
With our software we implemented Axtell's model for roughly 132 million agents, the number of employees in the American labor market at the time. The animation below shows how the system evolves from the initial state with one agent per firm to a dynamic equilibrium with a power law distribution of firm sizes over a number of employees.