This section discusses file formats used by the programs.
Each line of file contains:
Magnitude is encoded into three fields as follows: the first character may be a `-', in which case the next two characters are the magnitude times 10, e.g. `-16' means `-1.6'. The first character is a digit, the three characters are the magnitude times 100, e.g. `563' means `5.63'. Finally, if the first character is a capital letter, this is taken as the base-36 value of the integral part of the magnitude, and the remaining two characters are the fractional part times 100, e.g. `B34' means `11.34'.
The Bayer letter or Flamsteed numbers are applicable only to stars. The field is two characters wide. Greek letters are a single lowercase letter followed by a space or a number, encoded as in the PostScript Symbol font:
the original definitions, which were @, E, 0, x, and % respectively.
An uppercase letter followed by any character or two non-numeric characters is the roman letter designation for the star, e.g. `CY'. Two numbers or a space and a number is the Flamsteed number of the star.
The size of nonstellar objects is encoded in seconds of arc in the size field to two significant digits. The second character is always a decimal digit. Sizes from 0 to 99 arc seconds are encoded as two decimal digits. For larger objects the first character is a capital letter, interpreted as follows, with the second character as the next digit:
The types and subtypes implemented are:
The magnitude of an object determines what information is displayed. Three magnitude limits are defined for each file in each map window. If the magnitude is greater (dimmer) than the first limit, nothing is drawn. If the object is brighter than a second limit, the label (Bayer or Flamsteed) is printed (if present). If it is brighter than the third limit, the name is printed (if present; if not, the label is printed if present). These text strings generally appear to the right of the object, but the driver can change this. Note: the label string only applies to stars.
For nonstellar objects, the label field defines the size of the object in arc seconds.
For magnitudes within a range defined for the mapwindow, a magnitude tag, the magnitude to one decimal place as in variable star and asteroid finding charts, may be displayed. This will generally be below and to the right of the object, but this is controlled by the driver.
The symbol drawn for the object is determined by the type field.
For devices supporting color, the spectral class or color field defines the color of the object, and perhaps the associated text. The spectral class of stars is mapped to display color, and for other objects, this field may contain direct color specifications, e.g. 'r3' for an object colored red level 3. All this is controlled by the device driver. Standards for color definitions are yet to be defined.
The constellation field is not currently used in the display.
The comment field is also not generally used, but some drivers may use it to contain special information such as the phase of the moon or position angle of a comet's tail.
This text format, called lineread, is the original data file format. Data for each object is on a single line, stored in character fields. Currently, an older variant is also supported, one which has 4 characters for the magnitude and omits the color and letter/number fields. Both of these formats are designated as type lineread, since each line is read individually and these two types are easily distinguished on a line by line basis. In all formats, if a value is unknown, it should be spaces, or a null string in the case of the name and comment fields. The RA, DEC and mag. must always be provided for an object.
Since it is a text format, it may be mailed safely and be used on many different computer architectures without change. However, it is slow, and uses more file space than it ought.
The sif format was introduced to allow data to be exchanged as text, with greater precision in the location and magnitude fields, and greater readability compared to the lineread format. The format is too slow for use as input to the starchart programs. A data conversion program is provided to convert between formats, and to precess coordinates during the conversion.
Each object is represented by a single line in the file. This line contains fields each of which corresponds to a field in the lineread format. The fields are separated by a single character, usually `;'. Fields may be omitted from the end of the line; omitted fields are assigned their default values. Fields may be empty, and again are assigned their default values. As with the other formats, the RA, DEC, and mag. must be present.
The RA may be given as a decimal hour, hour and decimal minute, or hour minute and decimal second. The DEC may be given in the same format. The magnitude is a floating point number.
The type, and color, fields are empty or one or two characters, as in the lineread format.
The label field is also the same as in the lineread format, and encodes the size of non-stellar objects in two characters. There is a bit of "magic" in this field. Since `X ' or ` X' are both valid, and whitespace is normally ignored, iff this field is two characters wide, and both characters are printing characters, it is taken verbatim as the label field. That is, `... ; X; ...' is ` X', while `... ; X ; ...' is read as one character and left justified to become `X '.
The constellation field is the IAU abbreviation for the constellation and is always blank or three characters.
The name and comment are two separate fields. Commas should not be used in the name field, since when this name is placed in the other formats a comma is used to separate the name from comments.
Three binary input formats are supported. These formats provide greater position and magnitude accuracy, with faster input, and varying degrees of storage space reduction. The files are inherently unportable, however, and should not be exchanged between machines and operating systems, or even different compilers. The sif format, described above, provides a general data exchange format.
The three formats provide different storage sizes. The most general format, which contains all the data in the lineread format, is the binfull format. A smaller format, binobj stores only the RA, DEC, mag. and object type fields, all other fields become their defaults (usually spaces). The smallest format, binstar stores only the RA, DEC and mag., all other fields become their defaults, notably the object type is `SS'.
The binary formats are described as C structures. How the data in the structure is stored is therefore highly variable between compilers, operating systems and machines. However, most machines should be able to take advantage of these formats for local storage.
The Hubble Space Telescope Guide Star Catalog, available on 2 CD-ROMs,
may be used as a stellar database. This format may be read by
dataconv and the starchart programs, but now written. An index
file is used to specify which files on which CD-ROM should be read.
The indextype file is a special file format added to support larger databases of dimmer stars. It provides an index mapping location to filenames of files containing star data as above. Each indexed file covers a rectangle of sky in RA and DEC. The areas may be different sizes for different files. The area covered is given as the RA and DEC of the upper left and lower right corners, followed by the filename and a string indicating the type of the file. This is all on one line in the file. The format is then: