# $\LaTeX$ Guide

$\huge \text{Start}$ This will show like this $1 + 2 + 3 = 6$ And this appears as

$1 + 2 + 3 = 6$

But it will only show in the middle of the page.

You can apply the codes inside of $\backslash( \backslash)$ or $\backslash[\backslash]$ as shown in the picture above.

Here are the codes.

2 \times 3 appears as $2 \times 3$

2 \cdot 3 appear as $2 \cdot 3$

2 \div 3 appear as $2 \div 3$

\left(\frac 12 + \frac12 \right) appear as $\left(\frac 12 + \frac12 \right)$

\left(\dfrac 12 + \dfrac12 \right) appear as $\left(\dfrac 12 + \dfrac12 \right)$

\frac12 appear as $\frac12$

\dfrac 12 appear as $\dfrac 1 2$

\frac{13}{24} appear as $\frac{13}{24}$

\dfrac{13}{24} appear as $\dfrac{13}{24}$

\frac{\frac {11}{22}}{\frac {11}{22}} appear as $\frac{\frac {11}{22}}{\frac {11}{22}}$

\dfrac{\dfrac {11}{22}}{\dfrac {11}{22}} appear as $\dfrac{\dfrac {11}{22}}{\dfrac {11}{22}}$

\cfrac{1}{1+\cfrac{2}{2+\cfrac{3}{2}}} appear as $\cfrac{1}{1+\cfrac{2}{2+\cfrac{3}{2}}}$

$\text{\{1,2,3,4\}}$ appear as $\{1,2,3,4\}$

2^2 appear as $2^2$

2^{2^{2^2}} appear as $2^{2^{2^2}}$

2_2 appear as $2_2$

2^{10} appear as $2^{10}$

\sqrt{55} appear as $\sqrt{55}$

\sqrt 5 appear as $\sqrt 5$

\sqrt{\frac 56} appear as $\sqrt{\frac56}$

\sqrt4 appear as $\sqrt4$

\sqrt {\frac93} appear as $\sqrt  \frac 93$

\Rightarrow appear as $\Rightarrow$.

\Leftarrow appear as $\Leftarrow$

\Leftrightarrow appear as $\Leftrightarrow$

\Uparrow appear as $\Uparrow$

\Downarrow appear as $\Downarrow$

\Updownarrow appear as $\Updownarrow$

\rightarrow appear as $\rightarrow$

\longrightarrow appear as $\longrightarrow$

\longleftarrow appear as $\longleftarrow$

\leftarrow appear as $\leftarrow$

\leftrightarrow appear as $\leftrightarrow$

\uparrow appear as $\uparrow$

\downarrow appear as $\downarrow$

\updownarrow appear as $\updownarrow$

\implies appear as $\implies$

\sum appear as $\sum$

\displaystyle \sum_{i = x}^y will appear as $\displaystyle \sum_{i = x}^y$

\sum_{i = x}^y appears as $\sum_{i = x}^y$

\vdots appear as $\vdots$

\ldots appear as $\ldots$

\ddots appear as $\ddots$

\pm appear as $\pm$

\mp appear as $\mp$

a \le b appear as $a \le b$

c \ge d appear as $c \ge d$

e \ne f appear as $e \ne f$

\equiv appear as $\equiv$

\mod{b} appear as $\mod{b}$

\approx appear as $\approx$

\cong appear as $\cong$

\boxed{0} appear as $\boxed{0}$

\infty appear as $\infty$

\propto appear as $\propto$

180^\circ appear as $180^\circ$

\pi appear as $\pi$

\Pi appear as $\Pi$

\amalg appear as $\amalg$

\triangle appear as $\triangle$

\bigtriangledown appear as $\bigtriangledown$

\triangleleft appear as $\triangleleft$

\triangleright appear as $\triangleright$

\square appear as $\square$

\bigstar appear as $\bigstar$

\bigcirc appear as $\bigcirc$

\angle ABC appear as $\angle ABC$

X \cong Y appear as $X \cong Y$

X \sim Y appear as $X \sim Y$

AB \parallel CD appear as $AB \parallel CD$

AB\perp CD appear as $AB\perp CD$

\sin \theta appear as $\sin \theta$

