In addition to teaching introductory physics courses (both conceptual and technical), I have the privilege of teaching conceptual astronomy. One of the topics that arises early in the course is the Celestial Sphere, which provides a simple framework for describing the motions of objects through the heavens. In order to represent the heavens somewhat accurately, I needed a source of data describing the positions of the stars. The Bright Star Catalog (BSC) came to my rescue!
The BSC is essentially a directory listing of the visible stars in our sky. It can be found on the internet in a number of places, such as the Smithsonian Astrophysical Observatory Telescope Data Center and the Centre de Données astronomiques de Strasbourg.
There is quite a bit of information for each star in the BSC, most importantly each star's coordinates (right ascension and declination), visual magnitude (apparent brightness) and parallax angle (a measure of distance). The BSC data file has some handy documentation which describes how the ASCII data file is set up. With the help of a quick and dirty spreadsheet and some text file editing, the desired subset of data was converted into something more easily digested by POV-Ray. For convenience, the final data file was sorted by the visual magnitude of the stars, to make it easier to plot only the brightest of stars.
I also wanted to include constellation lines in the visual depiction of the sky. After a bit of internet sleuthing I found Starchart, an open source sky charting program, which also used the BSC and had a similar data file for constellations. A little spreadsheet magic and final editing yielded a constellation data file for use with the BSC.
POV-Ray uses its own scene description language in which objects are easily described via geometric primitives and Constructive Solid Geometry. In my animations, I simply place a sphere at a set distance from the center of the scene (or a distance inversely scaled by the star's parallax angle) at a location determined by the star's right ascension and declination. The size and brightness of the sphere is determined by the star's apparent magnitude. Constellation lines are created by placing cylinders which go from specified point to specified point on the celestial sphere, as determined from Starchart's constellation data file. The complete set of source files for the image at the top of this page can be found in this zip file.
On of the first animations I made using this data was a portrayal of the Celestial Sphere, illustrating how the rotation of this imaginary sphere gave a mechanical description of the apparent daily motion of the objects in the heavens: