divided differences function