Hot answers tagged

131

Crossing things out Use \require{cancel} in the first formula in your post that requires cancelling; you need it only once per page. Then use: $$\require{cancel}\begin{array}{rl} \verb|y+\cancel{x}| & y+\cancel{x}\\ \verb|\cancel{y+x}| & \cancel{y+x}\\ \verb|y+\bcancel{x}| & y+\bcancel{x}\\ \verb|y+\xcancel{x}| & y+\xcancel{x}\\ \verb|y+\...


115

Additional decorations $\def\demo#1#2{#1{#2}\ #1{#2#2}\ #1{#2#2#2}}$ \overline: $\demo\overline A$ \underline: $\demo\underline B$ \widetilde: $\demo\widetilde C$ \widehat: $\demo\widehat D$ \fbox: $\demo\fbox {$E$}$ \underleftarrow: $\demo\underleftarrow{F}\qquad$ variant: \xleftarrow{}: $\xleftarrow{abc}$ \underrightarrow: $\demo\underrightarrow{...


112

Commutative diagrams AMScd diagrams must start with a "require": $\require{AMScd}$ \begin{CD} A @>a>> B\\ @V b V V= @VV c V\\ C @>>d> D \end{CD} to get this diagram: $\require{AMScd}$ \begin{CD} A @>a>> B\\ @V b V V= @VV c V\\ C @>>d> D \end{CD} @>>> is used for arrow right @<<< is used for arrow ...


92

Using \newcommand I would like to remark that it is possible to define LaTeX commands as you do in your TeX files. I felt so happy when I first discovered it! It's enough to insert something like $ \newcommand{\SES}[3]{ 0 \to #1 \to #2 \to #3 \to 0 } $ $ \newcommand{\SES}[3]{ 0 \to #1 \to #2 \to #3 \to 0 }$ at the top of your post (remember the dollars!). ...


91

