Utility.
Utility and bug fix for midpoint.
Example updates.