Latex QuickNote

Universal LaTeX Math Formula Syntax Manual

MathJax is an open source JavaScript mathematical sign rendering engine that runs in Web browsers, making it easy to display mathematical formulas in modern Web browsers, and is currently capable of parsing markup languages such as LaTex and MathML. languages such as LaTex and MathML. The MathJax project originated in 2009 and is currently hosted by the NumFOCUS Foundation and supported by the MathJax Consortium, a joint venture of the American Mathematical Society (AMS) and the Society for Industrial and Applied Mathematics (SIAM).

LaTeX is a high-quality typesetting format for generating complex tables and mathematical formulas, and is currently the de facto standard in the electronic and mathematical publishing industry. This article summarizes the LaTeX syntax often used in writing mathematical formulas, using Pandoc as the LaTex rendering engine (a command-line tool for markup language document conversion), so that you can easily refer to it when writing related scientific and technical articles.

Reserved Character

Reserved characters with special meanings in the LaTeX environment cannot be used directly, but must be realized by the specified syntax:

No. Sign LaTeX No. Sign LaTeX
1 # \# 6 { \{
2 % \% 7 } \}
3 ^\wedge 8 \sim
4 & \& 9 \backslash
5 _ \_      

Greek Alphabet

No. Sign LaTeX Uppercase letters LaTeX Use var as prefix LaTeX pronun.
1 α \alpha         /ˈælfə/
2 β \beta         /ˈbeɪtə/
3 γ \gamma Γ \Gamma Γ \varGamma /ˈɡæmə/
4 δ \delta Δ \Delta Δ \varDelta /ˈdɛltə/
5 ϵ \epsilon     ε \varepsilon /ˈɛpsɪlɒn/
6 ζ \zeta         /ˈzeɪtə/
7 η \eta         /ˈeɪtə/
8 θ \theta Θ \Theta ϑΘ \vartheta\varTheta /ˈθiːtə/
9 ι \iota         /aɪˈoʊtə/
10 κ \kappa     ϰ \varkappa /ˈkæpə/
11 λ \lambda Λ \Lambda Λ \varLambda /ˈlæmdə/
12 μ \mu         /mjuː/
13 ν \nu         /njuː/
14 ξ \xi Ξ \Xi Ξ \varXi /zaɪ, ksaɪ/
15 o o O O     /ˈɒmɪkrɒn/
16 π \pi Π \Pi ϖΠ \varpi\varPi /paɪ/
17 ρ \rho     ϱ \varrho /roʊ/
18 σ \sigma Σ \Sigma ςΣ \varsigma\varSigma /ˈsɪɡmə/
19 τ \tau         /taʊ, tɔː/
20 υ \upsilon Υ \Upsilon Υ \varUpsilon /ˈʌpsɪlɒn/
21 ϕ \phi Φ \Phi φΦ \varphi\varPhi /faɪ/
22 χ \chi         /kaɪ/
23 ψ \psi Ψ \Psi Ψ \varPsi /psaɪ/
24 ω \omega Ω \Omega Ω \varOmega /oʊˈmeɪɡə/
25 ϝ \digamma         /daɪ’gæmə/

Hebrew alphabet

No. Sign LaTeX English No. Sign LaTeX English
1 \aleph aleph 3 \gimel gimel
2 \beth beth 4 \daleth daleth

Binary Operator

No. Sign LaTeX No. Sign LaTeX
1 + + 20 \bullet
2 - 21 \oplus
3 × \times 22 \ominus
4 ÷ \div 23 \odot
5 ± \pm 24 \oslash
6 \mp 25 \otimes
7 \triangleleft 26 \bigcirc
8 \triangleright 27 \diamond
9 \cdot 28 \uplus
10 \setminus 29 \bigtriangleup
11 \star 30 \bigtriangledown
12 \ast 31 \lhd
13 \cup 32 \rhd
14 \cap 33 \unlhd
15 \sqcup 34 \unrhd
16 \sqcap 35 ⨿ \amalg
17 \vee 36 \wr
18 \wedge 37 \dagger
19 \circ 38 \ddagger

Binary Relation Symbol

