improved the simulator classe