# Is it a convention that the word "where" following a mathematical formula needs a comma before it?

I am not a native english speaker. I learnt about defining and non-defining relative clauses from english grammar books. Grammar books tell me not to use commas in defining relative clauses, so I don't understand why there is a comma preceding "where" in these examples:

From Theorem 4.59 (Sylow Theorems) in Anthony W. Knapp's Basic Algebra, Digital Second Edition:

Let $$G$$ be a finite group of order $$p^mr$$, where $$p$$ is prime and $$p$$ does not divide $$r.$$

From Hungerford's Algebra:

Theorem 6.7 (Fundamental Theorem of Arithmetic) Any positive integer $$n \gt 1$$ may be written uniquely in the form $$n = p_1^{t_1}p_2^{t_2} \cdots p_k^{t_k}$$, where $$p_1 \lt p_2 \lt \cdots \lt p_k$$ are primes and $$t_i \gt 0$$ for all $$i.$$

I think the clause "where $$p_1 \lt p_2 \lt \cdots \lt p_k$$ are primes and $$t_i \gt 0$$ for all $$i$$" is a defining relative clause, since it gives essential information about the form $$n = p_1^{t_1}p_2^{t_2} \cdots p_k^{t_k}.$$

I looked up the word "where" in three mathematical textbooks, and in similar situations, they all use commas between formulae and the words "where". Is this a convention just in mathematical writing?

• This isn't exclusive to math. See ell.stackexchange.com/questions/32382/comma-and-where . As a native English speaker I find lots of commas in mathematical writing helpful to break up the long sentences. Commented Jan 10, 2017 at 9:12
• For me, this is a clear, simple grammar convention. Commented Jan 10, 2017 at 9:12
• In another direction, Halmos (How to Write Mathematics, though I don't own the book and can't give a page reference) advised against the "where" construction, arguing that notation should be explained before its first use. For instance, Halmos might have suggested, "For every integer $n > 1$, there exist unique primes $p_1 < \cdots < p_k$ and positive integers $t_i$ such that $n = p_1^{t_1} p_2^{t_2} \cdots p_k^{t_k}$" for the fundamental theorem, or "Let $r$ be a positive integer, $p$ a prime not dividing $r$, and let $G$ be a finite group of order $p^{m}r$" for the theorem in Knapp. Commented Jan 10, 2017 at 13:38
• I'm no English expert, but it's not clear to me that this is a defining relative clause. It seems that the thing being defined is "form" and the thing that defines it is "$n = p_1^{t_1}\cdots p_k^{t_k}$", not the following "where" clause. Maybe someone with better expertise can run with that and find some references or something. Commented Jan 10, 2017 at 19:38
• Halmos is right, of course, if you can give the information at the start. If not, considerations of grammar and logic aside, custom demands the comma. Commented Jan 21, 2017 at 6:51

## 2 Answers

Consider an example:

(1)$$\qquad$$"We can find $$x\in A$$ such that $$f(x,y)=0$$, where $$g(y)\in B$$ "

(2)$$\qquad$$"We can find $$x\in A$$ such that $$f(x,y)=0$$ where $$g(y)\in B$$ ".

The first statement could be rewritten, with a change of emphasis, as

$$\qquad$$"We can find $$(x,y)\in A\times \{y:g(y)\in B\}$$ such that $$f(x,y)=0$$ ".

The second statement has the same structure as "There is fire where there is smoke" and might be interpreted as

$$\qquad$$"We can find $$x\in A$$ such that $$f(x,y)=0$$ whenever $$g(y)\in B$$ ".

Usually in mathematics, this latter type of interpretation is unintended, and the comma is needed.

Ideally, all notation should be defined before it is used. However, it often happens that the defining condition—for example, "where $$c$$ is some positive constant"—is not the focus of interest of the statement; so we may not wish to preface our statement as "There is some positive constant $$c$$ such that ... ". This is especially the case when the notation and condition are routine and conventional. In such cases, the where clause (preceded, of course, by a comma!) is unobjectionable.

Grammar books tell me not to use commas in defining relative clauses, so I don't understand why there is a comma preceding "where" in these examples:

Let $$G$$ be a finite group of order $$p^mr$$, where $$p$$ is prime and $$p$$ does not divide $$r.$$

Any positive integer $$n \gt 1$$ may be written uniquely in the form $$n = p_1^{t_1}p_2^{t_2} \ldots p_k^{t_k}$$, where $$p_1 {\lt} p_2 {\lt} \ldots {\lt} p_k$$ are primes and $$t_i {\gt} 0$$ for all $$i.$$

A relative clause (for example, in "The dog that she adores is brown") applies to nouns or noun phrases or pronouns, and contains no standalone sentence. However, in each example above, since the "where..." clause applies to the entire sentence preceding it and does contain a full sentence, it is actually not a relative clause.

Now, as pointed out in John's answer and corroborated in Are "where" and "such that" interchangeable?, without a preceding comma, the word "where" functions as a conditional ("whenever/if"). However, in each example above, because the word "where" is functioning as a conjunction $$(\text“p$$ be a prime number that does not divide $$r,$$ and $$G$$ be a finite group of order $$p^mr\text”;$$ “such that $$p_1 {\lt} p_2 {\lt}\ldots{\lt}p_k$$ and $$t_1,t_2,\ldots,t_k \gt 0$$ and $$n =p_1^{t_1}p_2^{t_2} \cdots p_k^{t_k}\text”),$$ the comma is indeed required.