LaTeX学习之路 照着葫芦画瓢公式大全



早晚要学,不如现在学,况且目前比较感兴趣。学会了也能在博客写写机器学习的公式了,挖个坑先!明天开始肝。



上下标and空格:

f 1 ( x ) = x 2 f 1 ′ ( x ) = 2 x f 1 ( 2 ) ( x ) = 2 f_1(x) = x^2 \quad \quad f_{1}'(x)= 2x \quad \quad f ^{(2)} _1 (x) = 2 f1(x)=x2f1(x)=2xf1(2)(x)=2

$$
f(x) = x^2 \quad \quad
f'(x)= 2x \quad \quad
f^{(2)}(x) = 4
$$

\quad 表示一个汉字距离的空格
只要不用\ 公式内可以随便写空格 不会产生影响

_{下标数}
^{上标数}
花括号可加可不加 加上比较美观好看

照着葫芦画瓢公式:

f 下 标 上 标 ( x ) = ? f ^{上标} _{下标} (x) = ? f(x)=?

$$
f ^{上标} _{下标} (x) = ?
$$




分数式:

x = a 0 + 1 a 1 + 1 a 2 + 1 a 3 + 1 a 4 x = a_0 + \cfrac{1} {a_1+ \cfrac{1} {a_2+ \cfrac{1} {a_3 + \cfrac{1} {a_4} } } } x=a0+a1+a2+a3+a41111

$$
x = a_0 + \cfrac{1}
				{a_1+ \cfrac{1}
						{a_2+ \cfrac{1}
								{a_3 + \cfrac{1}
										{a_4} } } }
$$

有点复杂?来看个简单的。
x = a 0 + 1 a 1 + a 2 x = a_0 + \cfrac{1}{a_1+a_2} x=a0+a1+a21

$$
x = a_0 + \cfrac{1}{a_1+a_2}
$$

照着葫芦画瓢公式:

x = a 0 + 分 子 分 母 x = a_0+\cfrac{分子}{分母} x=a0+

$$
x = a_0+\cfrac{分子}{分母}
$$




根式:

y = x 1 2 + x 2 2 + x 3 2 + x 4 2 3 y = \sqrt [3]{x_1^2 + x_2^2 + x_3^2 + x_4^2} y=3x12+x22+x32+x42

$$
y = \sqrt [3]{x_1^2 + x_2^2 + x_3^2 + x_4^2}
$$




积分公式:

∫ 0 ∞ \int_{0}^{\infty} 0

$$
\int_{0}^{\infty}
$$

{ }就是为了方便好看美观

/int就是积分符号
∫ 0 π 2 sin ⁡ ( x ) d x \int_{0}^{\frac{\pi}{2}}\sin(x)\mathrm{dx} 02πsin(x)dx

$$
\int_{0}^{\frac{\pi}{2}}\sin(x)\mathrm{dx}
$$

∫ 0 π 2 s i n ( x )   d x \int_{0}^{\frac{\pi}{2}}{sin(x)}\,{dx} 02πsin(x)dx

$$
\int_{0}^{\frac{\pi}{2}}{sin(x)}{dx}
$$

\,空格
\mathrm{dx} 可以直接写dx
它可以将括号内的字母由数学斜体变为正体,即罗马体。

\sin(x) 其实可以直接写sin(x)

尽管显示上来看好像没什么问题 推荐还是用前者吧

照着葫芦画瓢公式:

∫ 下 限 上 限 被 积 函 数 d x \int_{下限}^{上限}{被积函数}\mathrm{dx} dx

$$
\int_{下限}^{上限}{被积函数}\mathrm{dx}
$$




求和公式:

∑ i = 1 n \sum_{i=1}^{n} i=1n

$$
\sum_{i=1}^{n}
$$




极限:

lim ⁡ x → 0 sin ⁡ ( x ) x = 1 \lim_{x\rightarrow0} \frac{\sin(x)}{x} = 1 x0limxsin(x)=1

$$
\lim_{x\rightarrow0} \frac{\sin(x)}{x} = 1
$$

\rightarrow 向右指向的箭头→





在复数域上伽玛函数定义为:

Γ ( z ) = ∫ 0 ∞ t z − 1 e − t d t \Gamma(z) = \int_0 ^\infty t^{z-1}e^{-t}dt Γ(z)=0tz1etdt

语法符号展示
\Alpha \Beta \Gamma \Delta \Epsilon \Zeta \Eta \Theta A B Γ Δ E Z H Θ \Alpha \Beta \Gamma \Delta \Epsilon \Zeta \Eta \Theta ABΓΔEZHΘ
\Iota \Kappa \Lambda \Mu \Nu \Xi \Omicron \Pi I K Λ M N Ξ O Π \Iota \Kappa \Lambda \Mu \Nu \Xi \Omicron \Pi IKΛMNΞOΠ
\Rho \Sigma \Tau \Upsilon \Phi \Chi \Psi \Omega P Σ T Υ Φ X Ψ Ω \Rho \Sigma \Tau \Upsilon \Phi \Chi \Psi\Omega PΣTΥΦXΨΩ
\alpha \beta \gamma \delta \epsilon \zeta \eta \theta α β γ δ ϵ ζ η θ \alpha \beta \gamma \delta \epsilon \zeta \eta \theta αβγδϵζηθ
\iota \kappa\varkappa \lambda \mu \nu \xi \omicron \pi ι κ ϰ λ μ ν ξ ο π \iota \kappa\varkappa \lambda \mu \nu \xi \omicron \pi ικϰλμνξοπ
\rho \sigma \tau \upsilon \phi \chi \psi \omega ρ σ τ υ ϕ χ ψ ω \rho \sigma \tau \upsilon \phi \chi \psi\omega ρστυϕχψω

