looks like you grabbed that math from ComputeMipLevel instead of just showing the ComputeMipLevel material function being used. Any particular reason, was there a problem with the function by default?
fwiw, computemip gives you only bilinear filtering which will never look quite as good as either trilinear or anisotropic. So you will see feint seams between the mip levels. For water which is usually viewed right along the surface this may pose a quality issue.