First principle calculations study of AlN surface terminal structure evolution under different conditions