如何c语言编译数学公式,[实用] 简书中如何编辑Latex数学公式

Tags: LaTex MathJax

简书Markdown暂时不能直接支持使用$$标签来显示Latex语法,可以在 https://www.zybuluo.com/hzw/note/80162 (作业部落 Markdown)查看使用"$$"标签显示Latex公式效果,其直接支持MathJax,脚注,目录,Tags等语法。

注:简书要想显示数学公式,可以按如下操作,使用Latex在线生成然后插入的方式。

编辑源码

对于简易公式,可以使用如下方式一:

![](http://latex.codecogs.com/png.latex?C_n^k=\frac{n(n-1)\ldots(n-k+1)}{k!})

如果上述方式有问题,或者公式相对较复杂,请使用下述标签方式二(推荐):

![][01]

[01]:http://latex.codecogs.com/png.latex?C_n^k=\frac{n(n-1)\ldots(n-k+1)}{k!}

注:[01]代表一个标签链接,可以根据需要改变数字即可。这里用到了Latex一个在线公式png生成的API,只要将自己写的Latex公式,比如C_n^k=\frac{n(n-1)\ldots(n-k+1)}{k!}放在http://latex.codecogs.com/png.latex?后面,在浏览器中打开,就可以生成对应png链接,然后将其加入到简书中就行了,此方式比截图的方式显示要友好多了。

上述示例显示结果如下:

5829cef704e935220c2e58a69ab0460e.png

公式示例

常见公式:

(1) ![](http://latex.codecogs.com/png.latex?\int_a^b(a_x)dx ~~ =\sum_{i=0}^nA_if(x_i))

(2)

b8e05a2f50d5bc17589eb8ede796a4a8.png

(3) ![](http://latex.codecogs.com/png.latex?\lim_{x\rightarrow\infty} f(x))

(4) ![](http://latex.codecogs.com/png.latex?\widetilde{abc} = \widehat{abc})

(5)

a10e5613e0b5f91d3e1133efea5f28d0.png

(6)

31855c6d55435d20e6b723cdfc919474.png

(7) ![](http://latex.codecogs.com/png.latex?f_x = \frac{\partial f(x,y)}{\partial x})

(8) ![](http://latex.codecogs.com/png.latex?\sum_{k=1}^\infty \frac{x^n}{n!} =\int_0 ^\infty e^x)

(9)

png.latex?%5Cunderbrace%7Ba+%5Coverbrace%7Bb+%5Cdots+b%7D%5E%7Bm%E4%B8%AA%7D+c%7D_%7B20%5Cmbox%7B%E4%B8%AA%7D%7D

(10) ![](http://latex.codecogs.com/png.latex?\vec{x}\stackrel{\mathrm{def}}{=}{x_1,\dots,x_n}\

{n+1 \choose k}={n \choose k}+{n \choose k-1}\

\sum_{k_0,k_1,\ldots>0 \atop k_0+k_1+\cdots=n}A_{k_0}A_{k_1}\cdots)

@普通Latex公式源码:

(1) $$ \int_a^b(a_x)dx ~~ =\sum_{i=0}^nA_if(x_i) $$

(2) $$ \sum_{a=1}^nf(\overline{x}) $$

(3) $$ \lim_{x\rightarrow\infty} f(x) $$

(4) $$ \widetilde{abc} = \widehat{abc} $$

(5) $$ x_0+\frac{1}{x_1+\frac{1}{x_2+\frac{1}{x_3+\frac{1}{x_4}}}} $$

(6) $$ \sqrt{1+\sqrt[p]{1+\sqrt[q]{1+a}}} $$

(7) $$ f_x = \frac{\partial f(x,y)}{\partial x} $$

(8) $$ \sum_{k=1}^\infty \frac{x^n}{n!} =\int_0 ^\infty e^x $$

(9) $$ \underbrace{a+\overbrace{b+\dots+b}^{m个}+c}_{20\mbox{个}} $$

(10)

$$

\vec{x}\stackrel{\mathrm{def}}{=}{x_1,\dots,x_n}\\

{n+1 \choose k}={n \choose k}+{n \choose k-1}\\

\sum_{k_0,k_1,\ldots>0 \atop k_0+k_1+\cdots=n}A_{k_0}A_{k_1}\cdots

$$

@简书显示该Latex公式源码(这里只列出方式一):

(1) ![](http://latex.codecogs.com/png.latex?\int_a^b(a_x)dx ~~ =\sum_{i=0}^nA_if(x_i))

(2) ![](http://latex.codecogs.com/png.latex?\sum_{a=1}^nf(\overline{x}))

(3) ![](http://latex.codecogs.com/png.latex?\lim_{x\rightarrow\infty} f(x))

(4) ![](http://latex.codecogs.com/png.latex?\widetilde{abc} = \widehat{abc})

(5) ![](http://latex.codecogs.com/png.latex?x_0+\frac{1}{x_1+\frac{1}{x_2+\frac{1}{x_3+\frac{1}{x_4}}}})

(6) ![](http://latex.codecogs.com/png.latex?\sqrt{1+\sqrt[p]{1+\sqrt[q]{1+a}}})

(7) ![](http://latex.codecogs.com/png.latex?f_x = \frac{\partial f(x,y)}{\partial x})

(8) ![](http://latex.codecogs.com/png.latex?\sum_{k=1}^\infty \frac{x^n}{n!} =\int_0 ^\infty e^x)

(9) ![](http://latex.codecogs.com/png.latex?\underbrace{a+\overbrace{b+\dots+b}^{m个}+c}_{20\mbox{个}})

(10) ![](http://latex.codecogs.com/png.latex?\vec{x}\stackrel{\mathrm{def}}{=}{x_1,\dots,x_n}\\

{n+1 \choose k}={n \choose k}+{n \choose k-1}\\

\sum_{k_0,k_1,\ldots>0 \atop k_0+k_1+\cdots=n}A_{k_0}A_{k_1}\cdots)

(注:感谢您的阅读,希望本文对您有所帮助。如果觉得不错欢迎分享转载,但请先点击 这里 获取授权。本文由 版权印 提供保护,禁止任何形式的未授权违规转载,谢谢!)