## The AM-GM inequality:

If we let $$\{a_i\}_{i=1}^n \subset \mathbb{R_{+}}$$, then

$$\frac{1}{n} \sum_{i=1}^n a_i \geq \big(\prod_{i=1}^n a_i \big)^{\frac{1}{n}}$$

## Proof using Lagrange multipliers:

Given that (1) is homogeneous, we may de-homogenise it by assuming that:

$$\sum_{i=1}^n a_i = n$$

without loss of generality.

Our inequality to be proven now becomes:

$$\prod_{i=1}^n a_i \leq 1$$

with the constraint:

$$\sum_{i=1}^n a_i = n$$

We may now approach this as an optimisation problem:

$$\max \prod_{i=1}^n a_i$$

with the constraint:

$$\sum_{i=1}^n a_i - n = 0$$

which leads to the Lagrange multiplier:

$$\mathcal{L}(\vec{a}, \lambda) = \prod_{i=1}^n a_i - \lambda \big(\sum_{i=1}^n a_i - n \big)$$

This leads to the variations:

$$\frac{\partial \mathcal{L}}{\partial a_i} = \frac{\prod_{i=1}^n a_i}{a_i} - \lambda = 0$$

$$\frac{\partial \mathcal{L}}{\partial \lambda} = \sum_{i=1}^n a_i - n = 0$$

The first variation (8) leads us to the conclusion that (5) is maximised when:

$$\forall i,j, a_i = a_j$$

and the second variation (9) tells us that (10) must satisfy:

$$\forall i, a_i = 1$$

It follows that:

$$\big(\prod_{i=1}^n a_i \big)^{\frac{1}{n}} \leq 1$$

and therefore:

$$\prod_{i=1}^n a_i \leq \frac{1}{n} \sum_{i=1}^n a_i$$

QED.