No. Sign LaTeX No. Sign LaTeX
1 = = 49 \gneq
2 \ne 50 \geqq
3 \neq 51 \ngeq
4 \equiv 52 \ngeqq
5 \not\equiv 53 \gneqq
6 \doteq 54 \gvertneqq
7 \doteqdot 55 \lessgtr
8 =def \overset{\underset{\mathrm{def}}{}}{=} 56 \lesseqgtr
9 := := 57 \lesseqqgtr
10 \sim 58 \gtrless
11 \nsim 59 \gtreqless
12 \backsim 60 \gtreqqless
13 \thicksim 61 \leqslant
14 \simeq 62 \nleqslant
15 \backsimeq 63 \eqslantless
16 \eqsim 64 \geqslant
17 \cong 65 \ngeqslant
18 \ncong 66 \eqslantgtr
19 \approx 67 \lesssim
20 \thickapprox 68 \lnsim
21 \approxeq 69 \lessapprox
22 \asymp 70 \lnapprox
23 \propto 71 \gtrsim
24 \varpropto 72 \gnsim
25 < < 73 \gtrapprox
26 \nless 74 \gnapprox
27 \ll 75 \prec
28 ≪̸ \not\ll 76 \nprec
29 \lll 77 \preceq
30 ⋘̸ \not\lll 78 \npreceq
31 \lessdot 79 \precneqq
32 > > 80 \succ
33 \ngtr 81 \nsucc
34 \gg 82 \succeq
35 ≫̸ \not\gg 83 \nsucceq
36 \ggg 84 \succneqq
37 ⋙̸ \not\ggg 85 \preccurlyeq
38 \gtrdot 86 \curlyeqprec
39 \le 87 \succcurlyeq
40 \leq 88 \curlyeqsucc
41 \lneq 89 \precsim
42 \leqq 90 \precnsim
43 \nleq 91 \precapprox
44 \nleqq 92 \precnapprox
45 \lneqq 93 \succsim
46 \lvertneqq 94 \succnsim
47 \ge 95 \succapprox
48 \geq 96 \succnapprox

Geometric Sign

No. Sign LaTeX No. Sign LaTeX
1 \parallel 14 \lozenge
2 \nparallel 15 \blacklozenge
3 \shortparallel 16 \bigstar
4 \nshortparallel 17 \bigcirc
5 \perp 18 \triangle
6 \angle 19 \bigtriangleup
7 \sphericalangle 20 \bigtriangledown
8 \measuredangle 21 \vartriangle
9 45 45^\circ 22 \triangledown
10 \Box 23 \blacktriangle
11 \blacksquare 24 \blacktriangledown
12 \diamond 25 \blacktriangleleft
13 \Diamond \lozenge 26 \blacktriangleright

Logic Sign

No. Sign LaTeX No. Sign LaTeX
1 \forall 20 ¬ \neg
2 \exists 21 R \not\operatorname{R}
3 \nexists 22 \bot
4 \therefore 23 \top
5 \because 24 \vdash
6 & \And 25 \dashv
7 \lor 26 \vDash
8 \vee 27 \Vdash
9 \curlyvee 28 \models
10 \bigvee 29 \Vvdash
11 \land 30 \nvdash
12 \wedge 31 \nVdash
13 \curlywedge 32 \nvDash
14 \bigwedge 33 \nVDash
15 q¯ \bar{q} 34 \ulcorner
16 abc¯ \bar{abc} 35 \urcorner
17 q \overline{q} 36 \llcorner
18 abc \overline{abc} 37 \lrcorner
19 ¬ \lnot      

Set Sign

No. Sign LaTeX No. Sign LaTeX
1 {} \{ \} 23 \sqsubset
2 \emptyset 24 \supset
3 \varnothing 25 \Supset
4 \in 26 \sqsupset
5 \notin 27 \subseteq
6 \ni 28 \nsubseteq
7 \cap 29 \subsetneq
8 \Cap 30 \varsubsetneq
9 \sqcap 31 \sqsubseteq
10 \bigcap 32 \supseteq
11 \cup 33 \nsupseteq
12 \Cup 34 \supsetneq
13 \sqcup 35 \varsupsetneq
14 \bigcup 36 \sqsupseteq
15 \bigsqcup 37 \subseteqq
16 \uplus 38 \nsubseteqq
17 \biguplus 39 \subsetneqq
18 \setminus 40 \varsubsetneqq
19 \smallsetminus 41 \supseteqq
20 × \times 42 \nsupseteqq
21 \subset 43 \supsetneqq
22 \Subset 44 \varsupsetneqq

