TL;DR
Preferential attachment is a growth rule for a Graph (a set of nodes joined by links). Each new node adds its links to existing nodes, and it picks a node with probability proportional to how many links that node already has. Nodes that are well connected attract more links, so they grow faster than the rest. Over time this produces a few very large hubs and a long tail of nodes with few links, which is a Power Law degree distribution. The degree of a node is simply its number of links.
This is not the same as a random network such as the Erdős–Rényi random graph. In a random network every node has about the same chance of being linked to, so the degrees stay bunched around their average.
Where you'll see it: in models of citation networks, where a well-cited paper gets noticed and cited more, in the link structure of the web, and in models of social and collaboration networks where popular people attract new contacts.
Intuition
The rich get richer
Think of a new student arriving at a school and choosing whom to befriend. Suppose they pick one classmate at random, with each classmate equally likely. Now suppose instead they are more likely to pick a classmate who already has many friends, because those people are easier to meet and more visible. The second rule is preferential attachment. Nobody planned it, but the popular kids keep getting more popular.
The idea is old. Economists and statisticians noticed the same pattern in income and in the sizes of cities and species groups long before networks were studied, and they often called it cumulative advantage. A small early lead compounds, because the lead itself attracts the next step.
Why the rule matters
If you grow a network by picking targets uniformly at random, the degrees come out roughly Poisson (a bell-shaped spread with a tail that dies off exponentially): most nodes have about the average number of links, and a node with ten times the average is almost impossible. If you grow it with preferential attachment, the degrees have a heavy tail. A few hubs have very many links, and the typical node has only a few. The difference is not in the number of links, but in who gets them.
- preferential attachment, 2/k^3
- random growth, decays fast
The curves above are shapes, not fitted to data. The point to notice is the slow decay: under preferential attachment a node with degree 10 is still common enough to appear, while under fast decay it is not.
flowchart LR A[New node arrives] --> B[Pick an old node with probability proportional to its degree] B --> C[Add a link] C --> D[Hubs grow] D --> B
The math
The model
Barabási and Albert proposed the model in 1999. Start with a small network. At each time step, add one new node with links, and connect each of its links to an existing node with probability
where is the current degree of node , and the sum runs over all existing nodes . The denominator is the total degree, which equals twice the number of links. So the probabilities always add to 1.
Growth of one node
Let the network have nodes. Node was added at time , and its degree grows over time. In the continuum approximation we treat as smooth. Each new node adds links in total, and the total degree of the network is . So the chance that the next arrival links to node is . The degree grows at that rate:
This is a simple differential equation. Its solution, starting from , is
Interpretation: a node added early (small ) has a large degree. A node added at the very start grows like the square root of the network size.
The degree distribution
Nodes arrive uniformly over time, so the fraction of nodes with is . A node has degree at least when , which is the same as . So the fraction of nodes with degree at least is
The probability density is the negative derivative of this cumulative form:
This is a power law with exponent . The exponent does not depend on . Compare this with the random network, where falls off exponentially.
Worked examples
Start with two nodes and , joined by one link, so and each has degree 1. The total degree is 2.
- Add node . It makes one link. It attaches to with probability and to with probability . Say it picks . Now , , , and the total degree is 4.
- Add node . The probabilities are now , and . Say picks again. Now .
- Check the sum. The degrees are , which equals links. The count is right.
Interpretation: after two arrivals, holds 3 of the 6 link ends in the network, three times the degree of each other node. One early choice compounded.
Take . Node was added when the network had nodes. Now the network has nodes. What is its degree?
- Use the growth formula .
- Compute the ratio .
- Take the square root. .
- Multiply by . .
Interpretation: a node that arrived early (at the 10th step) ends with 20 links, while a node that arrived at the 1000th step has only links. The early node is ten times as connected because it had a hundred times more time to attract arrivals, and the square root turns that into a factor of ten.
Take . Use the cumulative form from The math.
- Fraction of nodes with degree at least 30. . So about 1 node in 100 has degree 30 or more.
- Fraction with degree at least 300. . So about 1 node in 10,000 has degree 300 or more.
- Compare the ratio. Going from 30 to 300 multiplies the degree by 10, and divides the tail fraction by , which is the exponent 2 on the cumulative tail.
- Exact density at degree 30. .
Interpretation: in a network of a million nodes, about ten thousand would have degree 30 or more, and about a hundred would have degree 300 or more. A random network of the same size and average degree would have essentially none at degree 300. The model values here are analytic, from the continuum approximation; real networks need to be fitted and tested, as the degree distribution lesson explains.
Tradeoffs and failure modes
Preferential attachment explains one mechanism that produces hubs. It is a useful baseline, not a complete description of every network.
| Situation | What goes wrong | Better choice |
|---|---|---|
| Real data has a cutoff at large degrees | The model's pure power law has no cutoff, so it overstates the largest hubs | Add a fitness term or a node-aging term to the rule |
| Links are added and also removed | The growth-only model misses the balance of arrivals and departures | Models with rewiring or deletion |
| The data shows a tail but is not a power law | A straight line on a log-log plot is not enough evidence | Test the fit as in Clauset, Shalizi and Newman (2009) |
| Only the average degree matters | Two networks with equal averages can look very different | Compare the full degree distribution |
The model is simple, so it can be made to fit many things. Be careful when a model explains a feature that you chose to look at, and check it against a second feature the model did not use.
History
Herbert Simon described a rich-get-richer process in the 1950s, in work on skewed distributions of word frequencies and city sizes, and Derek de Solla Price had described cumulative advantage in the citation networks of scientific papers in the 1960s and 1970s. Both were working on how popularity compounds in populations, not on networks as graphs.
In 1999 Albert-László Barabási and Réka Albert put the rule into a growing network model and showed that it produces a power-law degree distribution with exponent close to 3. Their paper in Science made the model the standard reference for scale-free networks (networks whose degree distribution is a power law), and it started a large body of work on how to test such models against real data.
Recap
A network that grows by linking new nodes to old nodes in proportion to their degree develops hubs. The degree of a node grows like the square root of the ratio of network sizes, which gives a cumulative tail of and a density . The power law is a result of the rule, not an assumption. This is the reason the degree distribution of many real networks has a heavy tail.
Check yourself
QuestionIn the model, a new node links to an existing node with probability proportional to its degree. Why does the total of these probabilities add up to 1 without any extra normalising step?Show answer
The denominator is the sum of all degrees, , so dividing each degree by it gives probabilities that add to 1 by construction. The sum of the degrees is twice the number of links, so the denominator is just a count of the link ends in the network.
QuestionA node is added when the network has 4 nodes. The network later grows to 400 nodes. With , what is the degree of that node?Show answer
Use . The node has 10 links.
QuestionWhy does a random network with the same average degree have almost no hubs, while the preferential-attachment network does?Show answer
In the random network each node is equally likely to be chosen, so degrees stay close to the average and fall off quickly. In the preferential-attachment network the chance of getting a new link grows with the current degree, so a node that gets ahead keeps getting ahead. The growth is multiplicative, which gives a heavy tail.
QuestionA data set's degree histogram is a straight line on a log-log plot. Does that prove the network was built by preferential attachment? Explain.Show answer
No. Many different mechanisms produce heavy tails, and a straight line on a log-log plot is consistent with several of them. A proper test compares the power-law fit with alternative distributions, estimates the tail range, and checks other features of the network, as in Clauset, Shalizi and Newman (2009).
QuestionWith , a node added at the 50th step of a network that now has 5000 nodes. Compute its degree and the fraction of all nodes with degree at least that value.Show answer
The ratio is , so . The fraction of nodes with degree at least 20 is , about 1 node in 100.
Sources
- Barabási and Albert, Emergence of Scaling in Random Networks, Science (1999): https://doi.org/10.1126/science.286.5439.509
- Preferential attachment (Wikipedia): https://en.wikipedia.org/wiki/Preferential_attachment
- Clauset, Shalizi and Newman, Power-Law Distributions in Empirical Data (2009): https://doi.org/10.1137/070710111