Computing homelands