HP 50g Program MPFIT towards the end of the blog entry, enjoy!
http://edspi31415.blogspot.com/2013/01/length-of-polynomial-segment-part-1-and.html?m=0
Cool program!
:-)
Namir