Stack renumbering

when adding or deleting stacks, stacks are renumbered