Missions to asteroids have been the trend in space exploration for the last years. They provide information about the formation and evolution of the Solar System, contribute to direct planetary defense tasks, and could be potentially exploited for resource mining. Be their purpose as it may, the factor that all these mission types have in common is the challenging dynamical environment they have to deal with. The gravitational environment of a certain asteroid is most of the times not accurately known until very late mission phases when the spacecraft has already orbited the body for some time.
Shape models help to estimate the gravitational potential with a density distribution assumption (usually constant value) and some optical measurements of the body. These measurements, unlike the ones needed for harmonic coefficient estimation, can be taken from well before arriving at the asteroid’s sphere of influence, which allows to obtain a better approximation of the gravitational dynamics much sooner. The disadvantage they pose is that obtaining acceleration values from these models implies a heavy computational burden on the on-board processing unit, which is very often too time-consuming for the mission profile.
In this paper, the technique developed on  is used to create a validated Python-based tool that obtains spherical harmonic coefficients from the shape model of an asteroid or comet, given a certain density for the body. This validated software suite, called AstroHarm, is used to analyse the accuracy of the models obtained and the improvements in computational efficiency in a simulated spacecraft orbiting a small body.
The results obtained are shown offering a qualitative comparison between different order spherical harmonic models and the original shape model. Finally, the creation of a catalogue for harmonics is proposed together with some thoughts on complex modelling using this tool.