The entire enterprise of determining the orbits of planets, asteroids and comets is quite a large one, involving several stages. New asteroids and comets have to be searched for and discovered. Known bodies have to be found, which may be relatively easy if they have been frequently observed, or rather more difficult if they have not been observed for several years. Once located, images have to be obtained, and these have to be measured and the measurements converted to usable data, namely right ascension and declination. From the available observations, the orbit of the body has to be determined; in particular we have to determine the orbital elements, a set of parameters that describe the orbit. For a new body, one determines preliminary elements from the initial few observations that have been obtained. As more observations are accumulated, so will the calculated preliminary elements. After all observations (at least for a single opposition) have been obtained and no further observations are expected at that opposition, a definitive orbit can be computed. Whether one uses the preliminary orbit or the definitive orbit, one then has to compute an ephemeris (plural: ephemerides); that is to say a day-to-day prediction of its position (right ascension and declination) in the sky. Calculating an ephemeris from the orbital elements is the subject of this chapter. Determining the orbital elements from the observations is a rather more difficult calculation, and will be the subject of a later chapter.