\cos \theta appear as $\cos \theta$

\tan \theta appear as $\tan \theta$

\sec \theta appear as $\sec \theta$

\csc \theta appear as $\csc \theta$

\cot \theta appear as $\cot \theta$

\log_{10} appear as $\log_{10}$

\ln appear as $\ln$

\int appear as $\int$

\int^1_0 appear as $\int^1_0$

\lim_{x \to y} appear as $\lim_{x \to y}$

\displaystyle \lim_{x \to y} appear as $\displaystyle \lim_{x \to y}$

\theta appear as $\theta$

\alpha appear as $\alpha$

\beta appear as $\beta$

\mu appear as $\mu$

\lambda appear as $\lambda$

\Delta appear as $\Delta$

\delta appear as $\delta$

\lfloor b + c \rfloor appear as $\lfloor b + c \rfloor$

\lceil c +d \rceil appear as $\lceil c +d \rceil$

\binom xy appear as $\binom xy$

\dbinom xy appear as $\dbinom xy$

10\% appears as $10\%$

\overbrace{abc} appears as $\overbrace{abc}$

\underbrace{abc} appears as $\underbrace{abc}$

\overline{abc} appears as $\overline{abc}$

\underline{abc} appear as $\underline{abc}$

\widetilde{abc} appear as $\widetilde{abc}$

\widehat{abc} appears as $\widehat{abc}$

\subset appear as $\subset$

\subseteq appear as $\subseteq$

\supset appear as $\supset$

\not\subset appear as $\not\subset$

\supseteq appears as $\supseteq$

\nsubseteq appear as $\nsubseteq$

\sqsubset appear as $\sqsubset$

\sqsupset appear as $\sqsupset$

\sqsubseteq appear as $\sqsubseteq$

\sqsupseteq appear as $\sqsupseteq$

\in appear as $\in$

\not \in appear as $\not \in$

\cap appear as $\cap$

\cup appear as $\cup$

\sqcap appear as $\sqcap$

\sqcup appear as $\sqcup$

\oplus appear as $\oplus$

\ominus appear as $\ominus$

\otimes appear as $\otimes$

\odot appear as $\odot$

\oslash appear as $\oslash$

\forall appear as $\forall$

\mathbb{Z} appear as $\mathbb{Z}$

\mathbb{N} appear as $\mathbb{N}$

\mathbb{R} appear as $\mathbb{R}$

\text{I like math} appear as $\text{I like math}$

\smile appear as $\smile$

\frown appear as $\frown$

