当前位置:网站首页>MD文档中插入数学公式,Typora中插入数学公式
MD文档中插入数学公式,Typora中插入数学公式
2022-07-01 08:26:00 【Gisleung】
Markdown是一种标记语言,它简直不能再简单!仅仅用一些符号,就可以排版出简洁大方的文档笔记。
所以,如何优雅的在MD文档中插入公式?(下文以Typora中插入LaTeX为例)

首先需要了解一下什么是LaTeX
然后学习如何在MD中使用它。
LaTeX数学公式
什么是LaTeX数学公式,可以查看官网:The fastest math typesetting library for the web.
我认为,它就像Typora一样,仅仅用简单的文本符号,就可以排版出复杂的数学公式,可以很方便地嵌入网页或者MD文档中。
插入内敛公式
内敛公式即直接跟在文本后面,不单独占一行。以 f ^ i k \hat f_i^k f^ik 为例(这可不是图片哦),这样一个带上下标的内敛数学公式,只需要在文档中键入:
$\hat f_i^k$
其中$$为内敛公式标识,只需要在中间填入LaTeX即可。(赶紧复制到文档里,体验一下)
插入行内公式
行内公式单独占一行,以下面的行内公式为例:
r i k = M L P ( p i ⊕ p i k ⊕ ( p i − p i k ) ⊕ ∥ p i − p i k ∥ ) r_i^k = MLP\left( { {p_i} \oplus p_i^k \oplus \left( { {p_i} - p_i^k} \right) \oplus \left\| { {p_i} - p_i^k} \right\|} \right) rik=MLP(pi⊕pik⊕(pi−pik)⊕∥∥pi−pik∥∥)
需要使用公式块(类似代码块):
$$
r_i^k = MLP\left( {
{p_i} \oplus p_i^k \oplus \left( {
{p_i} - p_i^k} \right) \oplus \left\| {
{p_i} - p_i^k} \right\|} \right)
$$
其中$$为公式块,中间填入LateX即可。(赶紧复制到文档里,体验一下)
如何快速地书写LaTeX公式
看到这里,对于如何插入公式,你或许已经明朗了。但是怎么快速的书写 LaTeX 呢?
三种方案(最后一种最傻瓜式!)
1 学习 LaTeX语法(程序员入)
其实把书写 LaTeX 理解为编写代码,完全没有问题,数学公式中任何符号,其都提供了相应的字符表达(语法)。
如何学习语法,网上应该可以搜到好多。。。
当你学会之后,可以 边写边看:
2 便捷的可视化书写
3 从MathType转换(学生党入!)
相信大家对MathType都很熟悉,打开 预置—剪切和复制预置,按照下面截图中进行设置。
然后我们正常的编写公式,完了之后,选中,Ctrl+C直接复制,在MD文档中直接Ctrl+V粘贴,既是LaTeX格式的公式了!
或许粘贴之后,你还要删除公式两端的\],对于MD文档来说\]是多余的。
边栏推荐
- What is the material of 16MnDR, the minimum service temperature of 16MnDR, and the chemical composition of 16MnDR
- XX攻击——反射型 XSS 攻击劫持用户浏览器
- Practice and Thinking on the architecture of a set of 100000 TPS im integrated message system
- TypeError: __init__() got an unexpected keyword argument ‘autocompletion‘
- P4 installation bmv2 detailed tutorial
- Airsim radar camera fusion to generate color point cloud
- MATLAB小技巧(16)矩阵特征向量特征值求解一致性验证--层次分析
- [redis] it takes you through redis installation and connection at one go
- On several key issues of digital transformation
- XX attack - reflective XSS attack hijacking user browser
猜你喜欢

Conception et mise en service du processeur - chapitre 4 tâches pratiques

《微机原理》-绪论

网关gateway-88

Share 7 books I read in the first half of 2022

MATLAB【函数和图像】

P4 installation bmv2 detailed tutorial

factory type_id::create过程解析

7-26 word length (input and output in the loop)

View drawing process analysis

15Mo3 German standard steel plate 15Mo3 chemical composition 15Mo3 mechanical property analysis of Wuyang Steel Works
随机推荐
Advanced API
Leetcode t31: next spread
Book of quantitative trading - reading notes of the man who conquers the market
C basic knowledge review (Part 4 of 4)
When using charts to display data, the time field in the database is repeated. How to display the value at this time?
如何招到适合自己店铺的淘宝主播
Leetcode T39: 组合总和
On June 30, 2022, the record of provincial competition + national competition of Bluebridge
What is the material of 16MnDR, the minimum service temperature of 16MnDR, and the chemical composition of 16MnDR
15Mo3 German standard steel plate 15Mo3 chemical composition 15Mo3 mechanical property analysis of Wuyang Steel Works
[Yu Yue education] Shandong Vocational College talking about railway reference materials
Huawei machine test questions column subscription Guide
Practice and Thinking on the architecture of a set of 100000 TPS im integrated message system
CPU设计实战-第四章实践任务一简单CPU参考设计调试
Redis publish subscription
量化交易之读书篇 - 《征服市场的人》读书笔记
Luogu p1088 [noip2004 popularization group] Martians
机动目标跟踪——当前统计模型(CS模型)扩展卡尔曼滤波/无迹卡尔曼滤波 matlab实现
Leetcode t31: prochain arrangement
[dynamic planning] p1020 missile interception (variant of the longest increasing subsequence)