An approach to the simulation of a batch-respirometer