Arrow Sign

No. Sign LaTeX No. Sign LaTeX
1 \Rrightarrow 36 \longmapsto
2 \Lleftarrow 37 \rightharpoonup
3 \Rightarrow 38 \rightharpoondown
4 \nRightarrow 39 \leftharpoonup
5 \Longrightarrow 40 \leftharpoondown
6 \implies 41 \upharpoonleft
7 \Leftarrow 42 \upharpoonright
8 \nLeftarrow 43 \downharpoonleft
9 \Longleftarrow 44 \downharpoonright
10 \Leftrightarrow 45 \rightleftharpoons
11 \nLeftrightarrow 46 \leftrightharpoons
12 \Longleftrightarrow 47 \curvearrowleft
13 \iff 48 \circlearrowleft
14 \Uparrow 49 \Lsh
15 \Downarrow 50 \upuparrows
16 \Updownarrow 51 \rightrightarrows
17 \rightarrow 52 \rightleftarrows
18 \to 53 \rightarrowtail
19 \nrightarrow 54 \looparrowright
20 \longrightarrow 55 \curvearrowright
21 \leftarrow 56 \circlearrowright
22 \gets 57 \Rsh
23 \nleftarrow 58 \downdownarrows
24 \longleftarrow 59 \leftleftarrows
25 \leftrightarrow 60 \leftrightarrows
26 \nleftrightarrow 61 \leftarrowtail
27 \longleftrightarrow 62 \looparrowleft
28 \uparrow 63 \hookrightarrow
29 \downarrow 64 \hookleftarrow
30 \updownarrow 65 \multimap
31 \nearrow 66 \leftrightsquigarrow
32 \swarrow 67 \rightsquigarrow
33 \nwarrow 68 \twoheadrightarrow
34 \searrow 69 \twoheadleftarrow
35 \mapsto      

Special Sign

No. Sign LaTeX No. Sign LaTeX
1 \infty 33 \flat
2 \aleph 34 \natural
3 \complement 35 \sharp
4 \backepsilon 36 \diagup
5 ð \eth 37 \diagdown
6 \Finv 38 \centerdot
7 \hbar 39 \ltimes
8 \Im 40 \rtimes
9 ı \imath 41 \leftthreetimes
10 ȷ \jmath 42 \rightthreetimes
11 k \Bbbk 43 \eqcirc
12 \ell 44 \circeq
13 \mho 45 \triangleq
14 \wp 46 \bumpeq
15 \Re 47 \Bumpeq
16 \circledS 48 \doteqdot
17 ⨿ \amalg 49 \risingdotseq
18 % \% 50 \fallingdotseq
19 \dagger 51 \intercal
20 \ddagger 52 \barwedge
21 \ldots 53 \veebar
22 \cdots 54 \doublebarwedge
23 \smile 55 \between
24 \frown 56 \pitchfork
25 \wr 57 \vartriangleleft
26 \triangleleft 58 \ntriangleleft
27 \triangleright 59 \vartriangleright
28 \diamondsuit 60 \ntriangleright
29 \heartsuit 61 \trianglelefteq
30 \clubsuit 62 \ntrianglelefteq
31 \spadesuit 63 \trianglerighteq
32 \Game 64 \ntrianglerighteq

Points

Type Sign LaTeX
point 24x=0.5xor24x=0.5x \frac{2}{4}x=0.5x or {2 \over 4}x=0.5x
small point 24x=0.5x \tfrac{2}{4}x = 0.5x
big point (non-nested) 24=0.52c+2d+24=a \dfrac{2}{4} = 0.5 \qquad \dfrac{2}{c + \dfrac{2}{d + \dfrac{2}{4}}} = a
big point (nested) 2c+2d+24=a \cfrac{2}{c + \cfrac{2}{d + \cfrac{2}{4}}} = a

Numeric Function

