PlanetPhysics/Style Guideline Summary

This ia a Summary of the full guidelines written by Aaron Krowne for PlanetMath that is also useful for PlanetPhysics.org. The full text can be read at: PlanetPhysics.org Style Guidelines

PlanetPhysics Content and Style Guide Summary

edit

Rationale

edit

This guide is meant to be a set of suggestions revealing the "best way" to write PlanetPhysics entries. One reason it is needed is because there are many common \LaTeX{} pitfalls that new or even intermediate \LaTeX{} writers may experience, and we hope to help them here. The second is because while there are many ways to do things both in terms of presentation style and \LaTeX{} use, we want to encourage writers to select the methods that will help make PlanetPhysics more consistent and hence easier to understand.

We stress again that this is only a guide---not a forced set of rules. The owner of an entry is assumed to be its expert, not the PlanetPhysics staff or any other users of the site. However we appeal to each and every writer to heed this document, to help make PlanetPhysics a better resource for all learners.

Content Guidelines

edit

What to write.

Definitions

edit

In definitions, the term (or terms) being defined should be distinguished by typesetting it in either italics (preferred) or boldface . (See section \ref{sec:font-faces}.)

A basic definition-entry should give only one name and one notation (when such exists) for what is being defined. This will make the definition as short as possible and thus easy to read. It will also encourage a common notation/term for use at PM.

However, after the definition is given it is highly encouraged to mention examples, possible synonyms, alternative notations, etymology, and historical comments. These items could be placed in one or more additional sections, such as "Examples", "Notes", "Properties", and so forth. Lengthy examples should have their own entries attached to the definition.

Often an entry is lengthy, so that the definition might become difficult to distinguish from the surrounding text. This is especially noticeable if some introductory text precedes the definition. In such cases it is a good idea to somehow mark the definition so that it stands out. One way to do this is to use a ready-made "definition" environment (see below).

Sometimes, many concepts must be defined at once in a single entry. For example, it is difficult to define "graph" without also defining "nodes" and "edges". It makes more sense to group these things together. These additional concepts can be listed as defined in the "defines" metadata field of the entry. Synonyms for the main concept should be listed in the "synonyms" field.

Theorems

edit

In theorems, it should always be clear what the assumptions are and what are the implications. Also, one should try to eliminate any unnecessary notation from the formulation. In particular, the theorem formulation should not be used to set up the notation for a proof. Such unnecessary notation will make the theorem difficult to read.

As with definitions, if the theorem is surrounded with explanatory text (as most theorems should be), it is probably a good idea to set it off from the surrounding text in some way. A "theorem" environment (see below) is a good way to do this. Some publication styles set theorems in slanted text to attract attention.

Proofs

edit

Proofs may be included in the entry for the theorem itself if they are short; they should if possible be clearly marked as a proof, perhaps by using {\tt \verb|\begin{proof}| \ldots \verb|\end{proof}|} environment (see below). If the theorem contains its own proof, the appropriate checkbox should be set, so that the theorem does not appear on PlanetMath's "unproved theorems" list.

If the proof is long, it should go in its own entry, attached to the theorem itself. There's an "add proof" button for just this purpose. Others may attach alternative proofs to your theorems as well.

Topics

edit

Style Guidelines

edit

How to write:

Since entries at PM are entries in an encyclopedia, each entry should stand on its own.

Logic symbols versus words

edit

Logic symbols like  ,  ,   and   should be used sparingly. The reason is that their overuse leads to entries that look like a stream of gibberish, which are so dense they are difficult to read. The use of natural language logical connectives makes an entry much easier to read.

Choice of Title

edit

The title should be descriptive, of course, of what the entry actually is: "Fermat's last theorem" is good, as is "vector bundle", but "products of connected spaces" suggests (vaguely) a list of properties of products of connected spaces; if the entry is actually just the theorem that such products are connected, it should read "products of connected spaces are connected". If the theorem is in fact an if and only if theorem but one direction is essentially trivial (as in this case), the easy direction can be left out of the title.

