Changed the algorithm to do the stacking. In simulation, the call to a property is slower then a call to a class field or a local variable.