To add colors, you can use \color{blue}, \color{red}, \color{green}, \color{violet} etc. For example: \color{blue} \text{Write something!} appear as $\color{#3D99F6} \text{Write something!}$

$\huge \text{End}$

• You can toggle LaTex to see all the codes(Ignore LaTex:) and you can comment below to if you want more codes. Note by Munem Shahriar
3 years, 4 months ago

This discussion board is a place to discuss our Daily Challenges and the math and science related to those challenges. Explanations are more than just a solution — they should explain the steps and thinking strategies that you used to obtain the solution. Comments should further the discussion of math and science.

When posting on Brilliant:

• Use the emojis to react to an explanation, whether you're congratulating a job well done , or just really confused .
• Ask specific questions about the challenge or the steps in somebody's explanation. Well-posed questions can add a lot to the discussion, but posting "I don't understand!" doesn't help anyone.
• Try to contribute something new to the discussion, whether it is an extension, generalization or other idea related to the challenge.

MarkdownAppears as
*italics* or _italics_ italics
**bold** or __bold__ bold
- bulleted- list
• bulleted
• list
1. numbered2. list
1. numbered
2. list
Note: you must add a full line of space before and after lists for them to show up correctly
paragraph 1paragraph 2

paragraph 1

paragraph 2

[example link](https://brilliant.org)example link
> This is a quote
This is a quote
    # I indented these lines
# 4 spaces, and now they show
# up as a code block.

print "hello world"
# I indented these lines
# 4 spaces, and now they show
# up as a code block.

print "hello world"
MathAppears as
Remember to wrap math in $$ ... $$ or $ ... $ to ensure proper formatting.
2 \times 3 $2 \times 3$
2^{34} $2^{34}$
a_{i-1} $a_{i-1}$
\frac{2}{3} $\frac{2}{3}$
\sqrt{2} $\sqrt{2}$
\sum_{i=1}^3 $\sum_{i=1}^3$
\sin \theta $\sin \theta$
\boxed{123} $\boxed{123}$

Sort by:

@Munem Sahariar $\text{Thanks for this guide,Really needed it}$

- 3 years ago

You could stylize LaTeX as $\LaTeX$

- 3 years, 4 months ago

Done!

- 3 years, 4 months ago

how?

- 11 months, 1 week ago

This guide is very helpful as I'm just learning to use LaTex, thank you.

I do have one question: is there a way to push lines slightly to the right (like the Tab feature in word processors) without pushing them all the way to the middle? For example, in the lines

${(p-1)}^p \equiv -1 \pmod {p^2}$

$\equiv {p^2-1} \pmod {p^2}$

$\equiv {(p-1)(p+1)} \pmod {p^2}$

I would really like to have the equivalence symbol in the second and third lines line up with the one in the first line. Is there a way to do that?

- 2 years, 11 months ago

@zico quintina Like this? \begin{aligned} (p-1)^p & \equiv -1 \pmod {p^2} \\ & \equiv p^2 -1 \pmod {p^2} \\ & \equiv (p-1)(p+1) \pmod {p^2} \\ \end{aligned}

- 2 years, 11 months ago

Yes! Perfect, thank you very much!

- 2 years, 11 months ago

This one is my favourite:

text

=

- 2 years, 10 months ago

There is another guide that was posted early. :)

- 3 years ago

In those latex codes, there is a typo. \sqrt{4} appears as $\sqrt{4}$, not $\sqrt{4}$.

- 3 years ago

Fixed it. Thanks

- 3 years ago

@Munem Sahariar how to get that box in which you have written synatx and effect???

- 3 years ago

@Saksham Jain Like this?

$\text{> (1)}$

$\text{> (2)}$

$\text{> (3)}$

Appear as

(1)

(2)

(3)

- 3 years ago

yes .thanks

- 3 years ago

Hi

- 3 years ago

hi

- 3 years ago

- 2 years, 12 months ago

- 2 years, 12 months ago

yes

- 2 years, 12 months ago

Use $\text{[Text](Link)}$

For example: The text is ''Brilliant'' and the link is https://brilliant.org/

$\text{[Brilliant](https://brilliant.org/)}$ appear as Brilliant

- 2 years, 12 months ago

ok

- 2 years, 12 months ago

Check out mine too! Located above

- 2 years, 10 months ago

How to get angle sign?

- 2 years, 11 months ago

\angle

- 2 years, 11 months ago

Thanks

- 2 years, 11 months ago

lkkl

- 2 years, 8 months ago

jkk

- 2 years, 8 months ago

Thanks very much

- 2 years, 11 months ago

Neat.

- 2 years, 8 months ago

Ikr

- 2 years, 8 months ago

@Munem Sahariar How to write language codes in problems(programming language codes)??

- 3 years ago

You can do the following:

$\text{}$

$\text{}$

Anything written in the middle of these three single back-quotes will appear as

 1 Write anything! 

- 3 years ago

and how to add title like in which language code is written ??

- 3 years ago appear as

 1 Write anything 

- 3 years ago

ok .thanks to you and your latex guide.

- 3 years ago

What about rising and falling factorials

- 3 years ago

- 3 years ago

Yes

- 3 years ago

And so?

- 3 years ago

How to add them in $\LaTeX$

- 3 years ago

• For a rising factorial: $x^{\overline{n}}$

• For a falling factorial: $x^{\underline{n}}$

- 3 years ago

Thanks

- 3 years ago

ok

- 2 years, 8 months ago

Is there a 'strikethrough' feature in LaTeX? I'm trying to show a a product of fractions with several factors in numerators and denominators cancelling each other out. So far all I've found is the \not feature, but this works very poorly; e.g. when I try \not{147}, I get $\not{147}$, with only the 1 crossed out.

I would like to be able to cross out entire numbers; ideally, I'd also like to show either the strikethrough or the number (preferably not both) in a variety of colors.

Do you know whether this can be done? Thanks!

- 2 years, 5 months ago

Maybe there is.... who knows

- 2 years, 5 months ago

\require{cancel} \cancel{147}

- 2 years, 4 months ago

@Munem Shahriar , I suggest you to add

\pmod{a}

which appears as

$\pmod{a}$

- 2 years, 1 month ago

@Munem Shahriar, Sometimes I see people who write under the \underbrace and how do we do that?

- 2 years, 1 month ago

You can use \underbrace{ }_{ }. For example:

\underbrace{1222.....2}_{1000 ~ 2's}

$\underbrace{1222.....2}_{1000 ~ 2's}$

- 2 years, 1 month ago

THank you

- 2 years, 1 month ago

@Munem Shahriar, Can you please help me align the equal signs in the below $\LaTeX$

\begin{aligned} \pi & = 4 \sum_{k=0}^\infty \frac{(-1)^k}{2k+1} \\ &= 3 \sum_{k=0}^\infty (-1)^k \left[\frac{1}{6k+1} + \frac{1}{6k+5} \right] \\ &= 4 \sum_{k=0}^\infty (-1)^k \left[\frac{1}{10k+1} - \frac{1}{10k+3} + \frac{1}{10k+5} - \frac{1}{10k+7} + \frac{1}{10k+9}\right] \\ &= \sum_{k=0}^\infty (-1)^k \left[\frac{3}{14k+1} - \frac{3}{14k+3} + \frac{3}{14k+5} - \frac{4}{14k+7} + \frac{4}{14k+9} - \frac{4}{14k+11} + \frac{4}{14k+13}\right] \\ &= \sum_{k=0}^\infty (-1)^k \left[\frac{2}{18k+1}+\frac{3}{18k+3}+\frac{2}{18k+5}-\frac{2}{18k+7}-\frac{2}{18k+11}+\frac{2}{18k+13}+\frac{3}{18k+15}+\frac{2}{18k+17}\right] \\ &= \sum_{k=0}^\infty (-1)^k \left[\frac{3}{22k+1}-\frac{3}{22k+3}+\frac{3}{22k+5}-\frac{3}{22k+7}+\frac{3}{22k+9}+\frac{8}{22k+11}+\frac{3}{22k+13}-\frac{3}{22k+15}+\frac{3}{22k+17}-\frac{3}{22k+19}+\frac{1}{22k+21}\right]\end{aligned}

- 2 years, 1 month ago

done!

- 2 years, 1 month ago

THank you

- 2 years, 1 month ago

@Agnishom Chattopadhyay, I forgot to mention but this is actually for my megaproject: $\pi$, a beautiful number

- 2 years, 1 month ago

Can you help:

\displaystyle \Rightarrow I(n) = \int_{0}^{\pi} = - \sin^{n-1} x \cos x \right|_{0}^{\pi}

- 2 years, 1 month ago

Help:

\begin{aligned} \pi & = \sum_{k=0}^\infty \frac{1}{16^k} \left[\frac{4}{8k+1} - \frac{2}{8k+4} - \frac{1}{8k+5} - \frac{1}{8k+6}\right] \\ &= \frac{1}{2} \sum_{k=0}^\infty \frac{1}{16^k} \left[\frac{8}{8k+2} + \frac{4}{8k+3} + \frac{4}{8k+4} - \frac{1}{8k+7} \right] \\ &= \frac{1}{16} \sum_{k=0}^\infty \frac{1}{256^k} \left[\frac{64}{16k+1} - \frac{32}{16k+4} - \frac{16}{16k+5} - \frac{16}{16k+6} + \frac{4}{16k+9} - \frac{2}{16k+12} - \frac{1}{16k+13} - \frac{1}{16k+14} \right] \\ &= \frac{1}{32} \sum_{k=0}^\infty \frac{1}{256^k} \left[\frac{128}{1k+2} + \frac{64}{16k+3}+\frac{64}{16k+4}-\frac{16}{16k+7} + \frac{8}{16k+10}+\frac{4}{16k+11}+\frac{4}{16k+12}-\frac{1}{16k+15}\right] \\ &= \frac{1}{32} \sum_{k=0}^\infty \frac{1}{4096^k} \left[\frac{256}{24k+2}+\frac{192}{24k+3}-\frac{256}{24k+4}-\frac{96}{24k+6}-\frac{96}{24k+8}+\frac{16}{24k+10}-\frac{4}{24k+12}-\frac{3}{24k+15}-\frac{6}{24k+16}-\frac{2}{24k+18}-\frac{1}{24k+20}\right] \\ &= \frac{1}{64} \sum_{k=0}^\infty \frac{1}{4096^k} \left[\frac{256}{24k+1}+\frac{256}{24k+2}-\frac{384}{24k+3}-\frac{256}{24k+4}-\frac{64}{24k+5}+\frac{96}{24k+8}+\frac{64}{24k+9}+\frac{16}{24k+10}+\frac{8}{24k+12}-\frac{4}{24k+13}+\frac{6}{24k+15}+\frac{6}{24k+16}+\frac{1}{24k+17}+\frac{1}{24k+18}-\frac{1}{24k+20}-\frac{1}{24k+20}\right] \\ &= \frac{1}{96} \sum_{k=0}^\infty \frac{1}{4096^k}\left[\frac{256}{24k+2}+\frac{64}{24k+3}+\frac{128}{24k+5}+\frac{352}{24k+6}+\frac{64}{24k+7}+\frac{288}{24k+8}+\frac{128}{24k+9}+\frac{80}{24k+10}+\frac{20}{24k+12}-\frac{16}{24k+14}-\frac{1}{24k+15}+\frac{6}{24k+16}-\frac{2}{23k+17}-\frac{1}{24k+19}+\frac{1}{24k+20}-\frac{2}{24k+21}\right] \\ &= \frac{1}{96} \sum_{k=0}^\infty \frac{1}{4096^k} \left[\frac{256}{24k+1} + \frac{320}{24k+3} + \frac{256}{24k+4} - \frac{192}{24k+5}-\frac{224}{24k+6}-\frac{64}{24k+7}-\frac{192}{24k+8}-\frac{64}{24k+9}-\frac{64}{24k+10}-\frac{28}{24k+12}-\frac{4}{24k+13}-\frac{5}{24k+15}+\frac{3}{24k+17}+\frac{1}{24k+18}+\frac{1}{24k+19}+\frac{1}{24k+21}-\frac{1}{24k+22}\right] \\ & = \frac{1}{96} \sum_{k=0}^\infty \frac{1}{4096^k} \left[\frac{512}{24k+1}-\frac{256}{24k+2}+\frac{64}{24k+3}-\frac{512}{24k+4}-\frac{32}{24k+6}+\frac{64}{24k+7}+\frac{96}{24k+8}+\frac{64}{24k+9}+\frac{48}{24k+10}-\frac{12}{24k+12}-\frac{8}{24k+13}-\frac{16}{24k+14}-\frac{1}{24k+15}-\frac{6}{24k+16}-\frac{2}{24k+18}-\frac{1}{24k+19}-\frac{1}{24k+20}-\frac{1}{24k+21}\right] \\ &=\frac{1}{4096} \sum_{k=0}^\infty \frac{1}{65536^k} \left[\frac{16384}{32k+1}-\frac{8192}{32k+4}-\frac{4096}{32k+5}-\frac{4096}{32k+6}+\frac{1024}{32k+9}-\frac{512}{32k+12}-\frac{256}{32k+13}-\frac{256}{32k+14}+\frac{64}{32k+17}-\frac{32}{32k+20}-\frac{16}{32k+21}-\frac{16}{32k+22}+\frac{4}{32k+25}-\frac{2}{32k+28}-\frac{1}{32k+29}-\frac{32k+30}\right] \end{aligned}

P.S. The error is in the last lines but I could not find it

- 2 years, 1 month ago

The last code \frac{32k+30} is wrong.

- 2 years, 1 month ago

Thank you

- 2 years, 1 month ago

\frown

- 2 years, 1 month ago

$\frown \smile$

- 2 years, 1 month ago

Y doesn’t it work?

- 2 years, 1 month ago

/frown

- 2 years, 1 month ago

\frown

- 2 years, 1 month ago

/frown /smile

- 2 years, 1 month ago

\frown\smile

- 2 years, 1 month ago

You did not enclose it with the: $$and$$

- 2 years, 1 month ago

(\frown)

- 2 years, 1 month ago

$frown$

- 2 years, 1 month ago

$\hat{\frown}$

- 2 years, 1 month ago

$\frac123$ Please elaborate on how to properly use fractions.

- 2 years ago

If the numerator and denominator of a fraction are two digit(or more digit) numbers then you have to use braces(Not necessary for single digit numbers). For example:

\frac{12}{34} appear as $\frac{12}{34}$.

- 2 years ago

How does \align work?

- 1 year, 10 months ago

nice $\text{Latex}$ guide !! It really helped me a lot :))

- 11 months, 1 week ago

How to get huge brackets?

- 3 years ago

\huge \left(a + b \right ) appear as

$\huge \left(\dfrac{a}{b}\right)$

- 3 years ago

I have tried it in this but it is still not appearing like i want it. Latex \huge\displaystyle \sum{k=1}^{\infty}({\frac{\displaystyle \sum{n=1}^{k}nk}{\displaystyle\prod_{n=1}^{k}nk}})\ $\huge\displaystyle \sum_{k=1}^{\infty}({\frac\sum_{n=1}^{k}nk}{\displaystyle\prod_{n=1}^{k}nk}}) = \$

- 3 years ago

Use \left( \right)

\large \displaystyle \sum{k=1}^{\infty} \left({\frac{\displaystyle \sum{n=1}^{k}nk}{\displaystyle\prod_{n=1}^{k}nk}} \right) = \ x

Appear as

$\large \displaystyle \sum_{k=1}^{\infty}\left({\frac\sum_{n=1}^{k}nk}{\displaystyle\prod_{n=1}^{k}nk}}\right) = \$

- 3 years ago

However the equation coming format has changed

- 3 years ago

I want that nothing gets changed accept the brackets

- 3 years ago

The comment has been fixed. Check it

- 3 years ago

Thanks for this awesome latex code.

- 3 years ago

@Munem Sahariar Help me in this code \large \dfrac{\dfrac{1}{3}}{1-\dfrac{\dfrac{{5}{192}}{\dfrac{1}{3}}}

- 3 years ago

Do you mean this?

$\large \dfrac{\dfrac 13}{1 - \dfrac{\dfrac5{192}}{\dfrac13}}$

- 3 years ago

Yes

- 3 years ago

How did you learn latex?

- 3 years ago

In some various ways.

- 3 years ago

Which various ways?

- 3 years ago

Etc....

- 3 years ago

I have published a solution in a complete.Do you have any idea to make it better?Here it is

- 3 years ago

@Munem Sahariar How to add rising and falling factorials ?

- 3 years ago

- 2 years, 11 months ago

@Munem Sahariar , Can you help me here ?

- 3 years ago

Thanks. How can I help?

- 3 years ago

sometimes the feature of seeing the latex code by hovering over the cursor goes away at my laptop..why does it happens like that and how to cure it.

- 3 years ago

Sorry, I didn't understand the issue. Please clarify it or give screenshots.

Seeing LaTex feature works fine for me.

- 3 years ago

well fine for now...i will send them if i have the issue again, btw thanks! $\ddot\smile$

- 3 years ago

How do you insert code into a problem or solution? (Edit): Code as in the coding environment: https://brilliant.org/codex/

- 3 years ago

U could get screenshots for it

- 3 years ago

It was mentioned at top of the page.

''You can apply the codes inside of $\backslash( \backslash)$ and $\backslash[\backslash]$''

For example:

• $\backslash( 2 \text{\times} 3 \backslash)$ appear as $2 \times 3$

• $\backslash[ 2 \text{\times} 3 \backslash]$ appear as $2 \times 3$

- 3 years ago

I meant the coding environment

- 3 years ago

I think It is only possible for staffs.

But you can do the following:

$\text{}$

$\text{}$

Anything written in the middle of these three single back-quotes will appear as

 1 Write anything. 

- 3 years ago

Ah, that's too bad. Thanks for the information!

- 3 years ago

what r=the heck are yu on abouy

- 3 years ago

w

- 3 years ago