The general analytic solution of a functional equation of addition type