1606 lines
28 KiB
HTML
1606 lines
28 KiB
HTML
|
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
|
<HTML><HEAD><TITLE>Man page of EQN</TITLE>
|
|
</HEAD><BODY>
|
|
<H1>EQN</H1>
|
|
Section: User Commands (1)<BR>Updated: 21 March 2020<BR><A HREF="#index">Index</A>
|
|
<A HREF="/cgi-bin/man/man2html">Return to Main Contents</A><HR>
|
|
|
|
<A NAME="lbAB"> </A>
|
|
<H2>NAME</H2>
|
|
|
|
eqn - format equations for troff or MathML
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<A NAME="lbAC"> </A>
|
|
<H2>SYNOPSIS</H2>
|
|
|
|
|
|
|
|
[ <B>-rvCNR</B> ]
|
|
|
|
[ <B>-d </B><I>xy</I> ]
|
|
|
|
[ <B>-T </B><I>name</I> ]
|
|
|
|
[ <B>-M </B><I>dir</I> ]
|
|
|
|
[ <B>-f </B><I>F</I> ]
|
|
|
|
[ <B>-s </B><I>n</I> ]
|
|
|
|
[ <B>-p </B><I>n</I> ]
|
|
|
|
[ <B>-m </B><I>n</I> ]
|
|
|
|
[<I>file</I>
|
|
|
|
...]
|
|
|
|
|
|
<A NAME="lbAD"> </A>
|
|
<H2>DESCRIPTION</H2>
|
|
|
|
|
|
This manual page describes the GNU version of
|
|
<B>eqn</B>,
|
|
|
|
which is part of the groff document formatting system.
|
|
<B>eqn</B>
|
|
|
|
compiles descriptions of equations embedded within
|
|
<B>troff</B>
|
|
|
|
input files into commands that are understood by
|
|
<B>troff</B>.
|
|
|
|
Normally, it should be invoked using the
|
|
<B>-e</B>
|
|
|
|
option of
|
|
<B>groff</B>.
|
|
|
|
The syntax is quite compatible with Unix eqn.
|
|
The output of GNU
|
|
<B>eqn</B>
|
|
|
|
cannot be processed with Unix troff;
|
|
it must be processed with GNU troff.
|
|
If no files are given on the command line, the standard input is read.
|
|
A filename of
|
|
<B>-</B>
|
|
|
|
causes the standard input to be read.
|
|
<P>
|
|
|
|
<B>eqn</B>
|
|
|
|
searches for the file
|
|
<I>eqnrc</I>
|
|
|
|
in the directories given with the
|
|
<B>-M</B>
|
|
|
|
option first, then in
|
|
<I>/usr/:lib/:groff/:site-tmac</I>,
|
|
|
|
<I>/usr/:share/:groff/:site-tmac</I>,
|
|
|
|
and finally in the standard macro directory
|
|
<I>/usr/:share/:groff/:1.22.4/:tmac</I>.
|
|
|
|
If it exists,
|
|
<B>eqn</B>
|
|
|
|
processes it before the other input files.
|
|
The
|
|
<B>-R</B>
|
|
|
|
option prevents this.
|
|
<P>
|
|
|
|
GNU
|
|
<B>eqn</B>
|
|
|
|
does not provide the functionality of neqn:
|
|
it does not support low-resolution, typewriter-like devices
|
|
(although it may work adequately for very simple input).
|
|
|
|
<A NAME="lbAE"> </A>
|
|
<H2>OPTIONS</H2>
|
|
|
|
|
|
Whitespace is permitted between a command-line option and its argument.
|
|
<DL COMPACT>
|
|
<DT id="1"><B>-d</B><I>xy</I>
|
|
|
|
<DD>
|
|
Specify delimiters
|
|
<I>x</I>
|
|
|
|
and~<I>y</I>
|
|
|
|
for the left and right end, respectively, of in-line equations.
|
|
Any
|
|
<B>delim</B>
|
|
|
|
statements in the source file overrides this.
|
|
<DT id="2"><B>-C</B>
|
|
|
|
<DD>
|
|
Recognize
|
|
<B>.EQ</B>
|
|
|
|
and
|
|
<B>.EN</B>
|
|
|
|
even when followed by a character other than space or newline.
|
|
Also, the statement
|
|
'<B>delim on</B>'
|
|
|
|
is not handled specially.
|
|
<DT id="3"><B>-N</B>
|
|
|
|
<DD>
|
|
Don't allow newlines within delimiters.
|
|
This option allows
|
|
<B>eqn</B>
|
|
|
|
to recover better from missing closing delimiters.
|
|
<DT id="4"><B>-v</B>
|
|
|
|
<DD>
|
|
Print the version number.
|
|
<DT id="5"><B>-r</B>
|
|
|
|
<DD>
|
|
Only one size reduction.
|
|
<DT id="6"><B>-m</B><I>n</I>
|
|
|
|
<DD>
|
|
The minimum point-size is~<I>n</I>.
|
|
|
|
<B>eqn</B>
|
|
|
|
does not reduce the size of subscripts or superscripts to
|
|
a smaller size than~<I>n</I>.
|
|
|
|
<DT id="7"><B>-T</B><I>name</I>
|
|
|
|
<DD>
|
|
The output is for device
|
|
<I>name</I>.
|
|
|
|
Normally, the only effect of this is to define a macro
|
|
<I>name</I>
|
|
|
|
with a value of~<B>1</B>;
|
|
|
|
<I>eqnrc</I>
|
|
|
|
uses this to provide definitions appropriate for the output device.
|
|
However, if the specified device is "MathML", the output is
|
|
MathML markup rather than troff commands, and
|
|
<I>eqnrc</I>
|
|
|
|
is not loaded at all.
|
|
The default output device is
|
|
<B>ps</B>.
|
|
|
|
<DT id="8"><B>-M</B><I>dir</I>
|
|
|
|
<DD>
|
|
Search
|
|
<I>dir</I>
|
|
|
|
for
|
|
<I>eqnrc</I>
|
|
|
|
before the default directories.
|
|
<DT id="9"><B>-R</B>
|
|
|
|
<DD>
|
|
Don't load
|
|
<I>eqnrc</I>.
|
|
|
|
<DT id="10"><B>-f</B><I>F</I>
|
|
|
|
<DD>
|
|
This is equivalent to a
|
|
<B>gfont </B><I>F</I>
|
|
|
|
command.
|
|
<DT id="11"><B>-s</B><I>n</I>
|
|
|
|
<DD>
|
|
This is equivalent to a
|
|
<B>gsize </B><I>n</I>
|
|
|
|
command.
|
|
This option is deprecated.
|
|
<B>eqn</B>
|
|
|
|
normally sets equations at whatever the current point size
|
|
is when the equation is encountered.
|
|
<DT id="12"><B>-p</B><I>n</I>
|
|
|
|
<DD>
|
|
This says that subscripts and superscripts should be
|
|
<I>n</I>~points
|
|
|
|
smaller than the surrounding text.
|
|
This option is deprecated.
|
|
Normally
|
|
<B>eqn</B>
|
|
|
|
sets subscripts and superscripts at 70% of the size of the surrounding
|
|
text.
|
|
|
|
</DL>
|
|
<A NAME="lbAF"> </A>
|
|
<H2>USAGE</H2>
|
|
|
|
|
|
Only the differences between GNU
|
|
<B>eqn</B>
|
|
|
|
and Unix eqn are described here.
|
|
<P>
|
|
|
|
GNU
|
|
<B>eqn</B>
|
|
|
|
emits Presentation MathML output when invoked with the
|
|
<B>-T~MathML</B>
|
|
|
|
option.
|
|
<P>
|
|
|
|
GNU eqn sets the input token
|
|
<B>...</B>
|
|
|
|
as three periods or low dots, rather than the three centered dots of
|
|
classic eqn. To get three centered dots, write
|
|
<B>cdots</B>
|
|
|
|
or
|
|
<B>cdot cdot cdot.</B>
|
|
|
|
<P>
|
|
|
|
Most of the new features of the GNU
|
|
<B>eqn</B>
|
|
|
|
input language are based on TeX.
|
|
There are some references to the differences between TeX and GNU
|
|
<B>eqn</B>
|
|
|
|
below;
|
|
these may safely be ignored if you do not know TeX.
|
|
|
|
<A NAME="lbAG"> </A>
|
|
<H3>Controlling delimiters</H3>
|
|
|
|
|
|
If not in compatibility mode,
|
|
<B>eqn</B>
|
|
|
|
recognizes
|
|
<DL COMPACT><DT id="13"><DD>
|
|
<P>
|
|
|
|
<B>delim on</B>
|
|
|
|
</DL>
|
|
|
|
<P>
|
|
|
|
to restore the delimiters which have been previously disabled
|
|
with a call to
|
|
'<B>delim off</B>'.
|
|
|
|
If delimiters haven't been specified, the call has no effect.
|
|
|
|
<A NAME="lbAH"> </A>
|
|
<H3>Automatic spacing</H3>
|
|
|
|
|
|
<B>eqn</B>
|
|
|
|
gives each component of an equation a type, and adjusts the spacing
|
|
between components using that type.
|
|
Possible types are described in the table below.
|
|
<TABLE>
|
|
<TR VALIGN=top><TD><B>ordinary</B></TD><TD>
|
|
an ordinary character such as '1' or
|
|
'<I>x</I>'
|
|
|
|
<BR></TD></TR>
|
|
<TR VALIGN=top><TD><B>operator</B></TD><TD>
|
|
a large operator such as
|
|
|
|
|
|
'<FONT SIZE="+5">Σ</FONT>'
|
|
<BR></TD></TR>
|
|
<TR VALIGN=top><TD><B>binary</B></TD><TD>a binary operator such as '+'<BR></TD></TR>
|
|
<TR VALIGN=top><TD><B>relation</B></TD><TD>a relation such as '='<BR></TD></TR>
|
|
<TR VALIGN=top><TD><B>opening</B></TD><TD>a opening bracket such as '('<BR></TD></TR>
|
|
<TR VALIGN=top><TD><B>closing</B></TD><TD>a closing bracket such as ')'<BR></TD></TR>
|
|
<TR VALIGN=top><TD><B>punctuation</B></TD><TD>a punctuation character such as ','<BR></TD></TR>
|
|
<TR VALIGN=top><TD><B>inner</B></TD><TD>a subformula contained within brackets<BR></TD></TR>
|
|
<TR VALIGN=top><TD><B>suppress</B></TD><TD>a type that suppresses automatic spacing adjustment<BR></TD></TR>
|
|
</TABLE>
|
|
|
|
<P>
|
|
|
|
Components of an equation
|
|
get a type in one of two ways.
|
|
<DL COMPACT>
|
|
<DT id="14"><B>type </B><I>t e</I>
|
|
|
|
<DD>
|
|
This yields an equation component that contains~<I>e</I>
|
|
|
|
but that has type~<I>t</I>,
|
|
|
|
where
|
|
<I>t</I>
|
|
|
|
is one of the types mentioned above.
|
|
For example,
|
|
<B>times</B>
|
|
|
|
is defined as
|
|
<DL COMPACT><DT id="15"><DD>
|
|
<DL COMPACT>
|
|
<DT id="16"><DD>
|
|
<B>type "binary" \(mu</B>
|
|
|
|
</DL>
|
|
</DL>
|
|
|
|
<DT id="17"><DD>
|
|
The name of the type doesn't have to be quoted, but quoting protects
|
|
from macro expansion.
|
|
<DT id="18"><B>chartype </B><I>t text</I>
|
|
|
|
<DD>
|
|
Unquoted groups of characters are split up into individual characters,
|
|
and the type of each character is looked up;
|
|
this changes the type that is stored for each character;
|
|
it says that the characters in
|
|
<I>text</I>
|
|
|
|
from now on have type~<I>t</I>.
|
|
|
|
For example,
|
|
<DL COMPACT><DT id="19"><DD>
|
|
<DL COMPACT>
|
|
<DT id="20"><DD>
|
|
<B>chartype "punctuation" .,;:</B>
|
|
|
|
</DL>
|
|
</DL>
|
|
|
|
<DT id="21"><DD>
|
|
would make the characters '.,;:' have type punctuation
|
|
whenever they subsequently appeared in an equation.
|
|
The type~<I>t</I>
|
|
|
|
can also be
|
|
<B>letter</B>
|
|
|
|
or
|
|
<B>digit</B>;
|
|
|
|
in these cases
|
|
<B>chartype</B>
|
|
|
|
changes the font type of the characters.
|
|
See subsection "Fonts" below.
|
|
|
|
</DL>
|
|
<A NAME="lbAI"> </A>
|
|
<H3>New primitives</H3>
|
|
|
|
|
|
<DL COMPACT>
|
|
<DT id="22"><B>big </B><I>e</I>
|
|
|
|
<DD>
|
|
Enlarges the expression it modifies; intended to have semantics like
|
|
CSS 'large'.
|
|
In troff output, the point size is increased by~5; in MathML output,
|
|
the expression uses
|
|
<DL COMPACT><DT id="23"><DD>
|
|
<DL COMPACT>
|
|
<DT id="24"><DD>
|
|
|
|
<mstyle mathsize='big'>
|
|
|
|
</DL>
|
|
</DL>
|
|
|
|
<DT id="25"><I>e1 </I><B>smallover </B><I>e2</I>
|
|
|
|
<DD>
|
|
This is similar to
|
|
<B>over</B>;
|
|
|
|
<B>smallover</B>
|
|
|
|
reduces the size of
|
|
<I>e1</I>
|
|
|
|
and
|
|
<I>e2</I>;
|
|
|
|
it also puts less vertical space between
|
|
<I>e1</I>
|
|
|
|
or
|
|
<I>e2</I>
|
|
|
|
and the fraction bar.
|
|
The
|
|
<B>over</B>
|
|
|
|
primitive corresponds to the TeX
|
|
<B>\over</B>
|
|
|
|
primitive in display styles;
|
|
<B>smallover</B>
|
|
|
|
corresponds to
|
|
<B>\over</B>
|
|
|
|
in non-display styles.
|
|
<DT id="26"><B>vcenter </B><I>e</I>
|
|
|
|
<DD>
|
|
This vertically centers
|
|
<I>e</I>
|
|
|
|
about the math axis.
|
|
The math axis is the vertical position about which characters such as
|
|
'+' and '-' are centered; also it is the
|
|
vertical position used for the bar of fractions.
|
|
For example,
|
|
<B>sum</B>
|
|
|
|
is defined as
|
|
<DL COMPACT><DT id="27"><DD>
|
|
<DL COMPACT>
|
|
<DT id="28"><DD>
|
|
<B>{ type "operator" vcenter size +5 \(*S }</B>
|
|
|
|
</DL>
|
|
</DL>
|
|
|
|
<DT id="29"><DD>
|
|
(Note that vcenter is silently ignored when generating MathML.)
|
|
<DT id="30"><I>e1 </I><B>accent </B><I>e2</I>
|
|
|
|
<DD>
|
|
This sets
|
|
<I>e2</I>
|
|
|
|
as an accent over
|
|
<I>e1</I>.
|
|
|
|
<I>e2</I>
|
|
|
|
is assumed to be at the correct height for a lowercase letter;
|
|
<I>e2</I>
|
|
|
|
is moved down according to whether
|
|
<I>e1</I>
|
|
|
|
is taller or shorter than a lowercase letter.
|
|
For example,
|
|
<B>hat</B>
|
|
|
|
is defined as
|
|
<DL COMPACT><DT id="31"><DD>
|
|
<DL COMPACT>
|
|
<DT id="32"><DD>
|
|
<B>accent { "^" }</B>
|
|
|
|
</DL>
|
|
</DL>
|
|
|
|
<DT id="33"><DD>
|
|
<B>dotdot</B>,
|
|
|
|
<B>dot</B>,
|
|
|
|
<B>tilde</B>,
|
|
|
|
<B>vec</B>,
|
|
|
|
and
|
|
<B>dyad</B>
|
|
|
|
are also defined using the
|
|
<B>accent</B>
|
|
|
|
primitive.
|
|
<DT id="34"><I>e1 </I><B>uaccent </B><I>e2</I>
|
|
|
|
<DD>
|
|
This sets
|
|
<I>e2</I>
|
|
|
|
as an accent under
|
|
<I>e1</I>.
|
|
|
|
<I>e2</I>
|
|
|
|
is assumed to be at the correct height for a character without a descender;
|
|
<I>e2</I>
|
|
|
|
is moved down if
|
|
<I>e1</I>
|
|
|
|
has a descender.
|
|
<B>utilde</B>
|
|
|
|
is pre-defined using
|
|
<B>uaccent</B>
|
|
|
|
as a tilde accent below the baseline.
|
|
<DT id="35"><B>split "</B><I>text</I><B>"</B>
|
|
|
|
<DD>
|
|
This has the same effect as simply
|
|
<DL COMPACT><DT id="36"><DD>
|
|
<DL COMPACT>
|
|
<DT id="37"><DD>
|
|
<I>text</I>
|
|
|
|
</DL>
|
|
</DL>
|
|
|
|
<DT id="38"><DD>
|
|
but
|
|
<I>text</I>
|
|
|
|
is not subject to macro expansion because it is quoted;
|
|
<I>text</I>
|
|
|
|
is split up and the spacing between individual characters is adjusted.
|
|
<DT id="39"><B>nosplit </B><I>text</I>
|
|
|
|
<DD>
|
|
This has the same effect as
|
|
<DL COMPACT><DT id="40"><DD>
|
|
<DL COMPACT>
|
|
<DT id="41"><DD>
|
|
<B>"</B><I>text</I><B>"</B>
|
|
|
|
</DL>
|
|
</DL>
|
|
|
|
<DT id="42"><DD>
|
|
but because
|
|
<I>text</I>
|
|
|
|
is not quoted it is subject to macro expansion;
|
|
<I>text</I>
|
|
|
|
is not split up
|
|
and the spacing between individual characters is not adjusted.
|
|
<DT id="43"><I>e </I><B>opprime</B>
|
|
|
|
<DD>
|
|
This is a variant of
|
|
<B>prime</B>
|
|
|
|
that acts as an operator on~<I>e</I>.
|
|
|
|
It produces a different result from
|
|
<B>prime</B>
|
|
|
|
in a case such as
|
|
<B>A opprime sub 1</B>:
|
|
|
|
with
|
|
<B>opprime</B>
|
|
|
|
the~<B>1</B>
|
|
|
|
is tucked under the prime as a subscript to the~<B>A</B>
|
|
|
|
(as is conventional in mathematical typesetting),
|
|
whereas with
|
|
<B>prime</B>
|
|
|
|
the~<B>1</B>
|
|
|
|
is a subscript to the prime character.
|
|
The precedence of
|
|
<B>opprime</B>
|
|
|
|
is the same as that of
|
|
<B>bar</B>
|
|
|
|
and
|
|
<B>under</B>,
|
|
|
|
which is higher than that of everything except
|
|
<B>accent</B>
|
|
|
|
and
|
|
<B>uaccent</B>.
|
|
|
|
In unquoted text a~<B>'</B>
|
|
|
|
that is not the first character is treated like
|
|
<B>opprime</B>.
|
|
|
|
<DT id="44"><B>special </B><I>text e</I>
|
|
|
|
<DD>
|
|
This constructs a new object from~<I>e</I>
|
|
|
|
using a
|
|
<B><A HREF="/cgi-bin/man/man2html?1+troff">troff</A></B>(1)
|
|
|
|
macro named
|
|
<I>text</I>.
|
|
|
|
When the macro is called,
|
|
the string
|
|
<B>0s</B>
|
|
|
|
contains the output for~<I>e</I>,
|
|
|
|
and the number registers
|
|
<B>0w</B>,
|
|
|
|
<B>0h</B>,
|
|
|
|
<B>0d</B>,
|
|
|
|
<B>0skern</B>,
|
|
|
|
and
|
|
<B>0skew</B>
|
|
|
|
contain the width, height, depth, subscript kern, and skew of~<I>e</I>.
|
|
|
|
(The
|
|
<I>subscript kern</I>
|
|
|
|
of an object says how much a subscript on that object should be tucked in;
|
|
the
|
|
<I>skew</I>
|
|
|
|
of an object says how far to the right of the center of the object an
|
|
accent over the object should be placed.)
|
|
The macro must modify
|
|
<B>0s</B>
|
|
|
|
so that it outputs the desired result with its origin at the current
|
|
point, and increase the current horizontal position by the width
|
|
of the object.
|
|
The number registers must also be modified so that they correspond to the
|
|
result.
|
|
<DT id="45"><DD>
|
|
For example, suppose you wanted a construct that 'cancels' an
|
|
expression by drawing a diagonal line through it.
|
|
<DL COMPACT><DT id="46"><DD>
|
|
<DL COMPACT>
|
|
<DT id="47"><DD>
|
|
<B>
|
|
|
|
<BR>
|
|
|
|
.EQ
|
|
<BR>
|
|
|
|
define cancel 'special Ca'
|
|
<BR>
|
|
|
|
.EN
|
|
<BR>
|
|
|
|
.de Ca
|
|
<BR>
|
|
|
|
. ds 0s \
|
|
<BR>
|
|
|
|
\Z'\\*(0s'\
|
|
<BR>
|
|
|
|
\v'\\n(0du'\
|
|
<BR>
|
|
|
|
\D'l \\n(0wu -\\n(0hu-\\n(0du'\
|
|
<BR>
|
|
|
|
\v'\\n(0hu'
|
|
<BR>
|
|
|
|
..
|
|
</B>
|
|
</DL>
|
|
</DL>
|
|
|
|
<DT id="48"><DD>
|
|
Then you could cancel an expression~<I>e</I>
|
|
|
|
with
|
|
<B>cancel { </B><I>e </I><B>}</B>
|
|
|
|
<DT id="49"><DD>
|
|
Here's a more complicated construct that draws a box round an
|
|
expression:
|
|
<DL COMPACT><DT id="50"><DD>
|
|
<DL COMPACT>
|
|
<DT id="51"><DD>
|
|
<B>
|
|
|
|
.EQ
|
|
<BR>
|
|
|
|
define box 'special Bx'
|
|
<BR>
|
|
|
|
.EN
|
|
<BR>
|
|
|
|
.de Bx
|
|
<BR>
|
|
|
|
. ds 0s \
|
|
<BR>
|
|
|
|
\Z'\h'1n'\\*(0s'\
|
|
<BR>
|
|
|
|
\Z'\
|
|
<BR>
|
|
|
|
\v'\\n(0du+1n'\
|
|
<BR>
|
|
|
|
\D'l \\n(0wu+2n 0'\
|
|
<BR>
|
|
|
|
\D'l 0 -\\n(0hu-\\n(0du-2n'\
|
|
<BR>
|
|
|
|
\D'l -\\n(0wu-2n 0'\
|
|
<BR>
|
|
|
|
\D'l 0 \\n(0hu+\\n(0du+2n'\
|
|
<BR>
|
|
|
|
'\
|
|
<BR>
|
|
|
|
\h'\\n(0wu+2n'
|
|
<BR>
|
|
|
|
. nr 0w +2n
|
|
<BR>
|
|
|
|
. nr 0d +1n
|
|
<BR>
|
|
|
|
. nr 0h +1n
|
|
<BR>
|
|
|
|
..
|
|
</B>
|
|
</DL>
|
|
</DL>
|
|
|
|
<DT id="52"><B>space </B><I>n</I>
|
|
|
|
<DD>
|
|
A positive value of the integer~<I>n</I>
|
|
|
|
(in hundredths of an em) sets the vertical spacing before the
|
|
equation, a negative value sets the spacing after the equation,
|
|
replacing the default values.
|
|
This primitive provides an interface to
|
|
<B>groff</B>'s
|
|
|
|
<B>\x</B>
|
|
|
|
escape (but with opposite sign).
|
|
<DT id="53"><DD>
|
|
This keyword has no effect if the equation is part of a
|
|
<B>pic</B>
|
|
|
|
picture.
|
|
|
|
</DL>
|
|
<A NAME="lbAJ"> </A>
|
|
<H3>Extended primitives</H3>
|
|
|
|
|
|
<DL COMPACT>
|
|
<DT id="54"><B>col </B><I>n </I><B>{ </B><I>... </I><B>}</B>
|
|
|
|
<DD>
|
|
|
|
<B>ccol </B><I>n </I><B>{ </B><I>... </I><B>}</B>
|
|
|
|
|
|
<B>lcol </B><I>n </I><B>{ </B><I>... </I><B>}</B>
|
|
|
|
|
|
<B>rcol </B><I>n </I><B>{ </B><I>... </I><B>}</B>
|
|
|
|
|
|
<B>pile </B><I>n </I><B>{ </B><I>... </I><B>}</B>
|
|
|
|
|
|
<B>cpile </B><I>n </I><B>{ </B><I>... </I><B>}</B>
|
|
|
|
|
|
<B>lpile </B><I>n </I><B>{ </B><I>... </I><B>}</B>
|
|
|
|
|
|
<B>rpile </B><I>n </I><B>{ </B><I>... </I><B>}</B>
|
|
|
|
The integer value~<I>n</I>
|
|
|
|
(in hundredths of an em) increases the vertical spacing between rows,
|
|
using
|
|
<B>groff</B>'s
|
|
|
|
<B>\x</B>
|
|
|
|
escape (the value has no effect in MathML mode).
|
|
Negative values are possible but have no effect.
|
|
If there is more than a single value given in a matrix, the biggest one
|
|
is used.
|
|
|
|
</DL>
|
|
<A NAME="lbAK"> </A>
|
|
<H3>Customization</H3>
|
|
|
|
|
|
When
|
|
<B>eqn</B>
|
|
|
|
is generating troff markup, the appearance of equations is controlled
|
|
by a large number of parameters.
|
|
They have no effect when generating MathML mode, which pushes
|
|
typesetting and fine motions downstream to a MathML rendering engine.
|
|
These parameters can be set using the
|
|
<B>set</B>
|
|
|
|
command.
|
|
<DL COMPACT>
|
|
<DT id="55"><B>set </B><I>p n</I>
|
|
|
|
<DD>
|
|
This sets parameter~<I>p</I>
|
|
|
|
to value~<I>n</I>;
|
|
|
|
<I>n</I>~is
|
|
|
|
an integer.
|
|
For example,
|
|
<DL COMPACT><DT id="56"><DD>
|
|
<DL COMPACT>
|
|
<DT id="57"><DD>
|
|
<B>set x_height 45</B>
|
|
|
|
</DL>
|
|
</DL>
|
|
|
|
<DT id="58"><DD>
|
|
says that
|
|
<B>eqn</B>
|
|
|
|
should assume an x~height of 0.45~ems.
|
|
<DL COMPACT><DT id="59"><DD>
|
|
<P>
|
|
|
|
Possible parameters are as follows.
|
|
Values are in units of hundredths of an em unless otherwise stated.
|
|
These descriptions are intended to be expository rather than
|
|
definitive.
|
|
<DL COMPACT>
|
|
<DT id="60"><B>minimum_size</B>
|
|
|
|
<DD>
|
|
<B>eqn</B>
|
|
|
|
doesn't set anything at a smaller point-size than this.
|
|
The value is in points.
|
|
<DT id="61"><B>fat_offset</B>
|
|
|
|
<DD>
|
|
The
|
|
<B>fat</B>
|
|
|
|
primitive emboldens an equation by overprinting two copies of the
|
|
equation horizontally offset by this amount.
|
|
This parameter is not used in MathML mode; instead, fat text uses
|
|
<DL COMPACT><DT id="62"><DD>
|
|
<DL COMPACT>
|
|
<DT id="63"><DD>
|
|
|
|
<mstyle mathvariant='double-struck'>
|
|
|
|
</DL>
|
|
</DL>
|
|
|
|
<DT id="64"><B>over_hang</B>
|
|
|
|
<DD>
|
|
A fraction bar is longer by twice this amount than
|
|
the maximum of the widths of the numerator and denominator;
|
|
in other words, it overhangs the numerator and
|
|
denominator by at least this amount.
|
|
<DT id="65"><B>accent_width</B>
|
|
|
|
<DD>
|
|
When
|
|
<B>bar</B>
|
|
|
|
or
|
|
<B>under</B>
|
|
|
|
is applied to a single character,
|
|
the line is this long.
|
|
Normally,
|
|
<B>bar</B>
|
|
|
|
or
|
|
<B>under</B>
|
|
|
|
produces a line whose length is the width of the object to which it applies;
|
|
in the case of a single character,
|
|
this tends to produce a line that looks too long.
|
|
<DT id="66"><B>delimiter_factor</B>
|
|
|
|
<DD>
|
|
Extensible delimiters produced with the
|
|
<B>left</B>
|
|
|
|
and
|
|
<B>right</B>
|
|
|
|
primitives have a combined height and depth of at least this many
|
|
thousandths of twice the maximum amount by which the sub-equation that
|
|
the delimiters enclose extends away from the axis.
|
|
<DT id="67"><B>delimiter_shortfall</B>
|
|
|
|
<DD>
|
|
Extensible delimiters produced with the
|
|
<B>left</B>
|
|
|
|
and
|
|
<B>right</B>
|
|
|
|
primitives have a combined height and depth not less than the
|
|
difference of twice the maximum amount by which the sub-equation that
|
|
the delimiters enclose extends away from the axis and this amount.
|
|
<DT id="68"><B>null_delimiter_space</B>
|
|
|
|
<DD>
|
|
This much horizontal space is inserted on each side of a fraction.
|
|
<DT id="69"><B>script_space</B>
|
|
|
|
<DD>
|
|
The width of subscripts and superscripts is increased by this amount.
|
|
<DT id="70"><B>thin_space</B>
|
|
|
|
<DD>
|
|
This amount of space is automatically inserted after punctuation
|
|
characters.
|
|
<DT id="71"><B>medium_space</B>
|
|
|
|
<DD>
|
|
This amount of space is automatically inserted on either side of
|
|
binary operators.
|
|
<DT id="72"><B>thick_space</B>
|
|
|
|
<DD>
|
|
This amount of space is automatically inserted on either side of
|
|
relations.
|
|
<DT id="73"><B>x_height</B>
|
|
|
|
<DD>
|
|
The height of lowercase letters without ascenders such as 'x'.
|
|
<DT id="74"><B>axis_height</B>
|
|
|
|
<DD>
|
|
The height above the baseline of the center of characters such as
|
|
'+' and '-'.
|
|
It is important that this value is correct for the font
|
|
you are using.
|
|
<DT id="75"><B>default_rule_thickness</B>
|
|
|
|
<DD>
|
|
This should set to the thickness of the
|
|
<B>\(ru</B>
|
|
|
|
character, or the thickness of horizontal lines produced with the
|
|
<B>\D</B>
|
|
|
|
escape sequence.
|
|
<DT id="76"><B>num1</B>
|
|
|
|
<DD>
|
|
The
|
|
<B>over</B>
|
|
|
|
command shifts up the numerator by at least this amount.
|
|
<DT id="77"><B>num2</B>
|
|
|
|
<DD>
|
|
The
|
|
<B>smallover</B>
|
|
|
|
command shifts up the numerator by at least this amount.
|
|
<DT id="78"><B>denom1</B>
|
|
|
|
<DD>
|
|
The
|
|
<B>over</B>
|
|
|
|
command shifts down the denominator by at least this amount.
|
|
<DT id="79"><B>denom2</B>
|
|
|
|
<DD>
|
|
The
|
|
<B>smallover</B>
|
|
|
|
command shifts down the denominator by at least this amount.
|
|
<DT id="80"><B>sup1</B>
|
|
|
|
<DD>
|
|
Normally superscripts are shifted up by at least this amount.
|
|
<DT id="81"><B>sup2</B>
|
|
|
|
<DD>
|
|
Superscripts within superscripts or upper limits
|
|
or numerators of
|
|
<B>smallover</B>
|
|
|
|
fractions are shifted up by at least this amount.
|
|
This is usually less than sup1.
|
|
<DT id="82"><B>sup3</B>
|
|
|
|
<DD>
|
|
Superscripts within denominators or square roots
|
|
or subscripts or lower limits are shifted up by at least
|
|
this amount.
|
|
This is usually less than sup2.
|
|
<DT id="83"><B>sub1</B>
|
|
|
|
<DD>
|
|
Subscripts are normally shifted down by at least this amount.
|
|
<DT id="84"><B>sub2</B>
|
|
|
|
<DD>
|
|
When there is both a subscript and a superscript, the subscript is
|
|
shifted down by at least this amount.
|
|
<DT id="85"><B>sup_drop</B>
|
|
|
|
<DD>
|
|
The baseline of a superscript is no more than this much amount below
|
|
the top of the object on which the superscript is set.
|
|
<DT id="86"><B>sub_drop</B>
|
|
|
|
<DD>
|
|
The baseline of a subscript is at least this much below the bottom of
|
|
the object on which the subscript is set.
|
|
<DT id="87"><B>big_op_spacing1</B>
|
|
|
|
<DD>
|
|
The baseline of an upper limit is at least this much above the top of
|
|
the object on which the limit is set.
|
|
<DT id="88"><B>big_op_spacing2</B>
|
|
|
|
<DD>
|
|
The baseline of a lower limit is at least this much below the bottom
|
|
of the object on which the limit is set.
|
|
<DT id="89"><B>big_op_spacing3</B>
|
|
|
|
<DD>
|
|
The bottom of an upper limit is at least this much above the top of
|
|
the object on which the limit is set.
|
|
<DT id="90"><B>big_op_spacing4</B>
|
|
|
|
<DD>
|
|
The top of a lower limit is at least this much below the bottom of the
|
|
object on which the limit is set.
|
|
<DT id="91"><B>big_op_spacing5</B>
|
|
|
|
<DD>
|
|
This much vertical space is added above and below limits.
|
|
<DT id="92"><B>baseline_sep</B>
|
|
|
|
<DD>
|
|
The baselines of the rows in a pile or matrix are normally this far
|
|
apart.
|
|
In most cases this should be equal to the sum of
|
|
<B>num1</B>
|
|
|
|
and
|
|
<B>denom1</B>.
|
|
|
|
<DT id="93"><B>shift_down</B>
|
|
|
|
<DD>
|
|
The midpoint between the top baseline and the bottom baseline in a
|
|
matrix or pile is shifted down by this much from the axis.
|
|
In most cases this should be equal to
|
|
<B>axis_height</B>.
|
|
|
|
<DT id="94"><B>column_sep</B>
|
|
|
|
<DD>
|
|
This much space is added between columns in a matrix.
|
|
<DT id="95"><B>matrix_side_sep</B>
|
|
|
|
<DD>
|
|
This much space is added at each side of a matrix.
|
|
<DT id="96"><B>draw_lines</B>
|
|
|
|
<DD>
|
|
If this is non-zero, lines are drawn using the
|
|
<B>\D</B>
|
|
|
|
escape sequence, rather than with the
|
|
<B>\l</B>
|
|
|
|
escape sequence and the
|
|
<B>\(ru</B>
|
|
|
|
character.
|
|
<DT id="97"><B>body_height</B>
|
|
|
|
<DD>
|
|
The amount by which the height of the equation exceeds this is added
|
|
as extra space before the line containing the equation (using
|
|
<B>\x</B>).
|
|
|
|
The default value is 85.
|
|
<DT id="98"><B>body_depth</B>
|
|
|
|
<DD>
|
|
The amount by which the depth of the equation exceeds this is added as
|
|
extra space after the line containing the equation (using
|
|
<B>\x</B>).
|
|
|
|
The default value is 35.
|
|
<DT id="99"><B>nroff</B>
|
|
|
|
<DD>
|
|
If this is non-zero,
|
|
then
|
|
<B>ndefine</B>
|
|
|
|
behaves like
|
|
<B>define</B>
|
|
|
|
and
|
|
<B>tdefine</B>
|
|
|
|
is ignored, otherwise
|
|
<B>tdefine</B>
|
|
|
|
behaves like
|
|
<B>define</B>
|
|
|
|
and
|
|
<B>ndefine</B>
|
|
|
|
is ignored.
|
|
The default value is~0 (This is typically changed to~1 by the
|
|
<I>eqnrc</I>
|
|
|
|
file for the
|
|
<B>ascii</B>,
|
|
|
|
<B>latin1</B>,
|
|
|
|
<B>utf8</B>,
|
|
|
|
and
|
|
<B>cp1047</B>
|
|
|
|
devices.)
|
|
</DL>
|
|
<P>
|
|
|
|
A more precise description of the role of many of these
|
|
parameters can be found in Appendix~H of
|
|
<I>The TeXbook</I>.
|
|
|
|
</DL>
|
|
|
|
|
|
</DL>
|
|
<A NAME="lbAL"> </A>
|
|
<H3>Macros</H3>
|
|
|
|
|
|
Macros can take arguments.
|
|
In a macro body,
|
|
<B>$</B><I>n</I>
|
|
|
|
where
|
|
<I>n</I>
|
|
|
|
is between 1 and~9, is replaced by the
|
|
<I>n</I>th
|
|
|
|
argument if the macro is called with arguments;
|
|
if there are fewer than
|
|
<I>n</I>~arguments,
|
|
|
|
it is replaced by nothing.
|
|
A word containing a left parenthesis where the part of the word
|
|
before the left parenthesis has been defined using the
|
|
<B>define</B>
|
|
|
|
command is recognized as a macro call with arguments; characters
|
|
following the left parenthesis up to a matching right parenthesis are
|
|
treated as comma-separated arguments; commas inside nested parentheses
|
|
do not terminate an argument.
|
|
<DL COMPACT>
|
|
<DT id="100"><B>sdefine </B><I>name X anything X</I>
|
|
|
|
<DD>
|
|
This is like the
|
|
<B>define</B>
|
|
|
|
command, but
|
|
<I>name</I>
|
|
|
|
is not recognized if called with arguments.
|
|
<DT id="101"><B>include "</B><I>file</I><B>"</B>
|
|
|
|
<DD>
|
|
|
|
<B>copy "</B><I>file</I><B>"</B>
|
|
|
|
Include the contents of
|
|
<I>file</I>
|
|
|
|
(<B>include</B>
|
|
|
|
and
|
|
<B>copy</B>
|
|
|
|
are synonyms).
|
|
Lines of
|
|
<I>file</I>
|
|
|
|
beginning with
|
|
<B>.EQ</B>
|
|
|
|
or
|
|
<B>.EN</B>
|
|
|
|
are ignored.
|
|
<DT id="102"><B>ifdef </B><I>name X anything X</I>
|
|
|
|
<DD>
|
|
If
|
|
<I>name</I>
|
|
|
|
has been defined by
|
|
<B>define</B>
|
|
|
|
(or has been automatically defined because
|
|
<I>name</I>
|
|
|
|
is the output device) process
|
|
<I>anything</I>;
|
|
|
|
otherwise ignore
|
|
<I>anything</I>.
|
|
|
|
<I>X</I>
|
|
|
|
can be any character not appearing in
|
|
<I>anything</I>.
|
|
|
|
<DT id="103"><B>undef </B><I>name</I>
|
|
|
|
<DD>
|
|
Remove definition of
|
|
<I>name</I>,
|
|
|
|
making it undefined.
|
|
</DL>
|
|
<P>
|
|
|
|
Besides the macros mentioned above, the following definitions are available:
|
|
<B>Alpha</B>,
|
|
|
|
<B>Beta</B>,
|
|
|
|
...,
|
|
<B>Omega</B>
|
|
|
|
(this is the same as
|
|
<B>ALPHA</B>,
|
|
|
|
<B>BETA</B>,
|
|
|
|
...,
|
|
<B>OMEGA</B>),
|
|
|
|
<B>ldots</B>
|
|
|
|
(three dots on the base line), and
|
|
<B>dollar</B>.
|
|
|
|
|
|
<A NAME="lbAM"> </A>
|
|
<H3>Fonts</H3>
|
|
|
|
|
|
<B>eqn</B>
|
|
|
|
normally uses at least two fonts to set an equation:
|
|
an italic font for letters,
|
|
and a roman font for everything else.
|
|
The existing
|
|
<B>gfont</B>
|
|
|
|
command
|
|
changes the font that is used as the italic font.
|
|
By default this is~<B>I</B>.
|
|
|
|
The font that is used as the roman font can be changed using the new
|
|
<B>grfont</B>
|
|
|
|
command.
|
|
<DL COMPACT>
|
|
<DT id="104"><B>grfont </B><I>f</I>
|
|
|
|
<DD>
|
|
Set the roman font to~<I>f</I>.
|
|
|
|
</DL>
|
|
<P>
|
|
|
|
The
|
|
<B>italic</B>
|
|
|
|
primitive uses the current italic font set by
|
|
<B>gfont</B>;
|
|
|
|
the
|
|
<B>roman</B>
|
|
|
|
primitive uses the current roman font set by
|
|
<B>grfont</B>.
|
|
|
|
There is also a new
|
|
<B>gbfont</B>
|
|
|
|
command, which changes the font used by the
|
|
<B>bold</B>
|
|
|
|
primitive.
|
|
If you only use the
|
|
<B>roman</B>,
|
|
|
|
<B>italic</B>
|
|
|
|
and
|
|
<B>bold</B>
|
|
|
|
primitives to changes fonts within an equation, you can change all the
|
|
fonts used by your equations just by using
|
|
<B>gfont</B>,
|
|
|
|
<B>grfont</B>
|
|
|
|
and
|
|
<B>gbfont</B>
|
|
|
|
commands.
|
|
<P>
|
|
|
|
You can control which characters are treated as letters
|
|
(and therefore set in italics) by using the
|
|
<B>chartype</B>
|
|
|
|
command described above.
|
|
A type of
|
|
<B>letter</B>
|
|
|
|
causes a character to be set in italic type.
|
|
A type of
|
|
<B>digit</B>
|
|
|
|
causes a character to be set in roman type.
|
|
|
|
<A NAME="lbAN"> </A>
|
|
<H2>FILES</H2>
|
|
|
|
|
|
<DL COMPACT>
|
|
<DT id="105"><I>/usr/:share/:groff/:1.22.4/:tmac/eqnrc</I>
|
|
|
|
<DD>
|
|
Initialization file.
|
|
|
|
</DL>
|
|
<A NAME="lbAO"> </A>
|
|
<H2>MATHML MODE LIMITATIONS</H2>
|
|
|
|
|
|
MathML is designed on the assumption that it cannot know the exact
|
|
physical characteristics of the media and devices on which it will
|
|
be rendered.
|
|
It does not support fine control of motions and sizes to the same
|
|
degree troff does.
|
|
Thus:
|
|
<DL COMPACT>
|
|
<DT id="106">*<DD>
|
|
<B>eqn</B>
|
|
|
|
parameters have no effect on the generated MathML.
|
|
<DT id="107">*<DD>
|
|
The
|
|
<B>special</B>,
|
|
|
|
<B>up</B>,
|
|
|
|
<B>down</B>,
|
|
|
|
<B>fwd</B>,
|
|
|
|
and
|
|
<B>back</B>
|
|
|
|
operations cannot be implemented, and yield a MathML
|
|
'<merror>' message instead.
|
|
<DT id="108">*<DD>
|
|
The
|
|
<B>vcenter</B>
|
|
|
|
keyword is silently ignored, as centering on the math axis is the
|
|
MathML default.
|
|
<DT id="109">*<DD>
|
|
Characters that
|
|
<B>eqn</B>
|
|
|
|
over troff sets extra large - notably the integral sign - may
|
|
appear too small and need to have their '<mstyle>' wrappers
|
|
adjusted by hand.
|
|
</DL>
|
|
<P>
|
|
|
|
As in its troff mode,
|
|
<B>eqn</B>
|
|
|
|
in MathML mode leaves the
|
|
<B>.EQ</B>
|
|
|
|
and
|
|
<B>.EN</B>
|
|
|
|
delimiters in place for displayed equations, but emits no explicit
|
|
delimiters around inline equations.
|
|
They can, however, be recognized as strings that begin with
|
|
'<math>' and end with '</math>' and do not cross line
|
|
boundaries.
|
|
<P>
|
|
|
|
See section "Bugs" below for translation limits specific to
|
|
<B>eqn</B>.
|
|
|
|
|
|
<A NAME="lbAP"> </A>
|
|
<H2>BUGS</H2>
|
|
|
|
|
|
Inline equations are set at the point size that is current at the
|
|
beginning of the input line.
|
|
<P>
|
|
|
|
In MathML mode, the
|
|
<B>mark</B>
|
|
|
|
and
|
|
<B>lineup</B>
|
|
|
|
features don't work.
|
|
These could, in theory, be implemented with '<maligngroup>'
|
|
elements.
|
|
<P>
|
|
|
|
In MathML mode, each digit of a numeric literal gets a separate
|
|
'<mn>:</mn>' pair, and decimal points are tagged with
|
|
'<mo>:</mo>'.
|
|
This is allowed by the specification, but inefficient.
|
|
|
|
<A NAME="lbAQ"> </A>
|
|
<H2>SEE ALSO</H2>
|
|
|
|
|
|
<B><A HREF="/cgi-bin/man/man2html?1+groff">groff</A></B>(1),
|
|
|
|
<B><A HREF="/cgi-bin/man/man2html?1+troff">troff</A></B>(1),
|
|
|
|
<B><A HREF="/cgi-bin/man/man2html?1+pic">pic</A></B>(1),
|
|
|
|
<B><A HREF="/cgi-bin/man/man2html?5+groff_font">groff_font</A></B>(5),
|
|
|
|
<I>The TeXbook</I>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<P>
|
|
|
|
<HR>
|
|
<A NAME="index"> </A><H2>Index</H2>
|
|
<DL>
|
|
<DT id="110"><A HREF="#lbAB">NAME</A><DD>
|
|
<DT id="111"><A HREF="#lbAC">SYNOPSIS</A><DD>
|
|
<DT id="112"><A HREF="#lbAD">DESCRIPTION</A><DD>
|
|
<DT id="113"><A HREF="#lbAE">OPTIONS</A><DD>
|
|
<DT id="114"><A HREF="#lbAF">USAGE</A><DD>
|
|
<DL>
|
|
<DT id="115"><A HREF="#lbAG">Controlling delimiters</A><DD>
|
|
<DT id="116"><A HREF="#lbAH">Automatic spacing</A><DD>
|
|
<DT id="117"><A HREF="#lbAI">New primitives</A><DD>
|
|
<DT id="118"><A HREF="#lbAJ">Extended primitives</A><DD>
|
|
<DT id="119"><A HREF="#lbAK">Customization</A><DD>
|
|
<DT id="120"><A HREF="#lbAL">Macros</A><DD>
|
|
<DT id="121"><A HREF="#lbAM">Fonts</A><DD>
|
|
</DL>
|
|
<DT id="122"><A HREF="#lbAN">FILES</A><DD>
|
|
<DT id="123"><A HREF="#lbAO">MATHML MODE LIMITATIONS</A><DD>
|
|
<DT id="124"><A HREF="#lbAP">BUGS</A><DD>
|
|
<DT id="125"><A HREF="#lbAQ">SEE ALSO</A><DD>
|
|
</DL>
|
|
<HR>
|
|
This document was created by
|
|
<A HREF="/cgi-bin/man/man2html">man2html</A>,
|
|
using the manual pages.<BR>
|
|
Time: 00:05:11 GMT, March 31, 2021
|
|
</BODY>
|
|
</HTML>
|