Updated grad_bdry()