flush data after each simulation

Flushing data after each simulation updates the filesize.