Towards a mathematical theory of complex biological systems