Modelling the ATP production in mitochondria