refactored increment to break out and clarify algo