TIb^{∗}

A TEX bibliographic preprocessor

                            J. C. Alexander (jca@lakisis.umd.edu)

Department of Mathematics University of Maryland College Park, MD 20742

Small have continual plodders ever won, Save base authority from others’ books. W. Shakespeare, Love’s Labour’s Lost

• 0. General TIb is a package of four programs for making citations and reference lists in TEX documents. The main program, TIb, operates on a TEX file with incomplete or keyed citations, looks up the reference in a database, makes the complete citation and on command, makes a list of the references. The citations in the source document are enclosed in (non-TEX) escape characters which TIb recognizes. The output of TIb is another TEX file with complete citations and reference list formatted with a number of TEX control sequences and with definitions for these control sequences, ready to be processed by plain TEX, L^{A}TEX, or another TEX. With appropriate options in TIb and definitions of the control sequences, set by flags in the call to TIb or as environment variables, the citations and references can be formatted in any of a large variety of styles, and in particular, in the styles of various journals. It is intended that TIb be easy to use as is and yet also allow custom citation and reference formats to be created and implemented without undue effort.

TIbis a preprocessor in the style of refer, a similar preprocessor for the nroff/troff textsetters. Indeed TIb originally was to be a minor modification of the nroff/troff preprocessor bib written by T. A. Budd (which was inspired by refer), but with TEX output; however it has grown and changed considerably. The philosophy, though, is that of refer and bib (especially of bib in regard to modularity of the formatting files), and some of the code and subroutines from bib remain. The source code of TIb is in the language C.

The sections of this document are:

1. Demonstration
2. Program calls
3. Available styles
4. The input document
5. Styles and files
6. The reference file

         7. \input files

8. Error and warning messages

Disclaimer

A1. Appendix: the example document
A2. Appendix: local changes (if any)

Section 1 is for first-time users. Indeed, probably the best course is to use the demonstration files as models and use the remainder of this documentation as reference when needed.

The escape characters of TIb do not interfere with TEX processing. If TEX is applied to the original pre-TIb document, the escape characters and incomplete citations will appear as written. Thus it is suggested that a TEX document be debugged before applying TIb. When the TEX bugs are eliminated, TIb can be used for the final one or two runs.

∗ Version 2.2. \begin{matrix}c \\ ◯ \end{matrix}1986, 1989 James C. Alexander. TIb may be distributed whole, but not sold.

TIb 1. Demonstration — 2

• 1. Demonstration

1. Copy the file AAAAA/test.tex (see appendix) into a directory. This is a sample TEX document ready for TIb.

2. Copy the file AAAAA/test.ref into the same directory. This is a sample bibliographic database.

3. Apply the program TIbdex to test.ref

tibdex test (the .ref is appended automatically) This creates an inverted index INDEX in the directory.

4. Apply TIb to test.tex.

       tib test.tex

or

       tib test

(the extension .tex need not be part of the call). The output is the file test-t.tex, which is ready for TEX.

4.L. For L^{A}TEX, follow the instructions in test.tex before performing step 4. 5. Process test-t.tex with TEX or L^{A}TEX as usual.

This call sets default options. A large variety of formatting options is available. Some of them are: other fonts (old English, boldface ...), alphabetizing and other sorts of sorts, replacing successive listings of identical author(s) by underlines, other citation styles (3 letter codes from authors’ names, authors’ names and date, superscripts), reversing and/or abbreviating authors’ names, caps-small caps for names, hyphenating strings of references in citations, footnotes instead of endnotes, other listing formats. Any combination of these (and others) can be packaged in a format file and called with the -s ⟨style⟩ option. For demonstrations of some of these, repeat steps 4-5 with the following calls on test.tex (see also section 3):

tib -s demo1 test
tib -s demo2 test (for plain TEX)
tib -s demo2l test (for L^{A}TEX)
tib -s demo3 test (for plain TEX)
tib -s demo3l test (for L^{A}TEX)
tib -s demo4 test
tib -s demo5 test
tib -s demo6p test (for plain TEX)
tib -s demo6l test (for L^{A}TEX).

The last two call for footnotes; note the instructions in test.tex. Note that occasionally, reformatting or additional editing is called for. TIb is not meant to cover all formatting possibilities.

• 2. Program calls There are four programs in the TIb package:

TIb  bibliographic preprocessor for TEX documents,
TIbdex  makes inverted index from database(s),
TIblist  lists all members of the database(s),
TIblook  interactively locates listings in the database(s).

TIb 2. Program calls — 3

We consider the specifications for each. In the calls below angle brackets (⟨name⟩) enclose names to be supplied by the user. Square brackets ([-flag]) enclose optional items. The brackets are not part of the call. The space indicated between a flag and a ⟨name⟩ can be omitted. The flags need not be used in the order indicated below; files are processed in the order they appear, left to right. Note there is a distinction between index files and reference files. The latter is the database created by the user; the former is created by TIbdex.

tib [-d ⟨directory⟩] [-i ⟨include file⟩] [-j] [-n ⟨initial flag⟩] [-p ⟨private index file(s)⟩]

[-s ⟨style file⟩] [-x] [-z] [-|] [⟨input file(s)⟩]

TIb is a program to construct a bibliography for a TEX file and to include calls to macros files so that TEX formats the citations and bibliography in any of a number of styles. The input file is a TEX file augmented with incomplete or keyed citations surrounded by TIb escape characters, as described in section 4. Multiple input files are separated by spaces on the call and amalgamated into one output file. If ⟨input file⟩ is omitted, one prompt is given. If the input file is named file or file.tex, the output file is named file-t.tex, unless the input file is stdin, in which case the output file is stdout. The following are the options:

-d ⟨directory⟩ Private directory of TIb files. Obviates -i option. See Table 6.

-i ⟨file⟩ Include file of macros and TIb commands. See sections 3 and 5. This option is used if

there are private macro/command file(s).

-j Process \input files.

-n ⟨initial flag⟩Number (nonnegative) used as initial numerical citation flag (default 1). Ignored for

nonnumerical flags.

-p ⟨files⟩ Private index files, separated by commas. The default is the file INDEX in the working

directory.

-s ⟨file⟩ Style file, which contains formatting instructions and also may call other files. Style files

are described in detail in section 6. The available style files are described in section 3.

-x Output to stdout.

-z Silent run. Informational (but not warning or error) messages are suppressed.

-| Pipe. Input is stdin; output is stdout. Silent.

tibdex [-c ⟨common-word files⟩] [-k ⟨key number⟩] [-l ⟨length of keys⟩] [-n ⟨initial flag⟩]

[-p ⟨private output file⟩] [-z] [-%⟨string⟩] ⟨reference file(s)⟩

