Theory of surface stress and surface reconstruction