Ab initio study of hydrogen on beryllium surfaces