TIbdex makes an inverted index from reference file(s). The reference files are described in section 6. Names of multiple reference files are separated by spaces. The output is an inverted index for use by TIb and TIblook. The output index must not be moved or the links to the reference files will be broken. The following are the options:

-c ⟨file⟩ Common-word list, one word per line. Common words are not used as keys (default

CCCCC).

-k ⟨number⟩ Maximum number of keys kept per record (default 100).

-l ⟨number⟩ Maximum length of keys (default 6).

-n ⟨initial flag⟩Number (nonnegative) used as initial numerical citation flag (default 1). Ignored for

nonnumerical flags.

-p ⟨file⟩ Private output file (default INDEX in the current directory).

-z Silent run. Informational (but not warning and error) messages are suppressed.

-%⟨string⟩ Ignore lines in the reference file that begin with %x where x is in string (see Table 10) (default CNOPVcnopv\%). tiblist [-d ⟨directory⟩] [-i ⟨include file⟩] [-s ⟨style file⟩] [-x] [-z] [-|] [⟨reference file(s)⟩] TIblist makes a formatted plain TEX file of all entries in the input reference file(s). Names of multiple files are separated by spaces. If ⟨input file⟩ is omitted, one prompt is given. Unlike TIb, TIblist does not use inverted indices, but directly processes the reference files. The following are the options:

-d ⟨directory⟩ Private directory of TIb files. Obviates -i option. See Table 6.

-i ⟨file⟩ Include file of macros and TIb commands. See sections 3 and 5. This option is used if

there are private macro/command file(s).

-s ⟨file⟩ Style file, which contains formatting instructions and also may call other files. Style files

are described in detail in section 5. The available style files are described in section 3.

-x Output to stdout.

-z Silent run. Informational (but not warning and error) messages are suppressed.

-| Pipe. Input is stdin; output is stdout. Silent. Note: the -p option does not cause an error, but is ignored.

tiblook [-c ⟨common-words file⟩] [-l ⟨length of keys⟩] [-p ⟨private indices⟩] [⟨keywords⟩] TIblook locates entries in reference files from keywords. If keywords are not entered on the command line, TIblook gives instructions and operates interactively. TIblook, like TIb, works through inverted indices to get to the reference files.

The following are the options:

-c ⟨file⟩ Common-word list, one word per line. Common words are not used as keys (default

CCCCC).

-l ⟨number⟩ Maximum length of keys (default 6).

-p ⟨files⟩ Private index files, separated by commas. The default is the file INDEX in the working

directory.

-⟨keywords⟩ Keywords for noninteractive search.

The following can optionally be set as variables in the environment:

TMACLIB Directory for macro files (no directory-separator character on the end).

TMPDIR Scratch directory for temporary work files (no directory-separator character on the end). COMFILE File of common words. SYSINDEX System index file. DEFSTYLE Default style file.

The options permit a variety of possibilities in file organization. At one extreme there can be a number of specialized reference files and TIbdex can be run on particular ones to create an index for each particular document. At the other extreme, there can be one master reference file and one master index in a dedicated directory. This index can be accessed by TIb with the -p option. In this case the TIb programs could be aliased (or called from macros) so this index is automatically accessible. The same is true of private command files which are accessed with the -i option or made available with the -d option.

TIb 3. Available styles — 5

• 3. Available styles The selection of style file for the -s option for the call to TIb is the basic choice and is often the only choice necessary. It controls the format style of the citations and reference list. A number of styles are supplied; they are listed for reference (Tables 1 & 2). A name listed is called by the option -s ⟨name⟩ (although name is only part of the actual name of the file). The effect of the choice on TIb is described in section 5. There are a number of general styles and variations which are listed in Table 1. Also a number of journal styles are available. Journal styles currently available are listed in Table 2. One of the purposes of TIb is generating citations and reference lists in journal styles so that papers can be sent to journals as TEX files. As journals develop format specifications for TEX files, more journal styles will be developed and refined to those specifications. Conversely, a journal which accepts papers in TEX form and which has a copy of TIb, or at least appropriate .ttx files (see section 5), could process a paper set in TEX with TIb control sequences and format it to its own journal style. See also the file AAAAA/Styles.

TIb is not universally successful with all styles. There are several features which don’t work well in slyd; these are detailed in the master file BBBBB/slyd.tib. Moreover, so that the alternate citation style (see section 4) works with footnotes, TIb uses its own citation numbers in footnotes in plain TEX. If numbered footnotes are used for purposes other than citations, conflicts will arise. TIb works acceptably with L^{A}TEX, since it uses the footnote numbers generated by L^{A}TEX. Certainly the same process can be made to work in plain TEX (The TEXbook, exercise 15.12). In addition, when using “loc. cit.,” TIb refers only to the author(s). However, see the appropriate .ttx files for modifications to include the title also in the citation. Also some styles call for amalgamating multiple references into one footnote or include comments and references in one footnote. This is presently beyond TIb’s capability. For example, TIb has considerable trouble with the American Physical Society’s style, which uses footnotes with all the above features, and in addition collects them at the end as endnotes.

• 4. The input document TIb operates on a TEX file with incomplete citations. It recognizes its own set of escape sequences, which are summarized in Table 3. For an example document, see the appendix. For each such citation it locates the reference in a reference file, constructs the citation in one of several styles and on demand, creates a reference list. In this section we discuss the way TIb reads the file.

An ordinary incomplete citation is surrounded by the characters [. .]. For example:

                . . . in Arnol'd's book,[.arnold singularities.] especially. . .

Words in the incomplete citation (separated by spaces) are matched against the inverted index created by TIbdex and hence against the source reference files. The words are any words in the reference listing, except those in the excluded fields (see section 6 for a discussion of the reference files; see the -% option for TIbdex for excluded fields). TIb first searches the default index (INDEX ) or the indices designated with the -p option, in order from left to right and then the system index, if there is one. If an entry is found that matches all words, that reference is used. If no reference entry is found or if multiple entries are found, a warning message is sent to the console. The case of the letters in the citation is immaterial. The words in the citation are truncated (by default to 6 letters; see the -l option for TIbdex). Thus [.arnold singularities.] and [.ARNOLD singul.] effect the same result. Embedded newlines, tabs and extra spaces are ignored. The format of the citation is controlled by TIb format files (section 5).

