Even though this is not what this article is about, quite a few comments suggest better ways to compute the midpoint of two doubles, where "better" is supposed to mean "such that unnecessary overflow is avoided".
What I haven't seen is the suggestion
0.5*x + 0.5*y
Yes, we now have two multiplications, but floating point multiplication is considerably faster than division.