## 1. Introduction

The Friendship paradox on Wikipedia states that most people have fewer friends than their friends have, on average. This fills in a few of the steps of their derivation of this result.

## 2. Derivation

A social network is a graph, $$G=(V,E)$$. A node has degree, $$d(v)$$.

The average number of friends (direct neighbors), μ, of a randomly chosen person (node) in the graph is:

$$\mu = \frac{\sum_{v\epsilon V} d(v)}{\lvert V\rvert} = \frac{2\lvert E\rvert}{\lvert V\rvert} = E[d(v)]$$

The sum of the number of degrees over all nodes is the same as twice the number of edges, because each edge is counted twice, once for each direction.

They then state that

$$\frac{\sum_{v\epsilon V} d(v)^2}{2\lvert E\rvert} = \mu + \frac{\sigma^2}{\mu} \label{result}$$

where σ is the variance of $$d(v)$$.

Using the definition of the variance,

$$\sigma = E[(d(v) - E(d(v)))^2] = E[(d(v) - \mu)^2]$$

$= E[d^2(v) - 2\mu^2 + \mu^2] = E[d^2(v)] - \mu^2$

Therefore,

$$E[d^2(v)] = \mu^2 + \sigma$$

Also,

$$E[d^2(v)] = \frac{1}{\lvert V\rvert}\sum_{v\epsilon V} d(v)^2$$

So,

$$(\mu^2 + \sigma)\lvert V\rvert = \sum_{v\epsilon V} d(v)^2$$

To derive equation \eqref{result},

$\frac{\sum_{v\epsilon V} d(v)^2}{2\lvert E\rvert} = \frac{(\sigma^2 + \mu^2)\lvert V\rvert}{2\lvert E\rvert}$ (by 6)

$= \frac{1}{\mu}(\sigma^2 + \mu^2)$ (because $$2\lvert E\rvert = \mu\lvert V\rvert$$)

$= \frac{\sigma^2}{\mu} + \mu$

Date: 2016-04-03 Sun