{math-mode} is about typesetting mathematical content, e.g. tweaking the appearance of spacing and symbols in a formula, or producing specific mathematical constructs. For questions about "wrapper" environments like equation or align, consider the tag {equations}.

learn more… | top users | synonyms (2)

20
votes
4answers
2k views

Underscore in textmode vs mathmode

I use _ character often in text mode, so I changed category of underscore: \catcode\_=12, but that applies also to mathmode and now I'm unable to make subscripts with underscore in mathmode. Is there ...
20
votes
2answers
4k views

\overbrace with square bracket

I'm trying to put a nice square bracket over a complex text, it should look like an \overline but with ending like \ulcorner and \urcorner. The presence of \overrightarrow and \overleftarrow makes me ...
20
votes
1answer
10k views

typesetting modulus operator, as in remainder

Is there a standard way to typeset the modulus operator (as in arithmetic remainder)? The percent sign (%) is often used by programming languages and mathematicians tend to use mod, but because of the ...
20
votes
3answers
430 views

Create a new math mode

Motivation When I use math mode inside of itemize environments for multiline equations, I have to do something like the following ... \begin{itemize} \item $\begin{aligned}[t] equation stuff ...
20
votes
2answers
2k views

Typesetting Right-to-Left math

UPDATE: I've managed to produce something that is aesthetically correct, however with a lot of "hardcoding" and trial and error to manually measure my spaces. Not to mention that I have to write my ...
20
votes
2answers
2k views

Proper use of \mathchoice

I am trying to learn how to use \mathchoice. Before the solution was posted for Non-invasive replacement for \fbox?, I attempted to use mathchoice to adjust the size of the parameter before ...
20
votes
4answers
10k views

Bold italic vectors

I am trying to display vectors as bold and italic. The command \mathbf sets the letters non-italic. I also googled a bit and stumbled upon \mathbf{\em y} or \mathbfit{y}, which all didn't work. I ...
20
votes
2answers
5k views

Is there a difference between the `displaymath` and `equation*` environments?

The amsmath documentation says Basic LaTeX doesn’t provide an equation* environment, but rather a functionally equivalent environment named displaymath. Are they really the same or is there a ...
20
votes
1answer
269 views

There's a bump in the implies glyph

Edit: I understand this question has been marked as a duplicate, but the question I linked to doesn't have a solution for me (unless I'm missing something obvious, which is likely). The effect is ...
20
votes
1answer
587 views

Elisions in mathematics

Knuth incorporated many of the typographical rules for mathematics in the TeX engine. However some rules were left out. One such case is the use of elisions in equations. Sometimes \cdots are used and ...
20
votes
1answer
516 views

How would one design a math font?

There are (some very nice) text fonts which do not have math support. Though there are ways to 'remedy' this, such as the mathastext package and some others, these are hardly satisfactory. All accents ...
19
votes
5answers
1k views

How to typeset the limit of a sequence like so?

I want to write this: I tried with $x_n \to_{n \to 0} 0$ but the $n \to 0$ doesn't go under the right arrow, it goes under but on the right, and I want it under but in the center, as in the picture ...
19
votes
3answers
1k views

How to align limits of double integrals?

I'd like to have the limits of two integrals vertically aligned. In this example, the x and b should be positioned on the same line. \[\int\limits_x^{\infty}\int\limits_b^{\infty} x^2+y^2 ...
19
votes
3answers
886 views

Curly brace to insert something into an equation? Like an inverted underbrace

