Ubuntu 23.10安装TeXlive并安装CTEX中文支持

连接上互联网,打开SHELL命令行界面,

  1. sudo apt install texlive texstudio texlive-lang-chinese

就可以安装好了。texlive-lang-chinese 是TEXLIVE对CTEX中文的支持。

  1. Tex源文件必须采用UTF-8编码格式,编译器采用xelatex。这样对中文的pdf文件更好。

  2. 在SHELL命令行敲击命令时,如果实在想不起命令的拼写,按下TAB键就会有可选的命令提示。即可找到所需的命令。

  3. 源代码的编辑器推荐使用 texstudio,但是也可以使用 texworks。texworks最简单,而且随便一个TeX发行版都包含texworks。但是texstudio更加专业。

  4. 第一个tex源代码

|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| |
| \documentclassa4paper,UTF8,12pt,oneside,openany{book} \usepackagespace{ctex} \newcommand{\myauthor }{Donald E. Knuth} \newcommand{\myfont }1{\heiti #1} \newcommand{\mycmdA }2{ #1_1,#1_2,\\dots,#1_#2 } \newcommand{\mycmdB }2n{ #2_1,#2_2,\\dots,#2_#1 } \newcommand{\A}1{\bfseries #1} \newcommand*{\B}1{\bfseries #1} \newcommand{\lvec }{} \newcommand{\DEFlvec }2{\renewcommand{\lvec }1#2{\ensuremath{#1_1+\cdots+#1_{##1}}}} \DEFlvec{x}{n} \newcommand{\CC }{ \\Gamma_{i} } \newcommand{\CD }{\ensuremath{\Gamma_{i}}} \begin{document} 你好,\LaTeX{} ! \par \LaTeX3{} 是一个长远而艰巨的奋斗目标,在它最终完成之前,\LaTeXe{} 将是标准的\LaTeX\ 版本。 \par In 1971, \myauthor was the recipient of the first ACM Grace Murray Hopper Award. \par 方程有两种:\myfont{恒等式} 和 \myfont{条件等式} 。 \par 我们经常把数列写作: \mycmdA{x}{n},或者写作: \mycmdA{a}{m}。 \par 我把数列写作: \mycmdB{x},或者写作: \mycmdBm{a}。 \par \A{Cosmic Mystery \par Harmony of the World} \par \B{Cosmic Mystery Harmony of the World} \par Default, \\lvec \\neq \\lvec\[k\] \par \DEFlvec{y}{i} Now, \\lvec \\neq \\lvec\[k\] \par Let \CC{} be the number of gnats per cubic meter, where \CC\ is normalized with respect to \\nu(s) 。 \par Let \CD be the number of gnats per cubic meter, where e\^{\\CD }=\\nu(s) . \end{document} |

相关推荐
96245637 分钟前
一次 Dell PowerEdge R750xs 启动故障复盘:从 iDRAC 带外管理到 Linux 多内核回退与 initramfs 重建
linux·运维·服务器
Zevalin爱灰灰1 小时前
Linux入门第一部分(Ubuntu入门篇) 第二章 浅尝Ubuntu(二)
linux·嵌入式·1024程序员节
北京中科新远科技2 小时前
高速接口兼容排查实战:OSFP、QSFP112与QSFP56如何逐层验证
linux·运维·网络
Ruiery2 小时前
Linux 6.6内核 CPU 深度解析(零):x86 内核引导协议 — 从 bootloader 到 main()
linux·运维·服务器
Ruiery2 小时前
Linux 6.6内核 CPU 深度解析(十六):x86 保护机制 — 从 ring 到页表的权限防线
linux·运维·服务器
qetfw2 小时前
Linux 文件清理:find、mtime 与安全传参验证
linux·shell·1024程序员节
可乐_不渴3 小时前
【Linux】 项目自动化构建工具makefile&& 版本管理Git&&第一个程序
linux·git·自动化·1024程序员节
西安同步电子4 小时前
时统卡驱动踩坑:Windows 和 Linux 下时间同步的底层差异
linux·stm32·单片机
虚无的纽扣4 小时前
【Linux】线程互斥:多线程改同一个变量,到底会出什么问题
linux·服务器·1024程序员节
qetfw4 小时前
Bash 函数与流程控制:read、if、for、case 验证
linux·前端·javascript·bash