Performance increases in simulations - remove the evil loops