A flexible, all-purpose curve-fitting program