Sign LaTeX
expab=ab,expb=eb,10m \exp_a b = a^b, \exp b = e^b, 10^m
lnc,lgd=loge,log10f \ln c, \lg d = \log e, \log_{10} f
sina,cosb,tanc,cotd,sece,cscf \sin a, \cos b, \tan c, \cot d, \sec e, \csc f
arcsina,arccosb,arctanc \arcsin a, \arccos b, \arctan c
arccotd,arcsece,arccscf \operatorname{arccot} d, \operatorname{arcsec} e, \operatorname{arccsc} f
sinha,coshb,tanhc,cothd \sinh a, \cosh b, \tanh c, \coth d
shk,chl,thm,cothn \operatorname{sh}k, \operatorname{ch}l, \operatorname{th}m, \operatorname{coth}n
argsho,argchp,argthq \operatorname{argsh}o, \operatorname{argch}p, \operatorname{argth}q
sgnr,|s| \operatorname{sgn}r, \left\vert s \right\vert
min(x,y),max(x,y) \min(x,y), \max(x,y)

If a special function Sign is required, then it can be customized using the \operatorname{} command:

Sign LaTeX
mydefinex \operatorname{mydefine}x

Surd

Sign LaTeX Sign LaTeX
\surd πn \sqrt[n]{\pi}
π \sqrt{\pi} x3+y323 \sqrt[3]{\frac{x^3+y^3}{2}}*_

Differentiation and Derivatives

Sign LaTeX
dt,dt,t,ψ dt, \mathrm{d}t, \partial t, \nabla\psi
dy/dx,dy/dx,dydx,dydx,2x1x2y dy/dx, \mathrm{d}y/\mathrm{d}x, \frac{dy}{dx}, \frac{\mathrm{d}y}{\mathrm{d}x}, \frac{\partial^2}{\partial x_1\partial x_2}y
,,f,f,f,f(3),y˙,y¨ \prime, \backprime, f^\prime, f', f'', f^{(3)}, \dot y, \ddot y
Sign LaTeX
sk0(modm) s_k \equiv 0 \pmod{m}
amodb a \bmod b
gcd(m,n),lcm(m,n) \gcd(m, n), \operatorname{lcm}(m, n)
,,, \mid, \nmid, \shortmid, \nshortmid

Limit

Sign LaTeX
limnxn \lim_{n \to \infty}x_n
limnxn \textstyle \lim_{n \to \infty}x_n

Scope and Projections

Sign LaTeX
minx,maxy,infs,supt \min x, \max y, \inf s, \sup t
limu,lim infv,lim supw \lim u, \liminf v, \limsup w
dimp,degq,detm,kerϕ \dim p, \deg q, \det m, \ker\phi
Prj,homl,z,argz \Pr j, \hom l, \lVert z \rVert, \arg z

Integral

Sign LaTeX
13e3/xx2dx \int\limits_{1}^{3}\frac{e^3/x}{x^2}\, dx
13e3/xx2dx \int_{1}^{3}\frac{e^3/x}{x^2}\, dx
NNexdx \textstyle \int\limits_{-N}^{N} e^x dx
NNexdx \textstyle \int_{-N}^{N} e^x dx
Ddxdy \iint\limits_D dx\,dy
Edxdydz \iiint\limits_E dx\,dy\,dz
Fdxdydzdt \iiiint\limits_F dx\,dy\,dz\,dt
(x,y)Cx3dx+4y2dy \int_{(x,y)\in C} x^3\, dx + 4y^2\, dy
(x,y)Cx3dx+4y2dy \oint_{(x,y)\in C} x^3\, dx + 4y^2\, dy

Note: Integral Sign is invoked by \int\_{}^{} command, Double Integral Sign is invoked by \iint\_{}^{}, and so on, up to four integrals can be supported.

Curve integrals can be invoked with the \oint command, but MathJax does not support this syntax, so it can be invoked with the \unicode{} command with the Unicode extension enabled:

Sign LaTeX Description
C \unicode{8751} \unicode{x222F}_C The Unicode code for the surface integral Sign is 8751 in decimal and x222F in hexadecimal;
C \unicode{8752} \unicode{x2230}_C The Unicode code for the 3D surface integral Sign is 8752 in decimal and x2230 in hexadecimal;
ccc \unicode{8753} \unicode{x2231}_c \unicode{8754} \unicode{x2232}_c \unicode{8755} \unicode{x2233}_c Other points Sign;