I have a generic equation, into which I want to "insert" something so that the reader can see what I inserted into the equation and at which point. E.g. \documentclass{plain} \begin{document} \[ f ...
19
votes
3answers
18k views

How to put a big bracket under different parts of a equation so that I could write e.g. a text specific to that part in the equation?

How to put a big bracket under different parts of a equation so that I could write e.g. a text specific to that part in the equation? For example : f = x^3 + 2 |___| |__| | | ...
19
votes
3answers
614 views

Visually highlighting symbolic material

I have a diagram in which I need to indicate the difference between symbolic mathematics and English words (potentially to someone who doesn't know about it): Colour works beautifully for making ...
19
votes
4answers
4k views

What free math font could/should accompany Linux Libertine and Linux Biolinum?

Well, the title of the question pretty much says everything. To be more precise: I'd like to know (1) what font would be visually suitable to use with Linux Libertine and/or Linux Biolinum as the ...
19
votes
5answers
21k views

Unicode degree symbol ° in math formulas: \textdegree invalid in math mode

I'd like to be able to simply input a degree symbol as ° in my source code. German keyboards have a key for this, and it makes the source so much more readable. I'm using pdflatex from TeXLive 2012, ...
19
votes
2answers
9k views

\xRightarrow (text)

I know it's possible to have \xrightarrow (text), but if I try to do \xRightarrow (text) I get an error each time. Does anybody know if it's a syntax error or if there is a other way to produce the ...
19
votes
2answers
812 views

How do I format a regular expression in math mode?

I want to display some regular expression, like the following, in LaTeX math mode. \[ (F+(A+I*)*)|(F*(A+I*)+)E \] However, the spacing is all wrong, because TeX formats + and * as binary operators, ...
19
votes
2answers
351 views

How to prevent superscripts from moving under \sqrt?

When I put an expression with superscripts under a \sqrt, the superscripts (here "vis") move down a bit. How can I prevent that, so that it looks consistent no matter whether it's under a root or not? ...
19
votes
2answers
1k views

Make mathfont respect the surrounding family

How can one make the math mode change its font according to the surrounding text? I have to use (pdf)latex. xelatex, luatex etc. are not possible alternatives in this case. \documentclass{scrartcl} ...
19
votes
3answers
859 views

How can I create a new extensible symbol?

Given an arbitrary thin vertical symbol, can I create a new math delimiter from it (and if so, how)? Edit: Ideally, I would like to be able to create an extensible symbol, either built out an ...
19
votes
3answers
4k views

Is \mathrm really preferable to \text? [duplicate]

It seems to be the de facto standard to use \mathrm for upright letter notation in math mode as opposed to \text. Would it not be better to use \text in general? One particular problem I am thinking ...
19
votes
1answer
821 views

What does the tilde character (~) do in math mode?

What effect does the tilde character ~ have in math mode? Is it the same non-breaking space that it is in text mode? Is it bad style to use ~ in math mode? I've seen it used in some examples but ...
19
votes
1answer
528 views

Why \( and \) were not defined as robust commands in the first place?

I am aware of the difference between using \(...\) and $...$ (in moving arguments, for example), and yes, I've read the answers to this question: Are \( and \) preferable to $?). I also know the ...
19
votes
3answers
2k views

Why LaTeX uses upright uppercase Greek letters by default in math mode?

Why upper-case Greek letters are typeset in upright font, i.e., \mathrm? While at the same time, some upper-case Greek letters those are also Latin Letters ,e.g., A for $\Alpha$, B for $\Beta$, are ...
19
votes
2answers
1k views

Placement of subscripts using unicode-math. Is it XeTeX bug?

I don't like placement of subsripts when using unicode math fonts under XeLaTeX. In contrast to CM fonts the subscripts are placed at different vertical positions obviously depending on the depth of ...
19
votes
1answer
4k views

mathtools vs amsmath

I read on http://en.wikibooks.org/wiki/LaTeX/Mathematics: The mathtools package fixes some amsmath quirks and adds some useful settings, symbols, and environments to amsmath. It sounds like ...
18
votes
4answers
619 views

Is there any difference between quad in math mode and text mode?

Is there any difference between $a \text{\quad text\quad} b$ and $a \quad \text{text} \quad b$? I cannot see the difference as shown in the following figure. If there is no difference, which one ...
18
votes
3answers
13k views

Math mode in tabular without having to use $…$ everywhere

\begin{tabular}{|l|l|l|} \hline Column A & Column B \\ \begin{math} x & y \\ \end{math} \end{tabular} This won't let me compile and gives a lot of errors, how do I enable math mode in a ...
18
votes
4answers
3k views

Subscripts for primed variables

When I add a subscript to a primed variable, the subscript is rendered lower than when it is a subscript to an unprimed variable. For example, when I compile $l_x l'_x l_x l'_x l_x l'_x$ I get ...
18
votes
5answers
6k views

Color underline a formula

I want to underline different parts of a formula with different colors. What is the best possible option? Soul seems only to provide one color per document.
18
votes
3answers
4k views

\DeclareMathOperator won't take arguments

I'd like to define a family of math operators that have the same superscript, but different subscripts. My first attempt was: \DeclareMathOperator{\Upd}[1]{U^M_{#1}} But the log tells me that: l.3 ...
18
votes
3answers
2k views

Vertically asymmetric size variation for parentheses

One of the difficulties I have with writing formulas in LaTeX is that the standard sizing tools for the variable-size operators (parentheses, etc.) do not account for "high" symbols and "low" symbols ...
18
votes
2answers
10k views

How do I use a circle as a math accent (larger than \mathring)?

To denote the interior of a set, I'd like to have a command \interior. Now, as one can learn from this post, one possibility is to use \mathring. This is a neat command, but it produces a circle that ...
18
votes
3answers
580 views

Remove all math for spelling and grammar checking

I'm compiling a LaTeX file to pdf and then I use a pdf to text converter to convert the file to plain text. I then use LanguageTool to do grammar checking on that plain text file. The LaTeX source has ...
18
votes
4answers
10k views

How can I prevent inline math formulas from overflowing into the margin?

When I compile my document in LaTeX, some formulas in the document in math mode, between $ $, go into the right margin area beyond all the text. Is there a way to fix this aesthetic problem?
18
votes
3answers
11k views

How to typeset function restrictions

I wonder how to typeset the restriction of a function to some subdomain, a la $f|_A$ or $f\restriction_A$ , but with the vertical bar being as big as possible.
18
votes
1answer
4k views

How to use more than 10 tab stops in \bmatrix?

I'm using bmatrix environment from the amsmath package, and I'm trying to do something like this: \documentclass{article} \usepackage{amsmath} \begin{document} \begin{equation} ...
18
votes
1answer
1k views

How can I standardize my square root signs?

I've noticed that when square root signs get too large, their front leg goes vertical (1), and that otherwise, it angles to the right (2). How can I standardize all my square root signs to either ...
18
votes
1answer
321 views

Drawbacks of redefining math accents with extra leading {}?

As I discovered through the non-bug latex/4253, TeX has a (mis)feature whereby it ignores braces around a \mathaccent construction: ${a_b}_c$ works, but ${\tilde a_b}_c$ fails with a "Double ...
17
votes
4answers
2k views

How do I write $\notin$ backwards?

I write $P \niton x$, but it does not work. How can I write the symbol $\notin$ backwards?
17
votes
4answers
1k views

wavy division sign wanted

I would like to find or create a math relation symbol that resembles a division sign, except that the horizontal bar would instead be a tilde (\sim). Can anyone help with this?
17
votes
4answers
11k views

Evaluation of Differentiation and Integration

I was having some thought about what would be the syntax to make the end point evaluation of derivatives or integrals. Such as making the | with the two end points of evaluation on the top an bottom ...
17
votes
5answers
3k views

Upright Lowercase $\pi$

On pg. 144 of Kopka and Daily's A Guide to LaTeX, they mention that the symbols $e$, $i$, $d$, and $\pi$ should be displayed upright in math mode (for their usual uses). This is easy to do for $e$, ...
17
votes
4answers
2k views

No space present after ensuremath

When I insert a short maths section in a sentence, it renders fine with a space each side as expected: ...returned $\mathcal{P}$ from... If I define a command to do the same thing, it also renders ...
17
votes
4answers
9k views

Removing spaces between “words” in math mode

I'd like to set $1024 \times 768$ without any space between the three items. Is this possible? If so, how? E.g., what I get is: 1024 x 768 and what I want is: 1024x768
17
votes
3answers
26k views

making a big summation sign

how can I make a big summation sign ? ‎\begin{align}‎ ‎\cos x‎ ‎=‎ ‎‎\sum\limits‎_‎{n=0}^{‎\‎‎infty‎} ‎\frac{(ix)^2n‎}{(2n)!}‎‎ \end{align}‎ this is the code which I'm using for summation
17
votes
4answers
2k views

What is the command for a sum symbol superimposed on an integral sign?

I want to express a sum over all discrete states and an integral over all continuum states. Usually, the sign for this is a $\sum$ superimposed on an $\int$. Is there a command to make this symbol? If ...