Do math typesetting in one markdown file using KaTeX
Chinese version: Zhihu
Use Vs Code
and extension Markdown Preview Enhanced
(by Yiyi Wang) you can preview math typesetting in markdown file using KaTeX, see Math.
By the way, I use Markdown All in One
(by Yu Zhang) to creat table of contents and export markdown to html, Markdown Footnote
(by Mai Hou) to automatically add footnotes and markdown-index
(by legendmohe) to automatically add serial numbers on titles.
Here I introduce some basic fomulas most used in Calculus, for more information, see KaTeX.
The contents in every section are: code, preview.
1. Accents
1.1. Prime
$ f'(x) $
1.2. Vector
$ \vec {a} $
$ \overrightarrow {PP_0} $
1.3. Hat
$ \hat{\theta} $
$ \widehat{ac} $
2. Delimiters
2.1. Parentheses
$ (x) $
2.2. Brackets
$ [x] $
2.3. Braces
$ \{x\} $
2.4. Absolute Value
$ |x| $
2.5. Delimiter Sizing
( \big( \Big( \bigg( \Bigg(
$ (\csc x)' = \Big ( \frac {1} {\sin x} \Big )' $
$ \frac {d^2f} {dx^2} \big | _{x=x_0} $
3. Environments
3.1. Piecewise Function
$ f(x) = \begin{cases} x, &\text{if } x \ge 0 \\ -x, &\text{if } x < 0 \end{cases} $
3.2. Vmatrix
$ \begin{vmatrix} a & b \\ c & d \end{vmatrix} $
4. Layout
4.1. Line Breaks
$ a b \\ c d $
5. Greek Letters
5.1. alpha
$ \alpha $
5.2. beta
$ \beta $
5.3. Delta
$ \Delta $
5.4. theta
$ \theta $
5.5. lambda
$ \lambda $
5.6. mu
$ \mu $
5.7. xi
$ \xi $
5.8. pi
$ \pi $
5.9. Partial Derivative
$ \partial $
6. Binary Operators
6.1. Plus
$ x + y $
6.2. Minus
$ x - y $
6.3. Times
$ x \times y $
6.4. Divide
$ x \div y $
6.5. Intersect
$ (0,5) \cap (-1,3) $
6.6. Union
$ (-\infty,0) \cup (0,+\infty) $
7. Vertical Layout
7.1. Superscript
$ e^x $
7.2. Subscript
$ x_n $
8. Spacing
$ a b \\ a \space b $
or
$ a b \\ a \ b $
9. Logic and Set Theory
9.1. in
$ k \in \bf {Z} $
9.2. subset
$ D \subset R $
10. Big Operators
10.1. Integration
$ \int _{-\infty} ^{+\infty} e^x dx $
$ \iint \limits _D f(x,y) dxdy $
10.2. Sum
$ \sum \limits _{i=1} ^n f(x) $
$ \sum \limits _{\substack {0<i<m \\ 0<j<n}} f(x) $
10.3. Product
$ \prod \limits _{k=1} ^n a_k $
11. Fractions
$ \frac {x^2} {x+1} $
$ \frac {a} {1 + \frac {1} {b}} $
12. Math Operators
12.1. sin
$ \sin x $
12.2. cos
$ \cos x $
12.3. tan
$ \tan x $
12.4. arcsin
$ \arcsin x $
12.5. arctan
$ \arctan x $
12.6. lg
$ \lg x $
12.7. ln
$ \ln x $
12.8. log
$ \log x $
12.9. Radical Sign
$ \sqrt x $
$ \sqrt [3] {x^2+2x+1} $
12.10. lim
$ f'(x) = \lim \limits _{\Delta x \rightarrow 0} \frac {f(x + \Delta x) - f(x)} {\Delta x} $
13. Relations
13.1. equal to
$ x = y $
13.2. not equal to
$ x \ne y $
13.3. less than
$ x < y $
13.4. greater than
$ x > y $
13.5. less than or equal to
$ x \le y $
13.6. greater than or equal to
$ x \ge y $
13.7. equivalent to
$ F(x,f(x)) \equiv 0, x \in D $
13.8. approximately equal to
$ x \approx y $
14. Arrows
14.1. right arrow
$ x \rightarrow 0 $
14.2. not right arrow
$ x \nrightarrow 0 $
14.3. Long Equal
$ 2^{\frac 1 x} \xlongequal {y = \frac 1 x} 2^y $
15. Font
15.1. Bold
$ R \ \ \bf R $
16. Symbols and Punctuation
16.1. Infinity
$ \infty $
16.2. Dots
$ \dots $
16.3. Dot Product
$ x \sdot y $
Comments
Post a Comment