Tags & References For longer calculations (or referring to other post's results) it is convenient to use the tagging/labelling/referencing system. To tag an equation use \tag{yourtag}, and if you want to refer to that tag later on, add \label{somelabel} right after the \tag. It is not necessary that yourtag and somelabel are the same, but it usually is ...


76

Big braces Use \left and \right to make braces - (round), [square] and {curly} - scale up to be the size of their arguments. Thus $$ f\left( \left[ \frac{ 1+\left\{x,y\right\} }{ \left( \frac{x}{y}+\frac{y}{x} \right) \left(u+1\right) }+a \right]^{3/2} \right) $$ renders as $$ f\left(\left[ \frac{...


72

Limits To make a limit (like $\lim \limits_{x \to 1} \frac{x^2-1}{x-1}$), use this syntax: First, start off with $\lim. This renders as $\lim$. The backslash is there to prevent things like $lim$, where the letters are slanted. Second, add \limits_{x \to 1} inside. The code now looks like $\lim \limits_{x \to 1}$, and renders as $\lim \limits_{x \to 1}$. ...


66

My view has always been that programming questions are very much borderline. Here is the border, as I see it. Your question is about the mathematics of the algorithm. This could be about a specific implementation, but the question has to be mathematical. That question is on-topic here. Your question is about the implementation of your code. It is about the ...


62

Arbitrary operators If an operator is not available as a built-in command, use \operatorname{…}. So for things like $$\operatorname{arsinh}(x)$$ write \operatorname{arsinh}(x) since \arsinh(x) will give an error and arsinh(x) has wrong font and spacing: $arsinh(x)$. This was already mentioned in a comment by Charles Staats. You might consider this an ...


61

Avoid "no clue" questions Too many questions begin or end with "I don't even know how to begin with this problem". While this may be true (you may genuinely have no idea how to approach the problem), it is still not a valid reason to limit your post to the statement of the problem without any mention of your own thoughts. Such questions will most of the ...


60

Highlighting equation To highlight an equation, \bbox can be used. E.g, $$ \bbox[yellow] { e^x=\lim_{n\to\infty} \left( 1+\frac{x}{n} \right)^n \qquad (1) } $$ produces $$ \bbox[yellow] { e^x=\lim_{n\to\infty} \left( 1+\frac{x}{n} \right)^n \qquad (1) } $$ By default, the bounding box is "tight", so it doesn't extend beyond the characters used in the ...


53

Absolute values and norms The absolute value of some expression can be denoted as \lvert x\rvert or, more generally, as \left\lvert … \right\rvert. It renders as $\lvert x\rvert$. The norm of a vector (or similar) can be denoted as \lVert v\rVert or, more generally, as \left\lVert … \right\rVert. It renders as $\lVert v\rVert$. (You may also write \left\|…\...


51

Giving reasons on each line of a sequence of equations To produce this: \begin{align} v + w & = 0 &&\text{Given} \tag 1\\ -w & = -w + 0 && \text{additive identity} \tag 2\\ -w + 0 & = -w + (v + w) && \text{equations $(1)$ and $(2)$} \end{align} write this: \begin{align} v + w & = 0 &&\text{...


47

Pack of cards If you are asking (or answering) a combinatorics question involving packs of cards you can make it look more elegant by using \spadesuit, \heartsuit, \diamondsuit, \clubsuit in math mode: $$\spadesuit\quad\heartsuit\quad\diamondsuit\quad\clubsuit$$ Or if you're really fussy: \color{red}{\heartsuit} and \color{red}{\diamondsuit} $$\color{red}{\...


47

Mathematical typesetting using MathJax Mathematics.SE uses the emulation engine MathJax for providing $\TeX$-like mathematical typesetting. This means that you can use mathematical notation in your questions in a visually appealing way. How can I use MathJax? Basic information: This gives a quick start for people familiar with the $\TeX$-family of markup ...


47

Why do we have a policy? First and foremost: we believe that the responsibility for the integrity of an exam, contest, competition, etc. ultimately falls on the shoulders of the organizers. That said, the Mathematics Stack Exchange community is not an island unto itself: rather we exist within a larger macrocosm of people who do or are interested by ...


43

Formatting and writing This is not some random internet forum. We strive for well-composed questions and answers of lasting value -- so keep in mind that your question can be of interest to others as well. Posing a well-formatted question Use proper English to the best of your ability The use of proper spelling, grammar and punctuation makes your ...


42

Left and Right Implication Arrows Another way to display the arrows for right and left implication instead of using $\Rightarrow$, $\Leftarrow$ and $\Leftrightarrow$ which produces $\Rightarrow$, $\Leftarrow$ and $\Leftrightarrow$ respectively, you can use $\implies$ for $\implies$, $\impliedby$ for $\impliedby$ and $\iff$ for $\iff$ The latter of which ...


38

Those who have served as site moderators Katie Banks (appointed moderator pro tempore, August 2010—December 2010) Larry Wang (appointed moderator pro tempore, August 2010—December 2010) Isaac (appointed moderator pro tempore, August 2010—December 2010) KennyTM (appointed moderator pro tempore, August 2010—December 2010) Robin Chapman (elected moderator, ...


37

Degree symbol Standard Mathjax does not yet support a dedicated degree symbol, so here are some of the ways to try and emulate one : $$ \begin{array} \\ \text{45^\text{o}} & \text{renders as} & 45^\text{o} \\ \text{45^o} & \text{renders as} & 45^o \\ \text{45^\circ} & \text{renders as} & 45^\circ \\ \text{45^{\large\circ}} & \text{...


34

Long division $$ \require{enclose} \begin{array}{r} 13 \\[-3pt] 4 \enclose{longdiv}{52} \\[-3pt] \underline{4}\phantom{2} \\[-3pt] 12 \\[-3pt] \underline{12} \end{array} $$ $$ \require{enclose} \begin{array}{r} 13 \\[-3pt] 4 \enclose{longdiv}{52} \\[-3pt] \underline{4}\phantom{2} \\[-3pt] ...


28

Displaystyle and Textstyle Many things like fractions, sums, limits, and integrals display differently when written inline versus in a displayed formula. You can switch styles back and forth with \displaystyle and \textstyle in order to achieve the desired appearance. Here's an example switching back and forth in a displayed equation: $$\sum_{n=1}^\infty \...


27

Vertical Spacing Some formulas such as $\overline a+\overline b=\overline {a\cdot b}$, $\sqrt{a}-\sqrt{b}$, do not look quite right when it comes to vertical spacing. Fortunately, there is more than one way to fix this. One can for instance employ the \mathstrut command as follows: $\sqrt{\mathstrut a} - \sqrt{\mathstrut b}$ Which yields: $\sqrt{\...


26

To answer the first question, the acronym (or some might prefer initialism) PSQ, is derived from Problem Statement Question. In its purest form it is a question post that only contains the statement of a problem, in a form that is frequently found in exercise sections of textbooks, assignments and alike, e.g.: Prove that $\sum_{i=1}^n i= \frac{n+n^2}{2}$ ...


24

Equation numbering Simple equation To give an equation a number, use the \tag{}. To refer to it later, use \label{} to label this equation. When you want to refer to it, use \eqref{}. For example, $$e=mc^2 \tag{1}\label{eq1}$$ Equation $\eqref{eq1}$ is one the greatest equations in mankind history. Equation $\eqref{eq1}$ is produced using the following ...


23

Approach0 Searching for a specific formula is often rather difficult. A tool which is very suitable for this is the Approach0 search engine. Some basic information can be found in Guide for New Users (which contains also animations of some examples). If you want to know more about the project, you can look at the documentation. Approach0 uses mathquill ...


22

Most of the time it is in my opinion and observation possible to give a more detailed answer. Points that can often be addressed include: Suggesting minor improvements of the presentation or variations. Giving a high-level summary of the argument. Mentioning points where details might be added (even if not strictly needed). Putting the argument in a ...


22

When Editing Consider the age of the post. Whenever a post is edited, it is bumped to the top of the Active Questions list on the front page. This crowds out other posts which are also deserving of attention. If a question is relatively old and already has several answers, it likely doesn't need the renewed attention—such a post should not be edited ...


18

Pare question to its basics Pare your problem down to the minimum core problem. Instead of asking for $$\frac{\sin 2 k \sqrt{3 + q^3}}{b! (b-2)!} \int\limits_{x=0}^{\infty} \frac{e^{-x^2/(2 \sigma^2)} \cos \sqrt{3 + \sqrt{y}}}{\sqrt[3]{2 - 1/g}}\ dx$$ for constant $k$, $b$, $\sigma$, $y$, and $g$, eliminate all constants and ask about $$\int\limits_{x=0}^\...


Only top voted, non community-wiki answers of a minimum length are eligible