Note that punctuation is placed to the left of the citation. In some citation styles (e.g. brackets), punctuation comes after the citation, and in others (e.g. superscripts), it comes before. TIb looks at the character immediately preceding the [. and generates control sequences which are interpreted by TEX via TIb 4. The input document — 6

Table 1. General format styles

num (default unless reset at installation or in environment)

numo, numos, numb, numbs, numu, numub, numubs, numus, numul, numubl, numubsl
alpha, alphab
nmdt, nmdtb
footp, footl
intext, slyd

Meanings:

num standard numerical citations alpha 3 letter alphabetic citations nmdt citations made from names and date foot footnotes o old English b some boldface s sorted (alphabetized) u superscripts (up) p plain TEX l L^{A}TEX intext references in text slyd for making slides

Table 2. Journal format styles

acm Association of Computing Machinery (all journals) [acml for L^{A}TEX]

American Mathematical Society (all journals)

amsa alphabetical citations amsd name-date citations amsn numerical citations aps American Physical Society cmp Communications in Mathematical Physics epes Electrical Power and Energy Systems ijrr International Journal of Robotics Research ieee Institute of Electrical and Electronic Engineers (all journals) jgr Journal of Geophysical Research lala Linear Algebra and its Applications

Society for Industrial and Applied Mathematics (all journals)

siamd name-date citations [siamdl for L^{A}TEX] siamn numerical citations [siamnl for L^{A}TEX] spln Springer Lecture Notes and other publications

macro files appropriate to the citation style. Punctuation to the right of citations is passed through unparsed to TEX. Such a citation placed in a line after a TEX comment character ‘%’ (or other character of category 14) will cause the cited reference to appear in the listing, but not in the text.

Multiple citations in one citation mark are indicated by commas:

TIb 5. Styles and files — 7

                 . . . equations.[.arnold singularities, arnold equations.]

Additional information can be placed at the end of a citation by enclosing it in angle brackets < >, e.g.

                        . . . in.[.arnold singularities <, chap. 2>.]

In citation styles which use brackets, such insertions are enclosed verbatim in the brackets. In other styles, such as footnotes, the information is appended to the reference listing.

An alternate citation style can be used by surrounding the incomplete citation with <. .>. This is mostly for citations in running text. Thus:

                   . . . discussed in reference <.arnold singularities.>.

Insertions are not permitted in this alternative style. Neither is punctuation handled specially; thus punctuation should be put in its usual place.

A reference list is constructed and inserted in the document where the sequence .[] is encountered at the beginning of a line. The remainder of that line is processed and inserted before the listing. The style and format of the listing is controlled by TIb format files.

If for some reason, one of TIb’s sequences is part of the text of the document, break up the sequence so TIb will not recognize it (e.g. [{}. or $x< .5$). Note that the TIb escape sequences are transparent to TEX so they do not interfere with TEX processing. Thus a TEX document can be debugged without running TIb. The citations will appear as typed in the document. After all TEX bugs are eliminated, then TIb can be used for the final one or two runs.

Table 3. TIb’s escape sequences

[.key words.] Citation,

<.key words.> Alternate citation,

[….<insertion>.] Insertion in citation,

.[] Make reference list after this line (must be at beginning of line).

• 5. Styles and files TIb controls the format of the citations and reference lists by means of files of TIb and TEX commands. For the most part the details of such controls can be ignored, with three possible exceptions.

One: it is possible to “define” code words for use in the reference files. For example, a file of 1845 standard (= Mathematical Reviews) journal abbreviations is supplied and TIb will automatically abbreviate journal names. The process is discussed below in the subsection on definitions. Additionally, private abbreviations can be defined and the standard abbreviations can be overridden. The method for doing such is discussed in this section.

Two: TIb can automatically format 99^{44}/_{100}% of citation work. However it is only a computer program, and on occasion will require human assistance. There will be references which TIb just cannot format correctly. Or an overfull \hbox may crop up. The output of TIb is a TEX document which may be edited before applying TEX. However TIb puts out a small jungle of control sequences and it is necessary to have some idea how to hack through them.

Three: concerning those control strings, TIb reserves fifty or so control strings for its use. The definitions of these strings can be modified for particular effects; however unintentional modification can result in chaos. Thus it is at least necessary to know what the reserved strings are.

Reserved control strings We take care of the last point first. Table 4 is a complete list of global control strings which TIb may insert into a document. Also TIb uses the plain TEX strings \bgroup and \egroup as implicit left and right braces. For completeness, it explicitly defines them with their plain TEX meanings. In addition TIb sets a number of other control strings. However these are local and thus will not conflict with their possible other use in other parts of the document. For the meaning of these strings, see the file BBBBB/Macros.ttx, where these control strings are given their default definitions.

Table 4. Reserved global control strings (See file BBBBB/Macros.ttx for definitions)

\TMACLIB              \aand                 \Aand                 \aandd
\Aandd                \ACitefont            \acomma               \Acomma
\Authfont             \Citebrackets         \Citebreak            \Citecomma
\Citefont             \Citehyphen           \Citenamedate         \Citeparen
\Citesuper            \eand                 \Eand                 \eandd
\Eandd                \ecomma               \Ecomma               \Flagfont
\Flagstyle            \Initgap              \Initper              \LAcitemark
\Lbang                \Lcitemark            \Lcolon               \Lcomma
\LIcitemark           \Lperiod              \Lpunct               \Lqquote
\Lquest               \Lquote               \Lrquote              \Lscolon
\Lspace               \Nameand              \Nameandd             \Namecomma
\RAcitemark           \Rbang                \Rcitemark            \Rcolon
\Rcomma               \Reffont              \Refformat            \Refstd
\Refstda              \Resetstrings         \Revcomma             \RIcitemark
\Rperiod              \Rpunct               \Rqquote              \Rquest
\Rquote               \Rrquote              \Rscolon              \Rspace
\Smallcapsaand        \Smallcapseand        \Smallcapsfont        \Titlefont
\Tomefont             \Underlinemark        \Volfont              \zstr
\Zstr                 \ztest                \Ztest
\journalarticleformat         \conferencereportformat       \bookformat
\technicalreportformat        \bookarticleformat            \otherformat

TIb is intended to be compatible with virtually all possible TEXs, in particular plain TEX, L^{A}TEX, and AMS-TEX. With only a few exceptions, all macros in TIb are written in terms of primitive TEX (starred commands in D. Knuth’s The TEXbook). The exceptions are:

(1) fonts \rm and \sl are assumed loaded; also \sevenrm if AX or EX is used,

(2) footnote macros for plain TEX and L^{A}TEX are used in the appropriate macro files,

(3) the files of journal names are for Latin fonts and include plain TEX diacritical marks (D. Knuth’s The TEXbook, p. 52 or L. Lamport’s L^{A}TEX, p. 40); in particular, if a Cyrillic font is to be used, different journal word-definition files must be used.

On the other hand, TIb requires that the category codes of plain TEX be in force (see The TEXbook, p. 37). For example ‘{’ and ‘}’ are assumed to be grouping characters, ‘%’ is assumed to terminate a line, etc. TIb occasionally puts out something in $math mode$, but creates neither displayed nor tabular material.

TIb 5. Styles and files — 9

Table 5. A typical .tib file

#
#  standard format
#
#         include word-definition file (journals and publishers)
I TMACLIB amsabb.ttz
H         hyphenate strings of citations
%The lines below are copied verbatim into the output document as TeX commands.
%First the file \TMACLIB Macros.tib is \input with Macros and default settings.
%The control string \TMACLIB is just a path.
%
\input\TMACLIB stdbra.ttx %TeX macros for formatting reference list
\Refstda\Citebrackets %set general formats for reference list and citations

TIb files The -s and -i options of the call to TIb both cause TIb to process files. The files are processed in their orders in the call to TIb. These files (Table 5) contain TIb format commands (Table 7) which control how TIb processes the input file and/or TEX control strings which are printed verbatim in the output document. In turn these files can contain a command to process further files. In general the -s option causes TIb to process a master style file which in turn effects processing of subsidiary files. For the most part the user need only be concerned with the master file. The -d and -i options are available if some private commands (such as definitions for code words) or styles are to be incorporated. Although any TIb command file can contain either TIb commands or TEX control strings or both, there is a general extension-naming convention:

.tib Master command files, which are usually called by the -s option. These files contain enough

commands to completely set a style. It is possible for one of these files to call another.

.ttz Subsidiary files consisting of TIb commands and possibly TEX commands, which are called

by .tib files.

.ttx Files consisting of TEX macros which are often \input by commands from the master .tib file.

Thus there are files

num.tib setting standard numerical flags enclosed in brackets, amsabb.ttz containing definitions (abbreviations) of code words for journals, and ieee.ttx containing the TEX macros for formatting citations and references in the style of IEEE

journals.

Table 6. Order of file search

first: look in the current directory for ⟨filename⟩,

second: append .tib to ⟨filename⟩ and look in the current directory, third: if the -d option is used, look in that directory for ⟨filename⟩, fourth: append .tib to ⟨filename⟩ and look in the -d directory, fifth: look in the system directory for ⟨filename⟩, sixth: append .tib to ⟨filename⟩ and look in the system directory, seventh: quit with an error message.

TIb 5. Styles and files — 10

Table 7. TIb commands

# Comment, line ignored A Format authors’ names depending on following characters as follows: AA Abbreviate authors’ first names AR⟨num⟩ Reverse first and last names of first num authors. If num is omitted,

all authors’s names are reversed.

AX Print authors’ names in caps-small caps. If AA and AX are called for, the abbreviated first names are not put in caps-small caps (relevant only for first names not beginning with a capital letter). Defining \Authfont as a caps-small caps font [such as amcsc (=\sc in L^{A}TEX)] if one is available, is an alternative to using AX.

E Equivalent to the A command, except for editors. C⟨template⟩ Citation template. See discussion in text. D ⟨word⟩ ⟨definition⟩ Definition of word. See discussion in text. f Footnotes. Print out reference immediately, instead of saving for list (in

which case the escape sequence .[] is not used).

F Use special citations flags from reference file if they exist, instead of con-

structed flags.

I ⟨filename⟩ Include filename for processing; filename may contain further TIb com-

mands.

H Hyphenate three or more citations in one citation mark that refer to successive entries in the reference list. For example, the citation 2,3,4,5 is replaced by 2–5. The H option implies the O option.

L Use “loc. cit.” and “ibid.” for duplicate references. N⟨string⟩ Turn off options indicated by string, which must be composed of the letters

A (for AA), F, H, O, R, S, X (for AX).

O Citations in one citation mark are sorted according to the order given by

the reference list.

P Print only first page numbers of articles. S⟨template⟩ Sort reference list according to template. See discussion in text. T⟨string⟩ Generate trailing character strings for reference fields coded in string. See

discussion in text.

U Replace two or more successive reference listings of identical authors by underlines.

TIb searches for ⟨filename⟩ called with the -s or -i option in the call, or the I command in a file (see next subsection) in the order listed in Table 6. Thus system .tib files or private .tib files can be called with short names. All other files require full names. Private files can be kept in the working directory or a directory designated with the -d option. If the -d option is to be used regularly, the calls to TIb and TIblist could be aliased or put in macros. The code TMACLIB (followed by one or more spaces) is defined as the system directory BBBBB for use in command files, and the TEX control string \TMACLIB is defined as the system directory name, for use in \input commands.

A TIb output file starts with the TEX commands

     \def\TMACLIB{BBBBB/}\input\TMACLIB Macros.ttx.

The file TMACLIB/Macros.ttx contains default definitions for the reserved control strings. Then any TEX commands from the files called with the -s or -i options (and commands from files called by these files) are listed. Then comes the processed document. There are also \message commands to list the files called (in order with nesting) on the terminal and in the .log file during the subsequent TEX run. Note that any default TEX definition can be overridden by a redefinition either in a file called with -i or in the document proper. Similarly TIb commands can be added in files called with -i. If there is a standard private such file (e.g. containing definitions), it could be kept in a special directory and the call to TIb could be aliased or put in a macro so that this file is always included.

TIb commands

TIb commands begin in the first column of a file and are one-letter commands possibly followed by character sequences. Table 7 lists the commands. The first line in the file that does not match one of the items in Table 7 causes that line and all subsequent lines to be copied verbatim to the output file.

Citations

Table 8. Citation styles

0 No citation – used for inserting reference in the body of the text.

1 Numerical citation, starting at 1 (default style).

2 Alphabetic citation constructed from last names of author(s): if one author then first 3 letters of name; if two authors then first 2 letter of name of first and first letter of name of second; if 3 or more authors then first letter of name of first three. If the last name of an author does not begin with a capital letter, the citation is extended until the first capital letter is encountered. Can be followed by further code which denotes additional fields from the reference file. For example the template 2D-2 means follow the alphabetic citation with the last two characters in the date field. The two fields are separated by the TEX control string \Citebreak. If \Citebreak is defined to be empty, the template 2D-2 will effect citations of the form “AuD77.” If there are no authors, citations are made from editors’ names. If there are also no editors, the issuer is used.

3 Last names of authors or first author et al. if more than three authors. Can be followed by further code which denotes additional fields from the reference file, as above. If \Citebreak is defined to be {, }, the template 3D-4 will effect citations of the form “Hale, 1983.” If there are no authors, editors or the issuer is used as above.

4--9 Available for future use or for local styles.

The citation command C determines the style of the citation. The template is one number 0 through 3, which codes the citation, possibly followed by further instructions. The template codes are listed in Table 8. The numerical citation style is the default. If necessary, the character ‘@’ can be used to separate objects in the citation template. If two citations are identical (e.g. two works by one author in one year), TIb appends letters ‘a’, ‘b’, etc. at the end of the citation to resolve ambiguities.

Sorting This command causes the reference list to be sorted according to the order encoded in ⟨template⟩. The template consists of letters denoting fields of the reference file, possibly followed by numbers. For example, the template AD will effect a sort on authors’ last names, with a secondary sort on the date. The template A1D will effect a sort on the first authors’ last names, with a secondary sort on the date. A minus sign after a field code will cause the sort to be in the reverse order, e.g. anti-alphabetically. Two references which test equally in the sort will be listed in order of citation.

Trailing characters If the TIb T command is set, for each field indicated in template, TIb prints out a control string \fieldtrail which is defined as the last character in \fieldstr. This sometimes is used for determining the punctuation after the data in the listing.

Definitions TIb is able to store a list of code words and their expansions. Such word-definition pairs are inserted with the D command, followed by a space, followed by the code word, followed by another space, followed by the definition (expansion), e.g.

        D PROC Proceedings

or

        D COMMA1 Comm. ACM

Code words are restricted to alphanumeric, ampersand and underscore characters. Whenever TIb encounters a |word| (enclosed between two vertical bars) in a reference file, it searches its list and replaces word with definition. Moreover definition can itself contain |another word|. TIb will iterate the process until all words are expanded. Also, more than one field can be part of the definition. For example (with reference to Table 10) the word-definition pair

        D AcPress Academic Press\
        %C |NYC|

causes |AcPress| to expand to the publisher “Academic Press” and the city “|NYC|”, which of course further expands to “New York, NY.” Both fields are automatically available. Similarly |LNMath| expands to the series “Lecture Notes in Mathematics,” the publisher “Springer-Verlag” and the cities “New York– Heidelberg–Berlin.”

Files of word-definition pairs can be collected and processed by TIb before processing the document. Thus expansions which are different in different styles can be changed by using different definition files. For example, one style may require “Proceedings” where another may require “Proc.” Furthermore files of standard abbreviations can be made automatically available. In particular, Mathematical Reviews has supplied its databases of full journal names and abbreviations. These are available as amsfll.ttz and amsabb.ttz respectively, and are automatically processed by the supplied format styles.^{∗} The styles of most journals call for abbreviated journal names in reference lists, although a few (such as the Journal of Optimization Theory and Applications) require full names. The 6-letter codes may be obtained by perusing the files. Any definition can be overridden by a later word-definition pair. Moreover, since TIb iterates the process

∗ TIb thanks Mathematical Reviews for its generosity in providing these files as a service to the scientific community. The data in these files are copyright \begin{matrix}c \\ ◯ \end{matrix} by Mathematical Reviews and are not to be used in any proprietary manner. of expanding words, private (perhaps shorter) codes can be created which expand to the ones in the files. These could be kept in another file which is accessed with the -i or -d option. For example:

        D CACM |COMMA1|

There are other word-definition files pub.ttz (publishers) and misabb.ttz and misfll.ttz (miscellaneous) which are automatically included with the journal files. For run-time efficiency, extensive word-definition files should be amalgamated as much as possible and sorted alphabetically on the words.

Reference lists For each reference to be listed, TIb generates a local sequence of control strings for TEX. The interpretation of these control strings is governed by the macros in the selected .ttx file. The relation of control strings with reference file fields is discussed in section 6. In this section we discuss the control strings TIb generates. In Table 9 is listed a typical reference listing in a TIb output file.

Table 9. A typical TIb reference listing

    {\Resetstrings%
    \def\Loccittest{}\def\Abbtest{}\def\Capssmallcapstest{}%
       \def\Edabbtest{}\def\Edcapsmallcapstest{}\def\Underlinetest{}%
    \def\NoArev{0}\def\NoErev{0}\def\Acnt{1}\def\Ecnt{0}\def\acnt{0}\def\ecnt{0}%
    \def\Ftest{ }\def\Fstr{10}%
    \def\Atest{ }\def\Astr{Donald E. Knuth}%
    \def\Ttest{ }\def\Tstr{The \TeX book}%
    \def\Itest{ }\def\Istr{Addison Wesley}%
    \def\Ctest{ }\def\Cstr{Reading, MA}%
    \def\Dtest{ }\def\Dstr{1984}%
    \Refformat%
    }

The control strings \Loccittest, etc. are printed out by TIb depending on the setting of various TIb controls. They are defined as {} or {} depending on whether the control is off or on, respectively. The control strings \NoArev, \Acnt, etc. are respectively set equal to the numbers of authors’ names to be reversed, the number of authors, etc. These are for use in formatting, if needed. For certain fields, TIb also prints out formatting aides. For example, for listings with page numbers, TIb prints out a control string \Pcnt, which is defined as {} or { } if there is one or more than one page, respectively, so that for example, a choice can be made between “p.” and “pp.” in the listing. For each field field of the reference file which contains data, TIb prints out

        \def\fieldtest{ }\def\fieldstr{data}%.

A new field can be inserted in the TIb output file before running TEX by inserting such a line. In particular, anything put in the O field is appended to the end of the reference listing. Also if need be, the data can be changed. Depending on TIb commands set, some fields, particularly author and editor fields, may contain inserted TEX control strings. The control string \Resetstrings resets all the \fieldtests and \fieldstrs to {} (except for the Z and z fields, see Table 10). The control string \Refformat effects the printing of the listing. Thus any changes between these two control strings affect the final printed document.

TIb 6. The reference file — 14

Table 10. Field tags

%A Author(s) (may have multiple authors, separate field entry for each author in order) %B Book title %C City of publication %D Date %E Editor(s) (may have multiple editors, separate field entry for each editor in order) %F Special citation flag, use is governed by TIb F command %G Government (NTIS) ordering number %I Issuer (publisher) %J Journal name or for unpublished conference report, the conference name %K Keys for searching, not printed out %M Mathematical Reviews number %N Number of issue (journal or series) %O Other information, appended to listing %P Page numbers %R Technical report identifier %S Series title %T Title of article or book %V Volume number (journal or series) %Z Reserved by TIb for special insertions %a Translator(s), also editor(s) of translated compilations %b Translated book title %c City of publication of translated item %d Date of translated item %e Author(s) of reviewed material; reviewers’ names go in A fields in order %i Issuer of translated item %j Translated journal name %k Reserved for future use for secondary references %l Language of translation %n Number of translated item %o Other information, inserted after book title %p Pages of translated article %r Identifier of translated technical report %s Series of translated item %t Title of translated article or book %v Volume of translated item %z Reserved by TIb for special insertions %\ Beginning of line of TEX instruction(s) %% Comment (passed as TEX comment)

TIb 6. The reference file — 15

• 6. The reference file A reference file is a database file containing any number of reference items, separated by one or more blank lines. Reference items consist of reference fields which in turn consist of data organized into field tags and field data. The meaning of field tags is an extension of that of bib and is suggested by that of refer. However there are enough differences that bib or refer reference files are not directly usable with TIb. A field tag is a percent sign ‘%’ in column 1 followed in column 2 by a single character. The currently recognized tags are listed in Table 10. Field data begins in column 4; the data can consist of any printable characters. Field data can be as long as necessary and can extend into the next line. Lines that do not begin with a percent sign are treated as continuation lines. Every line (including continuation lines) must begin in column 1. The A, E, a, e and \ fields can be repeated as often as necessary; other fields can occur at most once (more precisely the last occurance of a field is the one used). Fields can occur in any order except that authors, editors, etc. are listed in order of appearance. Lines beginning ‘%\’ are inserted verbatim into the output; they are assumed to be TEX instructions. Lines in a reference item beginning ‘%%’ are comments.

Table 11. The control string \Refformat

    \def\Refformat{%Determines the kind of reference by the presence or
    %   absence of certain fields in the database listing, and calls the
    %   appropriate macro.
        \if\Jtest\present
            {\if\Vtest\present\journalarticleformat
                 \else\conferencereportformat\fi}
           \else\if\Btest\present\bookarticleformat
              \else\if\Rtest\present\technicalreportformat
                 \else\if\Itest\present\bookformat
                    \else\otherformat\fi\fi\fi\fi}

As discussed in section 5, TIb turns the field data in a reference item into a sequence of TEX control strings. In each .ttx file, there are six basic format macros. Which one is used depends on the presence or absence of certain fields in the sequence (unless the process is overridden). The control string \Refformat (Table 11), which TIb sets up to be processed by TEX after the sequence of field strings (Table 9), is contained in the file Macros.ttx, and causes TEX to choose one of the six. The control string \Resetstrings defines \present to be a space, so that if \fieldtest is { }, then \if\fieldtest\present tests true.

Table 12. A macro to print a reference item

    \def\conferencereportformat{\Reffont\let\uchyph=1\parindent=1.25pc\def\Comma{}%
    \sfcode`\.=1000\sfcode`\?=1000\sfcode`\!=1000\sfcode`\:=1000%
              \sfcode`\;=1000\sfcode`\,=1000%\frenchspacing
               \par\vfil\penalty-200\vfilneg%\filbreak
     \if\Ftest\present\Flagstyle\Fstr\fi%
      \if\Atest\present\bgroup\Authfont\Astr\egroup\def\Comma{\unskip, }\fi%
       \if\Ttest\present\Comma\bgroup\Titlefont\Tstr\egroup\def\Comma{, }\fi%
        \if\Jtest\present\Comma\bgroup\Tomefont\Jstr\egroup\def\Comma{, }\fi%
         \if\Ctest\present\Comma\bgroup\Cstr\egroup\def\Comma{, }\fi%
          \if\Dtest\present\kern.16667em(\bgroup\Dstr\egroup)\def\Comma{, }\fi%
           \if\Otest\present\Comma\bgroup\Ostr\egroup\fi.%
            \vskip3ptplus1ptminus1pt}%\smallskip

The six macros \journalarticalformat, etc. that actually effect the printing of the reference listings are rather straightforward (see Table 12). They check for the presence of relevant fields and print them out in the desired form. Thus they consist mostly of a series of \if… \fi conditional commands enclosing printing commands.

If \Reffont’s selection for a particular reference item is unsatisfactory, it can be redefined locally on a one-time basis in the TIb output document before running TEX, or permanently by including control strings in the reference file (see the example below). Indeed of course, \Refformat or any of the six formatting macros can be redefined in the document or in an included file (called with the -i option or the TIb I command (Table 7)).

The K (keyword) field The K field is searched to identify references but is not printed out. Thus it can be used to facilitate identification. An example:

    %A Dennie Van~Tassel
    %T Program Style, Design, Efficiency
    %I |PrHall|
    %D 1978
    %K testing debugging tassel

Note also the use of the defined word in the %I field. The city of publication is included as part of the definition.

Formatting techniques Most reference items are uncomplicated and present no formatting problems. In this subsection we discuss some techniques for the other cases.

TEX control strings in the reference file can be used to automatically effect the format of the reference listing. Consider the example:

    %A R. Colt Hoare
    %T A Tour through the Island of Elba
    %C London
    %D 1814
    %O out of print
    %\def\Refformat{\bookformat}

This example of a book has no listed publisher (I field). The I field is used by \Refformat in its decision (Table 11) and the decision would be incorrect for this example. Thus \Refformat is redefined in the reference item. The redefinition is local to the one reference and does not affect other references.

Most data in the reference file is passed through to TEX unaltered. Thus TEX control strings are permitted in the field data:

    %T The development of the January 1983\/$1^\circ\times1^\circ$
    mean free-air anomaly data tape

The italic correction spaces things correctly if the title is printed in italic or slant. In the six formatting macros, the control string printing the data is preceded by \bgroup and followed by \egroup. This permits certain techniques. For example, either

    %T A refined gravity model from LAGEOS\/ \egroup(GEM-L2)\bgroup

or

    %T A refined gravity model from LAGEOS\/ {\Reffont(GEM-L2)}

causes “(GEM-L2)” to be printed out in ordinary type (usually Roman), even if the font for titles is something else.

It is necessary to be more careful with author, editor, reviewer, translator and possibly institution fields. TIb operates on these fields in response to commands to abbreviate names, reverse names, and put fields in caps-small caps. We discuss how TIb operates on these fields. The ‘a’ and ‘e’ fields are governed by the commands for editors. If a reference item has no authors, the editors are used in place of the authors, both in the listing and for sorting. If there are also no editors, the publishing institution is used. The last name is the last word in a field. If the name is compound, it can be connected with an active character or a space control character. Thus

    %A Dennie Van~Tassel

or

    %A Dennie Van\ Tassel

is correct. The first style prohibits a line break; the second permits a break.

For purposes of sorting, the first capital letter of the last name is used. The abbreviation routine has a certain amount of sophistication. It will abbreviate “Heinz-Otto” to “H-O.” It will abbreviate “d’Arcy” to “d’A.” However if both abbreviation and caps-small caps are called for, it will not set the ‘d’ in “d’A.” in small caps. That will have to be done by hand or with TEX. Making special letters with control characters in these fields (D. Knuth’s The TEXbook, p. 52 or L. Lamport’s L^{A}TEX, p. 40) must conform to the following rules: they may not be nested and they must be enclosed in braces. When sorting or making caps-small caps, TIb handles material in braces in special ways. The following are correct:

    %A Ol{\'u}wol{\'e} {\'O}d{\'u}nd{\'u}n
    %A S{\o}ren {\AA}ngstr{\"o}m
    %A Heinz-Otto O'Grady
    %A Serge{\v\i} {\t I}ur'ev

There is one more rule. Caps-small caps turns lowercase letters into uppercase; accordingly lowercase strings must have uppercase analogues if TIb’s caps-small caps are to be used. If necessary these can be set up by \def (which are local to the references). Thus:

    %\def\SS{\ss}
    %A K. L. Weierstra{\ss}

The last example above is better:

    %\def\I{I}
    %A Serge{\v\i} {\t I}ur'ev

In fact, such control strings can be created and used to fool TIb, at least partially, if need be. For example:

    %\def\PRESIDENT{The President's Commission on Aging}
    %A {\PRESIDENT}

This will ensure that the reference is alphabetized by “PRESIDENT,” rather than by “The.” However, TIb’s caps-small caps will not work; the entry will have to be set by hand.

Reference items In this section we consider the forms in the reference database of various types of reference materials. The criteria used are those of \Refformat (Table 11). Tags are indicated in parenthesis.

Journal article

A journal article must have a journal name (%J) and a volume number (%V). It usually also has one or more authors (%A), a title (%T), page numbers (%P), and a date of publication (%D), and sometimes an issue number (%N). It may have a publisher (%I) or be a translation. In the last case, certain lower case fields are used. Two examples:

%A Tammo tom~Dieck
%T Bordism of $G$-manifolds and integrality theorems
%J |TOPOL|
%P 345-358
%V 9
%D 1970
%K dieck
%A V. I. Arnol'd
%T Singularities of smooth mappings
%J |USPMN1|
%V 23
%P 3-44
%D 1968
%K arnold
%j |RUSMS|
%v 23
%d 1968
%p 1-43

Note the use of journal codes to effect automatic standard abbreviation.

Conference presentation

A conference presentation can be either an unpublished report or an article in a proceedings which has no editor and is identified by the conference. In this case the name of the conference is put in the journal field (%J). There is no volume (%V) field. There are likely also one or more authors (%A), a title (%T), a date (%D) and a city (%C), and in a proceedings, pages (%P).

%A F. J. Lerch
%A S. M. Klosko
%T Gravity model improvement using laser data
%J First Crustal Dynamics Working Group Meeting
%C Goddard Space Flight Center
%D |SEP|, 1981

Technical report A technical report has a report number or identifier (%R). It probably also has one or more authors (%A), a title (%T), a date (%D), and an issuing institution (%I) (which may alternatively be part of the report identifier), and possibly a city (%C), a government issue number (%G) and perhaps pages (%P).

%A F. J. Lerch
%A S. M. Klosko
%A G. B. Patel
%T A refined gravity model from LAGEOS\/ \egroup(GEM-L2)\bgroup
%I |NASA|
%R Tech. Memo. TM 84986
%D |FEB|, 1983

Book A book has a publisher (%I) but no journal name (%J) or report number (%R). Usually it also has one or more authors (%A), a title (%T), a date (%D) and a city of publication (%C). It may also belong to a series, in which case it has a series name (%S), and probably a series volume (%V) or number (%N). It may also have a government number (%G). Note the use of the F field. In these examples, the city of publication (%C) included as part of the definition of the abbreviated %I field. In the first example there is no author (%A) or editor (%E); the issuer (%I) is used in place of the author for citation making and sorting.

%T Software Engineering Automated Tools Index
%I |SRA|
%F SRA
%D 1982
%A R. E. Griswold
%A J. F. Poage
%A I. P. Polonsky
%T The SNOBOL4 Programming Language
%o (second edition)
%I |PrHall|
%D 1971

Article in book An article in a book has two titles, the title of the article (%T) and the title of the book (%B). It probably has one or more authors (%A), and the book probably has one or more editors (%E). It also probably has page numbers (%P). As well, the fields for a book are present.

%A C. A. R. Hoare
%T Procedures and parameters: An axiomatic approach
%B Symposium on Semantics of Algorithmic Languages
%E E. Engeler
%P 102-116
%S |LNMath|
%V 188
%D 1971

TIb 7. \input files — 20

Compilation A compilation is the work of several authors gathered together by one or more editors (%E). Thus there are no authors (%A). Other than that, it is treated as a book.

    %E Heinz-Otto Peitgen
    %E Hans-Otto Walther
    %T Functional Differential Equations and Approximation of Fixed Points
    %D 1979
    %S |LNMath|
    %V 730

Dissertation or thesis Many manuals of style say to treat a PhD dissertation as a book, with the institution granting the degree as the issuer. However most journals format dissertation and thesis listings as technical reports.

    %A Martin Brooks
    %T Automatic Generation of Test Data for Recursive Programs Having
    Simple Errors
    %R PhD Thesis
    %I Stanford |UNIV|
    %D 1980

Preprint A preprint is also best handled as a technical report with “preprint” or “to be published” or even “unpublished” in the R field. Sometimes a preprint has a report number which can be used and “to be published” can be put in the O field.

Other Most sources fit in one of the above categories. A little experimentation may be necessary for less-standard sources, such as newspapers, archival sources, or correspondence. If the reference item does not meet any of the criteria of \Refformat, it is formated by \otherformat (see Table 11).

• 7. \input files With the OPTCH j option (OPTCH i was already assigned), TIb will recognize \input statements,^{∗} and process the corresponding files. The processed contents of these files are incorporated in the master -t file. Messages are printed out during the TIb run and also messages “⟨file⟩ input by Tib” are printed out during the subsequent TEX run. TIb will process a file only if a complete (relative or absolute) path is given (it will attempt to append the .tex suffix to the name). In particular, it does not look through the TEXINPUTS environment. It assumes anything without a complete path name is not a text file and should not be processed. If TIb cannot find a file, it prints out a message and leaves the \input statement unaltered. If \input is part of a definition of a macro in the text, TIb will be confused, but not fatally; it will leave the definition unchanged and the message it prints can be ignored. However files which are input by means of the macro will not be processed by TIb. Indeed, to be safe, it is probably best to prevent TIb from processing

TIb 8. Error and warning messages — 21

∗ In L^{A}TEX, there is a similar command, \include. However, \include is more complicated than \input. For examples, \include interacts with the \includeonly command and it involves dealing with auxiliary files. It was decided that trying to get TIb to process \included files could lead to mishandled files, and that it is safest not to include this capability. macro files, even if they are in the working directory; this can be accomplished by defining something else as \input (e.g., \INPUT) and using that for non-text files.

TIb incorporates any final blank lines and the usual final ‘newline’ in the \input file. This generally effects a new paragraph after the material from the \input file. The new paragraph can be avoided by eliminating any final blank lines and either: (1) eliminating the final ‘newline’ in the \input file (not recommended), or (2) continuing the text (possibly a comment character preceeded by at least one space) on the same line after the “\input ⟨file⟩” statement in the master file.

• 8. Error and warning messages

Can't open index <indexname>

Index ⟨indexname⟩ does not exist or not readable.

command line: invalid switch <switch>

⟨switch⟩ not a valid option on the call.

Can't open <filename> or <filename>.tex

Neither document file ⟨filename⟩ nor ⟨filename⟩.tex is available for reading.

Cannot locate reference file <filename>

File of references ⟨filename⟩ not available.

<index> not up to date

One of the reference files antecedent to ⟨index⟩ has been changed since ⟨index⟩ was made.

word <word> not defined in definition list

Misspelled word in reference file?

bad brackets in string <string> in references

Unmatched, or badly placed, pair of brackets {} in a reference item has caused TIb to get lost.

word expected in definition

A undefined word exists in word-definition file.

too many definitions

Word-definition file larger than limit set in source code. Reset and recompile.

out of storage

TIb too big for system (either while making word-definition list or while processing citations). Possibly have to use smaller word-definition file.

unexpected end of citation template

Citation template not complete.

can't open temporary reference file

Work file cannot be opened—system or environment problem.

can't open temporary output file

Work file cannot be opened—system or environment problem.

can't open temporary output file for reading

Work file cannot be reopened—system or environment problem.

ill formed reference

Bad reference item has caused TIb to get lost.

end of file reading citation

Probably .] was omitted in document.

citation too long

Too many keys, or keys too long (truncate to 6 letters).

inconsistent citation found in pass two

TIb found a reference earlier, now it can’t—something funny’s going on.

citation not found in pass two

TIb found a reference earlier, now it can’t—something funny’s going on.

tibdex: can't open temporary output file

Work file cannot be opened—system or environment problem.

tibdex: error in open of <filename>

⟨filename⟩ doesn’t exist or can’t be read.

tibdex: error in opening file for compression

Work file cannot be opened—system problem.

ill formed reference file

Bad reference item has caused TIb to get lost.

too many references

Number of reference larger than limit set in source code.

locate: cannot open <filename>

⟨filename⟩ not available for reading in subroutine locate.

locate: no keys for citation

Empty citation discovered in subroutine locate.

locate: insufficient space for references

TIb too big for system—discovered in subroutine locate.

locate: first key (<keyname>) matched too many refs

Put another key first in citation.

tibdex: too many common words

Too many words in list of words not to be used as keys.

no reference matching <citation>

Probably mistyped keyword.

multiple references match <citation>

Need more keys in citation.

end of file after \input/\include

Missing file name.

\input/\include files nested too deeply

Nesting limited to a depth of 32 files.

unable to locate file, assuming it has no references

Cannot locate \input/\include file, and leaves command unaltered.

truncated following reference . . .

Reference too large and must be truncated.

Warning: reference list not made -- .[] not encountered

A reference list is made where the symbols .[] begin a line.

Finally there is the possibility the TIb output file will cause a TEX error. It may be that a reference item does not have the right format (e.g. unmatched braces). In many cases a quick fix may be possible in the TIb output file. If something goes completely haywire, a reserved control string may have been inadverdently redefined. There is also the possibility that TEX will run out of room (see The TEXbook, p. 300), most likely because there are too many macros that are too big. The macros that TIb creates are not particularly space efficient. None the less, they seem to have no trouble coexisting with the macros of L^{A}TEX or AMS-TEX. However, these macros together with a collection of private macros may be too much. In this regard, see The TEXbook, appendix D.4. It is also true that there is much room for compactification in the macros TIb creates. In particular, for any particular input document, many of the macros are probably not used and can be physically eliminated from the appropriate .ttx files.

It is hoped, however, that all your TEXnical referencing is trouble-free and that you never have read this section.

Disclaimer

In no event will the author be liable for any damages, including any lost profits, or other incidental or consequential damages arising out the use of or inability to use this program, even if the author has been advised of the possibility of such damages, or for any claim by any other party.

TIb A1. Appendix: the example document — 24

• A1. Appendix: the example document

%           EXAMPLE PAGE FOR TIB -- FOR USE WITH test.refs
%
%       For plain TeX: adjust \vglue just below if necessary.
%       For footnotes (demo.6.p) comment out (%) the line "\vsize ..."
%       just below and the line near the end beginning ".[]".
%
%       For LaTeX, comment out (%) the line "\vsize ..." just below
%       and activate the three indicated lines.  Also activate the
%       line "\end{document}" near the end.  For footnotes (demo.6.l)
%       comment out the second of the three lines and the line near
%       the end beginning ".[]".
%
%   next line for plain TeX
\vsize10.3truein\nopagenumbers\vglue-.5truein% adjust \vglue if necessary
%
%   next 3 lines for LaTeX
%\documentstyle{article}\textwidth6.5truein\nofiles\oddsidemargin=0truein
%\pagestyle{empty}\textheight10.3truein\topmargin=-.7truein
%\begin{document}
\centerline{\bf Example Test Page}\smallskip
This example shows a citation for a book,[.griswold poage polonsky.]
a journal article,[.dieck.] a conference paper,[.lerch crustal.]
a technical report,[.lerch patel.] an article in a book,[.hoare engeler.]
and something that fits in no category.[.reagan.]  Multiple citations
[.brooks, hoare engeler.] look like this---or this,%
[.brooks.].[.hoare engeler.]  A run of citations [.derham, sra, knuth, tassel.]
can sometimes be hyphenated.  The alternate citation style, for referring to
reference <.knuth.> in running text, is different.  Extra text can be
inserted in citations.[.griswold poage polonsky <, chap.~2>.]  Translations
can be referenced.[.arnold equations, arnold singularities,gantmacher.]
If necessary, letters are appended to citations to remove ambiguities.
If desired, citations can be sorted by any of several templates.[.lerch
crustal,lerch putney,hoare elba,hoare engeler.]  If there are no authors,
editors are used instead;[.peitgen walther.] if there are also no editors, the
publishing institution is used.[.sra.]  Sorting and citation creation is
based on the first capital letter in the last name.[.tassel,dieck,derham.]
Special strings can be part of references [.tex,momentum harmonic,derham,rapp.]
and special citation strings can be used.[.sra.]  Also note
the performance of the abbreviation routine.[.thompson,peitgen.]
.[]\smallskip\centerline{\bf References}\smallskip  %comment out for footnotes
%\end{document}  %LaTeX
\bye  %plain TeX