Cleaned up. Create global minIncrement instead of local. Updated doc.