You should write the title with capitalization as it would appear in an index. When using a term within an entry, the local capitalization style will be adopted by the automatic linker. Proper names and adjectives derived from proper names are to be capitalized to create a consistent look to the entries. Thus, Eulerian, Euclidean, Archimedean, Henselian, Noetherian, Artinian, Abelian, Lagrangian, and Gaussian are to be used.

Classification

edit

It is important to select a good classification for your entry, as this helps readers find it while browsing, and helps to steer the automatic linking system. Classification on PlanetMath uses the AMS Mathematics Subject Classification scheme (AMS-MSC). You can search or browse this scheme, looking for categories that match your entry.

A classification string is a list of comma-separated category codes, of the form \verb=scheme:code=, where \verb=scheme= is the classification scheme. If \verb=scheme:= is left out, \verb=msc= is assumed (as this is the only supported scheme at the time anyway). Codes look like \verb=NNLNN=, where \verb=N= is a number and \verb=L= is a letter.

The order of the category codes in a classification string is important. The first code is considered the most important, the second is considered second-most important, and so on. In situations where one category code must be selected to "represent" the subject of the entry, the first code will be used.

Choice of Words

edit

Abbreviations and Latin terms

edit

In scientific writing, Latin terms occur frequently. However, if these are overused, they tend to make the text quite formal. Thus, when possible, one should consider using the corresponding English terms.

  • iff is handy in notes, but in printed text, it is usually written out if and only if [1].
  • e.g. is short for exempli gratia (Latin: for example).
  • i.e. is short for id est (Latin: that is, in other words).

    Now   converges to  , i.e., if  , there is an   such that   for all  .

  • et al. is short for et alia (Latin: and others).
  • cf. is short for confer (Latin: compare). This abbreviation is frequently used incorrectly to mean "see" [1]. For example, cf. [20] for a discussion, is incorrect.
  • viz. short for videlicet , (Latin: it is permitted to see).
  • sic.
  • ad hoc
  • mutatis mutandis Latin for ``with the necessary changes having been made".

Displaying Equations

edit

Equations can be typeset as inline equations (like \fbox{ }) or as a displayed equation;   Typically, an equation is displayed if it needs to be numbered, if it is long (and therefore difficult to read inline), or if it defines an important quantity or is otherwise important [1].

  • If a sentence ends with a displayed equation, the displayed equation should end with a period [1].
  • If an equation is numbered, it should be referred to at least once. \item References to numbered items should indicate what is being numbered. For instance, "according to equation (2)", "by inequality (4)" are much easier to read than "according to (2)", "by (4)". The abbreviation "Eq." should not be used [1]. In order to refence a numbered item, use the command \verb+(1)+ where tag is a unique identifier. Later you can use \verb+10+ in order to include the number at some other place.

Emphasis

edit

When emphasizing text, the usual way to do it is to use {\tt \verb|emphasized text |}. This will look like this , or like this in italic text , or \textbf{like this in bold text}, or \textsl{like this in slanted text}, or finally \texttt{like this in typewriter text}. This is the way books are written, for good typographic reasons. If you really prefer boldface, it is available; you will have to keep track of whether it actually looks any different from the surrounding text.

Sentences

edit

Paragraphs

edit

Sectioning

edit

Grammar

edit

Punctuation

edit

Flow Between Text and Mathematics

edit

What you write should be primarily text, in the following sense: the reader should be able to read the paragraph aloud, and it should be grammatically correct and clear, using English connectives such as "and" and "but". While it is possible to write many equations in one giant formula without explanation, it should be reserved for situations when the calculations are really self-explanatory. Even then, it is rare that more than four or five successive equalities appear in the same formula without english text.

