  Since the original work of Hansen and Tisserand in the XIXth century, there
have been many variations in the analytical expansion of the three-body
disturbing function in series of the semi-major axis ratio. With the increasing
number of planetary systems of large eccentricity, these expansions are even
more interesting as they allow us to obtain for the secular systems finite
expressions that are valid for all eccentricities and inclinations. We
revisited the derivation of the disturbing function in Legendre polynomial,
with a special focus on the secular system. We provide here expressions of the
disturbing function for the planar and spatial case at any order with respect
to the ratio of the semi-major axes. Moreover, for orders in the ratio of
semi-major axis up to ten in the planar case and five in the spatial case, we
provide explicit expansions of the secular system, and simple algorithms with
minimal computation to extend this to higher order, as well as the algorithms
for the computation of non secular terms.
