The theory of population dynamics: back to first principles