If you need small pieces of text to appear in your formulas, for example in piecewise definitions of functions (which you do using the {\tt \verb|\begin{cases}| \ldots \verb|\end{cases}|} environment), use

{\tt \verb|=the text= |} which is provided by =amsmath= package. For instance if you type


\delta(x)=\begin{cases} 1 & =if = x=0\\ 0 & =otherwise= . \end{cases}

then the result looks like this:

 

Notation

edit

If your entry depends on another entry in some essential way (say, you're proving a theorem, or you're defining a special kind of a type of object they define), you need to look at their page to check that you have the same thing in mind as the author. At the same time, you should look at their notation. If it's reasonable and you have no strong reason to use a different notation, use theirs. It makes life easier for PlanetMath users. On the other hand, if you're really working in a different field that uses different notation, by all means change it. Make sure readers won't be confused by the change in notation, by explaining it or asking the other author to explain it. If the other author is using notation that is so bad you don't feel you should use it in your entry, file a correction on their page, asking them to at least mention your notation. Then use yours in your entry.

The Right Way\texttrademark

edit

Tips, tricks, and advice on how to do things the right way.

Quotes

edit

When writing text to be viewed on a computer screen, only one type of quote is used, either {\tt \verb|"|} or {\tt \verb|'|}.\footnote{ Some word processing or web publishing programs helpfully guess whether you meant to open or close the quotation and change the symbol. Often this happens in a non-portable way, making web pages look like they were written by illiterates.} However, when writing text to be typeset and printed, two types of quotes are used \fbox{``} and \fbox{''} or \fbox{`} and \fbox{'}. Those writing TeX documents should be mindful of the difference. So incorrect usage is \verb|"wrong"| giving \fbox{"wrong"}, while correct usage is \verb|"right"| giving \fbox{"right"}. Note that in TeX both \verb|''| and \verb|"| produce the same symbol \fbox{"}, but the former is used more often because of symmetric appeal.

→ vs. ↦

edit

The symbols \verb|\to| ( ) and \verb|\mapsto| ( ) are often confused, but, as their names suggest, are different. Writing   indicates that   is a function from a set   to a set  . On the other hand,   indicates that   maps   to  , or equivalently that   is the   function.

denoted vs. denoted by

edit

In ``The set  , denoted  , is open", there is a missing "by".

Ambiguous words

edit
  • this : In "From this the proof follows", it is seldom completely clear what this refers to. Instead, one could write something like "Combining equation (1) and (2) gives the result."
  • it [1]: In ``Condition b. in Theorem 1 does not hold for the steepest descent method. Therefore, we shall not consider it., the word it can refer to both Condition b. or the steepest descent method.
  • etc. is an abbreviation for et cetera , Latin for ``and the others". An ambiguous example would be

    We can now prove that   is smooth, invertible, convex, etc.

Theorem-like and Proof Environments

edit

When presenting a theorem, lemma, definition, remark, and similar statements, it is customary to set it apart from the rest of the text to make them easier to notice. This can be done usig a =theorem= -like environment created with the {\tt \verb|\newtheorem|} macro. For example


\newtheorem{thm}{Hard Theorem} \begin{thm}[Fermat] There are no positive integer solutions to the equation   for  . \end{thm}

gives

\newtheorem{thm}{Hard Theorem} \begin{thm}[Fermat] There are no positive integer solutions to the equation   for  . \end{thm}

A proof can be given using the =proof= environment provided by the =amsthm= package. For example


\begin{proof}[Simple proof] See Wiles (1995). \end{proof}

gives

\begin{proof}[Simple proof] See Wiles (1995). \end{proof}

As mentioned above, =theorem= -like environments can be used for more than just theorems. This is facilitated by the =amsthm= package. It provides three default styles `plain', `definition', and `remark'. For example


\theoremstyle{definition} \newtheorem*{defn}{Simple Definition} \begin{defn} An integer is even if it is divisible by  . \end{defn}

gives

\theoremstyle{definition} \newtheorem*{defn}{Simple Definition} \begin{defn} An integer is even if it is divisible by  . \end{defn}

Note that \verb|\newtheorem*| supresses numbering, unlike its unstarred cousin. Note that default theorem styles do not have to be used in the way they are named, they simply provide different choices of font styles for header and body of the new environment.

All contributors to PlanetMath are strongly encouraged to make use of =theorem= -like environments. One reason is to set them apart from other text semantically, just as they are set apart visually. This is especially important in an online encyclop{\ae}dia which is subject to automatic indexing. Another important reason is consistency. If everyone uses a few standard styles, this adds greatly to a consistent look of PlanetMath as a whole. Definitions for such styles can be added to your default preamble so that they just appear when you write an entry.

The =amsthm= package provides other useful features such as the ability to define custom theorem styles. More information can be found in guide to =amsthm= by Richard Kaye.

Spacing

edit

There is often confusion betwen punctuation and mathematical symbols or operators. The symbol itself may look the same, but it is typeset differently in different contexts. Usually, the difference is in spacing. There are several common mistakes. ====Failed to parse (syntax error): {\displaystyle {-==== \colon{-}<math> vs.\ } {-}:{-}Failed to parse (unknown function "\verb"): {\displaystyle } The colon symbol (:) can be used as punctuation or as an operator, both in the context of a mathematical expression. If it is ''punctuation'' , the \verb|\colon| macro should be used. If it is an ''operator'' , then \verb|:| should be used. Here are some examples: *''incorrect'' usage \verb|function <math>f: X \to Y} | gives \fbox{function  }, while correct usage \verb|function  | gives \fbox{function  };

  • incorrect usage \verb|ratio  | gives \fbox{ratio  }, while correct usage \verb|ratio  | gives \fbox{ratio  }.

</math>{-

edit

<{-}>{-} {-}\langle{-}\rangle{-}</math>} There is common confusion between mathematical relational operators less-than ( ) and greater-than ( ), and punctuation angle brackets   and  . The difference must be respected. Here are some examples:

  • incorrect usage \verb| | gives \fbox{ }, while correct usage \verb| | gives \fbox{ };
  • incorrect usage \verb| | gives \fbox{ }, while correct usage \verb| | gives \fbox{ }.

====Failed to parse (syntax error): {\displaystyle {-==== |{-}<math> vs.\ } {-}\mid{-}Failed to parse (syntax error): {\displaystyle } The vertical bar (<math>|} ) symbol is often misused in mathematical expressions. It is mostly used to make vertical bars in tables and it keeps the same meaning in mathematical expressions. The corresponding mathematical operator is typeset with the \verb|\mid| macro. So incorrect usage \verb" " gives \fbox{ }, while correct usage \verb| | gives \fbox{ }. Similarly the relation "divides into" should be typeset as \verb" " giving \fbox{ } and its negation should be typeset as \verb" " giving \fbox{ }.

Operator and Function Names

edit

\LaTeX{} provides predefined macros for typesetting the commonly used functions such as \verb|\sin|, \verb|\cos|, \verb|\exp|, \verb|\log|, \verb|\lim|, \verb|\liminf|, \verb|\limsup|, \verb|\min|, \verb|\max| and others. In case when the needed operator is not the one of them one can define custom operators using command \verb|\DeclareMathOperator| from package =amsmath= .


\DeclareMathOperator{\Tr}{Tr} ... Sometimes Failed to parse (unknown function "\Tr"): {\displaystyle \Tr M} is used to denote the trace of  .

The above produces

Alternatively, if you do not intend to use a certain function or operator often, it can be typeset the same way using the Failed to parse (SVG (MathML can be enabled via browser plugin): Invalid response ("Math extension cannot connect to Restbase.") from server "http://localhost:6011/en.wikiversity.org/v1/":): {\displaystyle \verb|\operatorname| macro} , for example Failed to parse (SVG (MathML can be enabled via browser plugin): Invalid response ("Math extension cannot connect to Restbase.") from server "http://localhost:6011/en.wikiversity.org/v1/":): {\displaystyle \verb|} x\operatorname{Tr}M .

Figures and Diagrams

edit

Figures and diagrams really "bring the math to life". We encourage everyone to consider illustrating the concepts in their entries using figures, particularly for geometric, combinatorial, or algebraic entries.

There are two main categories for digital encoding of images, raster and vector formats. Raster formats store the image as a two-dimensional array of colored pixels, while vector formats store drawing commands that can be reproduced to draw the image on any display medium.

Vector formats are especially suited for mathematical diagrams and illustrations in a digital medium. Hence all diagrams included in PlanetMath should be in a vector format (inline, EPS, etc.)\ and not in a raster format (JPEG, PNG, GIF, etc.). Note that simply encapsulating a raster image in an EPS file is not acceptable. If an image is drawn in the Gimp or MS~Paint\texttrademark, it will be a raster image no matter what format you save it in, and it will look awful in print or in page images mode. Moreover, in the interests of reproducibility and editability of the diagrams, the original editable sources should be provided. Of course, there are exceptions such as photographs or any other image whose raster nature is intrinsically justified. If you absolutely must provide such an image (an article about the Mandelbrot set, for example), provide it in the highest resolution you can, so that the print version has a chance of being legible.

Including Figures

edit

There are two main ways of including diagrams in an entry: inline and externally. Inline diagrams are generated by code included directly in the TeX document. They are rendered using specific packages. However, some of them only work with PostScript output and cannot be compiled directly with PDF-LaTeX or PDF-TeX. External figures are usually EPS (Encapsulated PostScript), PostScript, or pdf files, which can be generated with a large number of programs (see below). Once created, they should be uploaded to the article's PlanetMath filebox, along with the source (for example, the FIG file if XFig was the drawing program). Including the source alleviates concerns about compliance with the FDL license, and is just the "right thing" to do.

Text in Math and Math in Text

edit

. When writing inline math, \LaTeX\ supports a number of possible syntaxes. You can write   as \verb| | or \verb|\(a=b\)|. There's no major reason to prefer one over the other. When writing displayed math, however, there is a \LaTeX\ way (\verb|

 

|) and primitive \TeX\ way (\verb| |). The primitive \TeX\ way bypasses the \LaTeX\ formatting algorithms and can cause poor formatting if AMS math features are used. For numbered equations, use the \verb|

 

This should be distinguished from operators that are normally typeset upright, such as   or  . To put text in a math context, use \verb|= something like this= |. Note that math environments normally ignore spaces, so if you want word spaces before or after your text, you should include them in the argument to \verb|\text|. If you want to typeset an operator that does not have a \LaTeX\ macro already, use \verb|\operatorname{name}|. If you want to use an operator many times, put \verb|\DeclareMathOperator{\name}{name}| in your preamble.

Bibliography

edit

All authors are strongly encouraged to include bibliographies in their entries. Besides giving the proper credit to the original sources a bibiliography provides a pointer to the place where more information on the subject can be found.

The preferred way for creating bibliography is using thebibliography environment--see example given below. At the moment   cannot be used directly. Instead the bibliography can be created offline, and then copy-pasted from the   file. One should also be advised against using texttt(amsrefs) package because in HTML rendering mode an texttt(amsrefs) bibliography is rendered as graphics.

When a source is available online (as a preprint, for example), then an hyperlink should be included using the   command (see  ,   for syntax). Links to the pertinent  ,   or  ,  reviews also help the reader to find relevant sources.

All Sources

edit

[1]

References

edit
  1. 1.0 1.1 1.2 1.3 1.4 1.5 1.6 N. J. Higham, Handbook of Writing for the Mathematical Sciences , SIAM, 1998.