Large-scale Operators

Class Sign LaTeX Sign LaTeX
Summation ab \sum_{a}^{b} ab \textstyle \sum_{a}^{b}
coproduct ab \prod_{a}^{b} ab \textstyle \prod_{a}^{b}
residual product ab \coprod_{a}^{b} ab \textstyle \coprod_{a}^{b}
union ab \bigcup_{a}^{b} ab \textstyle \bigcup_{a}^{b}
intersection ab \bigcap_{a}^{b} ab \textstyle \bigcap_{a}^{b}
disjunction ab \bigvee_{a}^{b} ab \textstyle \bigvee_{a}^{b}
connective ab \bigwedge_{a}^{b} ab \textstyle \bigwedge_{a}^{b}

Superscript

Type Sign Code
superscript a2 a^2
  ax+3 a^{x+3}
     
suffix a2 a_2
combo 1030a2+2 10^{30} a^{2+2}
  ai,jbf a{i,j} b{f'}
     
mix of upper and lower scales x23 x_2^3
  x23 {x_2}^3
     
superscript of superscript 10108 10^{10^{8}}
hybrid logo X12X34ab \sideset{1^2}{3^4}X_a^b
  12!Ω34 {}_1^2!\Omega_3^4
     
Top markups ωα \overset{\alpha}{\omega}
  ωα \underset{\alpha}{\omega}
  ωγα \overset{\alpha}{\underset{\gamma}{\omega}}
  ωα \stackrel{\alpha}{\omega}
     
     
     
derivative x,y,f,f x,y x', y'', f', f'' x^\prime, y^{\prime\prime}
derivative point x˙,x¨ \dot{x}, \ddot{x}
Underline, upperline and Vector a^ b¯ c \hat a \ \bar b \ \vec c
  ab cd def^ \overrightarrow{a b} \ \overleftarrow{c d} \ \widehat{d e f}
  ghi jkl \overline{g h i} \ \underline{j k l}
     
     
arc AB \overset{\frown} {AB}
arrow An+μ1BTn±i1C A \xleftarrow{n+\mu-1} B \xrightarrow[T]{n\pm i-1} C
curly brackets 1+2++1005050 \overbrace{ 1+2+\cdots+100 }^{5050}
bottom curly brackets a+b++z26 \underbrace{ a+b+\cdots+z }_{26}
sum calculus k=1Nk2 \sum_{k=1}^N k^2
summation in text mode k=1Nk2 \textstyle \sum_{k=1}^N k^2
summation in fractions k=1Nk2a \frac{\sum_{k=1}^N k^2}{a}
summation in fractions k=1Nk2a \frac{\displaystyle \sum_{k=1}^N k^2}{a}
summation in fractions k=1Nk2a \frac{\sum\limits^{^N}_{k=1} k^2}{a}
product operation i=1Nxi \prod_{i=1}^N x_i
product operation i=1Nxi \textstyle \prod_{i=1}^N x_i
subtractive operation i=1Nxi \coprod_{i=1}^N x_i
subtractive operation i=1Nxi \textstyle \coprod_{i=1}^N x_i
limit limnxn \lim_{n \to \infty}x_n
limit limnxn \textstyle \lim_{n \to \infty}x_n
limit 13e3/xx2dx \int\limits_{1}^{3}\frac{e^3/x}{x^2}\, dx
limit 13e3/xx2dx \int_{1}^{3}\frac{e^3/x}{x^2}\, dx
limit NNexdx \textstyle \int\limits_{-N}^{N} e^x dx
limit NNexdx \textstyle \int_{-N}^{N} e^x dx
double integral Ddxdy \iint\limits_D dx\,dy
triple integral Edxdydz \iiint\limits_E dx\,dy\,dz
quadruple integral Fdxdydzdt \iiiint\limits_F dx\,dy\,dz\,dt
path integral (x,y)Cx3dx+4y2dy \int_{(x,y)\in C} x^3\, dx + 4y^2\, dy
loop integral (x,y)Cx3dx+4y2dy \oint_{(x,y)\in C} x^3\, dx + 4y^2\, dy
intersection i=1nEi \bigcap_{i=1}^n E_i
union i=1nEi \bigcup_{i=1}^n E_i

Binomial Coefficient

Type Sign LaTeX
binomial coefficient (nk) \binom{n}{k}
small binomial coefficients (nk) \tbinom{n}{k}
big binomial coefficients (nk) \dbinom{n}{k}

Matrix

xyzv
1
2
3
4
\begin{matrix}
x & y \\
z & v
\end{matrix}
 
|xyzv|
1
2
3
4
\begin{vmatrix}
x & y \\
z & v
\end{vmatrix}
 
xyzv
1
2
3
4
\begin{Vmatrix}
x & y \\
z & v
\end{Vmatrix}
 
[0000]
1
2
3
4
5
\begin{bmatrix}
0 & \cdots & 0 \\
\vdots & \ddots & \vdots \\
0 & \cdots & 0
\end{bmatrix}
 
{xyzv}
1
2
3
4
\begin{Bmatrix}
x & y \\
z & v
\end{Bmatrix}
 
(xyzv)
1
2
3
4
\begin{pmatrix}
x & y \\
z & v
\end{pmatrix}
 
(abcd)
1
2
3
4
\bigl( \begin{smallmatrix}
a&b\\
c&d
\end{smallmatrix} \bigr)

Array

Sign LaTeX      
![](https://latex.codecogs.com/svg.image?\large&space;\begin{array}{ c c c }a&b&S\hline&space;0&0&1\0&1&1\1&0&1\1&1&0\end{array})
1
2
3
4
5
6
7
8
\begin{array}{ | c | c | c | }
a & b & S \\
\hline
0 & 0 & 1 \\
0 & 1 & 1 \\
1 & 0 & 1 \\
1 & 1 & 0
\end{array}

Equations and Systems of Equations

1
2
3
4
5
\begin{cases}
3x + 5y + z \\
7x - 2y + 4z \\
-6x + 3y + 2z
\end{cases}

Definition of conditions

| Sign | LaTeX | | —- | —– |

1
2
3
4
5
f(n) =
\begin{cases}
n/2, & \text{if }n\text{ is even} \\
3n+1, & \text{if }n\text{ is odd}
\end{cases}

Multi-linear Equation

| Sign | LaTeX | | —- | —– |

1
2
3
4
\begin{align}
f(x) & = (a+b)^2\\
& = a^2+2ab+b^2
\end{align}

1
2
3
4
\begin{alignat}{2}
f(x) & = (a-b)^2 \\
& = a^2-2ab+b^2
\end{alignat}

1
2
3
4
\begin{array}{lcl}
z & = & a \\
f(x,y,z) & = & x + y + z
\end{array}

1
2
3
4
\begin{array}{lcr}
z & = & a \\
f(x,y,z) & = & x + y + z
\end{array}

Auto-Numbering

1
2
3
4
\begin{eqnarray}
E = mc^2 \\
e^{i\pi}+1=0
\end{eqnarray}
   
The entire equation is unnumbered, and you can use the {equation*}, {eqnarray*} environments; E=mc2eiπ+1=0
1
2
3
4
\begin{eqnarray*}
E = mc^2 \\
e^{i\pi}+1=0
\end{eqnarray*}
   
Individual equations are not numbered, you can add the \nonumber command after the specified equation; (1)E=mc2eiπ+1=0
1
2
3
4
\begin{eqnarray}
E = mc^2 \\
e^{i\pi}+1=0 \nonumber
\end{eqnarray}
   
Individual formulas appear or do not appear numbered, you can use the \tag{} or \notag command after the formula; E=mc2(b)eiπ+1=0
1
2
3
4
\begin{eqnarray}
E = mc^2 \notag\\
e^{i\pi}+1=0 \tag{b}
\end{eqnarray}

Bracket Size

Sign LaTeX
(((((]]]]] ( \bigl( \Bigl( \biggl( \Biggl( \dots \Biggr] \biggr] \Bigr] \bigr] ]
{{{{{ \{ \bigl \{ \Bigl \{ \biggl \{ \Biggl \{ \dots \Biggr\rangle \biggr\rangle \Bigr\rangle \bigr\rangle \rangle
||||||||| \vert \big \vert \Big \vert \bigg \vert \Bigg \vert \dots \Bigg \vert \bigg \vert \Big \vert \big \vert
\lfloor \bigl\lfloor \Bigl\lfloor \biggl\lfloor \Biggl\lfloor \dots \Biggr\rceil \biggr\rceil \Bigr\rceil \bigr\rceil \rceil
\uparrow \big\uparrow \Big\uparrow \bigg\uparrow \Bigg\uparrow \dots \Bigg\Downarrow \bigg\Downarrow \Big\Downarrow \big\Downarrow \Downarrow
\updownarrow \big\updownarrow \Big\updownarrow \bigg\updownarrow \Bigg\updownarrow \dots \Bigg\Updownarrow \bigg\Updownarrow \Big\Updownarrow \big\Updownarrow \Updownarrow
/////\\\\ / \big/ \Big/ \bigg/ \Bigg/ \dots \Bigg\backslash \bigg\backslash \Big\backslash \big\backslash \backslash

Spaces and Line Breaks

No. Sign LaTeX
double space ab a \qquad b
single space ab a \quad b
character space a b a\ b
character spaces in text mode a b a \text{ } b
big space ab a\;b
small space ab a\,b
tiny space ab ab
tiny space(Used to differentiate syntax) ab a b
no space(Used to distinguish multi-letter variables) ab \mathit{ab}

MathJax 3.0 removes the \\ forced line break function in single line equation environment, so the forced line break command \\ can only be used in multi-line environment such as eqnarray, align, array, matrix, etc. Besides, you can use \displaylines{} in line display commands: \displaylines{} forced line break command. In addition, you can use \\displaylines{} to force line breaks in \displaylines{} line display commands:

Sign LaTeX
y=1729xy=1729x \displaylines{y=1729x \\ y=1729-x}

Color

When writing LaTeX, it is supported to set Text, Sign or Background to the colors in the table below:

Apricot - Apricot Emerald - Emerald OliveGreen - OliveGreen RubineRed - RubineRed
Aquamarine - Aquamarine ForestGreen - ForestGreen Orange - Orange Salmon - Salmon
Bittersweet - Bittersweet Fuchsia - Fuchsia OrangeRed - OrangeRed SeaGreen - SeaGreen
Black - Black Goldenrod - Goldenrod Orchid - Orchid Sepia - Sepia
Blue - Blue Gray - Gray Peach - Peach SkyBlue - SkyBlue
BlueGreen - BlueGreen Green - Green Periwinkle - Periwinkle SpringGreen - SpringGreen
Blueviolet - Blueviolet GreenYellow - GreenYellow PineGreen - PineGreen Tan - Tan
BrickRed - BrickRed JungleGreen - JungleGreen Plum - Plum TealBlue - TealBlue
Brown - Brown Lavender - Lavender ProcessBlue - ProcessBlue Thistle - Thistle
BurntOrange - BurntOrange LimeGreen - LimeGreen Purple - Purple Turquoise - Turquoise
CadetBlue - CadetBlue Magenta - Magenta RawSienna - RawSienna Violet - Violet
CarnationPink - CarnationPink Mahogany - Mahogany Red - Red VioletRed - VioletRed
CornFlowerBlue - CornFlowerBlue Melon - Melon Redviolet - Redviolet WildStrawberry - WildStrawberry
Cerulean - Cerulean Maroon - Maroon RedOrange - RedOrange white - white
Cyan - Cyan MidnightBlue - MidnightBlue Rhodamine - Rhodamine Yellow - Yellow
Dandelion - Dandelion Mulberry - Mulberry RoyalBlue - RoyalBlue YellowGreen - YellowGreen
DarkOrchid - DarkOrchid NavyBlue - NavyBlue RoyalPurple - RoyalPurple YellowOrange - YellowOrange

Font Color

In the formula, you can use {\color{hues}text} to call the color command, where the hues parameter is the font color and the text parameter is the formula content:

Sign LaTeX
x2+2x1 {\color{Blue}x^2}+{\color{Orange}2x}-{\color{LimeGreen}1}

Background Color

The background color command can be invoked in the text environment using \colorbox{hues}{text}, where the hues parameter is the background color and the text parameter is the equation content:

Sign LaTeX
Thistext \colorbox{yellow}{Thistext}

When this command is used in a math environment, you need to add $\displaystyle + formula$ to the second argument:

Sign LaTeX
ab \colorbox{yellow}{$\displaystyle \frac{a}{b}$}

Note: Using the $\displaystyle + formula $ syntax in Markdown inline LaTeX formulas $.... $ will cause conflicts when using the $\displaystyle + formula $ syntax in Markdown, so this syntax should only be used for multi-line formulas $$... $$.

RGB Color

The colors of LaTeX formulas can be customized by using the \definecolor command:

Sign LaTeX
eiπ+1=0 \definecolor{mygreen}{RGB}{0,200,0} {\color{mygreen}e^{i \pi} + 1 = 0 }

Font Style

Font Bold

Sign LaTeX
ABCDEFGHIJKLMNOPQRSTUVWXYZ \boldsymbol{ABCDEFGHIJKLMNOPQRSTUVWXYZ}
abcdefghijklmnopqrstuvwxyz \boldsymbol{abcdefghijklmnopqrstuvwxyz}
0123456789 \boldsymbol{0123456789}

Boldface

Sign LaTeX
ABCDEFGHIJKLMNOPQRSTUVWXYZ \mathbf{ABCDEFGHIJKLMNOPQRSTUVWXYZ}
abcdefghijklmnopqrstuvwxyz \mathbf{abcdefghijklmnopqrstuvwxyz}
0123456789 \mathbf{0123456789}

Chalkboard Newspaper

Sign LaTeX
ABCDEFGHIJKLMNOPQRSTUVWXYZ \mathbb{ABCDEFGHIJKLMNOPQRSTUVWXYZ}
abcdefghijklmnopqrstuvwxyz \mathbb{abcdefghijklmnopqrstuvwxyz}
0123456789 \mathbb{0123456789}

Italic

Sign LaTeX
ABCDEFGHIJKLMNOPQRSTUVWXYZ \mathit{ABCDEFGHIJKLMNOPQRSTUVWXYZ}
abcdefghijklmnopqrstuvwxyz \mathit{abcdefghijklmnopqrstuvwxyz}
0123456789 \mathit{0123456789}

Times New Roman

Sign LaTeX
ABCDEFGHIJKLMNOPQRSTUVWXYZ \mathrm{ABCDEFGHIJKLMNOPQRSTUVWXYZ}
abcdefghijklmnopqrstuvwxyz \mathrm{abcdefghijklmnopqrstuvwxyz}
0123456789 \mathrm{0123456789}

Sans Serif

Sign LaTeX
ABCDEFGHIJKLMNOPQRSTUVWXYZ \mathsf{ABCDEFGHIJKLMNOPQRSTUVWXYZ}
abcdefghijklmnopqrstuvwxyz \mathsf{abcdefghijklmnopqrstuvwxyz}
0123456789 \mathsf{0123456789}

Handwriting

Sign LaTeX
ABCDEFGHIJKLMNOPQRSTUVWXYZ \mathcal{ABCDEFGHIJKLMNOPQRSTUVWXYZ}
abcdefghijklmnopqrstuvwxyz \mathcal{abcdefghijklmnopqrstuvwxyz}
0123456789 \mathcal{0123456789}

Gothic

Sign LaTeX
ABCDEFGHIJKLMNOPQRSTUVWXYZ \mathfrak{ABCDEFGHIJKLMNOPQRSTUVWXYZ}
abcdefghijklmnopqrstuvwxyz \mathfrak{abcdefghijklmnopqrstuvwxyz}
0123456789 \mathfrak{0123456789}

Small Script

Sign LaTeX
ABCDEFGHIJKLMNOPQRSTUVWXYZ {\scriptstyle\text{ABCDEFGHIJKLMNOPQRSTUVWXYZ}}
abcdefghijklmnopqrstuvwxyz {\scriptstyle\text{abcdefghijklmnopqrstuvwxyz}}
0123456789 {\scriptstyle\text{0123456789}}

Font Size

Sign LaTeX
abctiny {\tiny abc tiny}
abcscriptsize {\scriptsize abc scriptsize}
abcsmall {\small abc small}
abcnormal {\normalsize abc normal}
abclarge {\large abc large}
abcLarge {\Large abc Large}
abcLARGE {\LARGE abc LARGE}
abchuge {\huge abc huge}s
abcHuge {\Huge abc Huge}