行列式&矩阵:

[ 1 2 3 4 5 6 6 7 8 ] \left[ \begin {matrix} 1 & 2 &3\\4 & 5 & 6\\6 & 7 & 8\end{matrix} \right] 146257368

$$
\left[
\begin {matrix} 1 & 2 &3\\4 & 5 & 6\\6 & 7 & 8\end{matrix}
\right]
$$

( 1 2 3 4 5 6 6 7 8 ) \left( \begin {matrix} 1 & 2 &3\\4 & 5 & 6\\6 & 7 & 8\end{matrix} \right) 146257368

$$
\left(
\begin {matrix} 1 & 2 &3\\4 & 5 & 6\\6 & 7 & 8\end{matrix}
\right)
$$

\为换行
&用于对齐
\left( 和 \right) 要成对出现

[ 1 0 ⋯ 0 0 1 ⋯ 0 ⋮ ⋮ ⋱ ⋮ 0 0 ⋯ 1 ] \begin{bmatrix} 1&0&\cdots&0\\ 0&1&\cdots&0\\ \vdots&\vdots&\ddots&\vdots\\ 0&0&\cdots&1 \end{bmatrix} 100010001

$$
\begin{bmatrix}
1&0&\cdots&0\\
0&1&\cdots&0\\
\vdots&\vdots&\ddots&\vdots\\
0&0&\cdots&1
\end{bmatrix}
$$

[ ]也可以写成bmatrix
( )可以写成pmatrix
\cdots横着三个点
\vdots竖着三个点
\ddots斜着三个点

  • 3
    点赞
  • 3
    收藏
    觉得还不错? 一键收藏
  • 2
    评论
以下是三个关于Latex绘制三线表的代码示例: 引用\[1\]中的代码示例: \documentclass{article} \usepackage{booktabs} \usepackage{multirow} \usepackage{tabularx} \begin{table} \centering \caption{A Simple Example Table} \label{table_example} \begin{tabular}{cc} \toprule \multicolumn{1}{m{1.5cm}}{\centering Symbol} & \multicolumn{1}{m{6cm}}{\centering Definition}\\ \midrule 1111 & 11111\\ 2222 & 2222\\ \bottomrule \end{tabular} \end{table} 引用\[2\]中的代码示例: \documentclass\[UTF8\]{ctexart} \usepackage{makecell} \usepackage{geometry} \geometry{a4paper,left=1cm,right=1cm,top=2cm,bottom=1cm} \begin{document} \begin{center} \begin{table}\[t\] \centering \begin{tabular}{ccccc} \Xhline{1.5 pt} Breakfasd & Lunch & Dinner & Snack & Drink \\ \Xhline{0.5 pt} Milk & Beef & Yogurt & Chocolate & Coffee \\ Bread & Potato & Lettuce & Cookie & Chocolate milk\\ \Xhline{1.5 pt} \end{tabular} \caption{Paddington's favourite food} \end{table} \end{center} \end{document} 引用\[3\]中的代码示例: \begin{table}\[!htbp\] \centering \begin{tabular}{ccccccccccc} \toprule \multicolumn{3}{c}{\multirow{2}{*}{Method}}& \multicolumn{3}{c}{Homographic}& &\multicolumn{3}{c}{Hetergraphic}\\ \multicolumn{3}{c}{}&Precision&Recall&F1&&Precision&Recall&F1&\\ \hline \multicolumn{3}{c}{A}& 50& 0& 100&&200& 300& 300\\ \multicolumn{3}{c}{B}&100&100&0&&100&200&200\\ \multicolumn{3}{c}{C}&150&200&100&&0&100&200\\ \bottomrule \end{tabular} \caption{亲,能点赞+关注吗,(\^\_−)☆} \end{table} 以上是三个不同的Latex代码示例,用于绘制三线表。你可以根据自己的需求选择其中一个进行使用。 #### 引用[.reference_title] - *1* [Latex三线表代码](https://blog.csdn.net/qq_42635142/article/details/105019104)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v91^insertT0,239^v3^insert_chatgpt"}} ] [.reference_item] - *2* [Latex绘制三线表](https://blog.csdn.net/Paddington7/article/details/126432179)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v91^insertT0,239^v3^insert_chatgpt"}} ] [.reference_item] - *3* [使用latex做三线表](https://blog.csdn.net/liu16659/article/details/111656244)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v91^insertT0,239^v3^insert_chatgpt"}} ] [.reference_item] [ .reference_list ]

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 2
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值