Implement simulator run function