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源代码

|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| |
| \documentclass[a4paper,UTF8,12pt,oneside,openany]{book} \usepackage[space]{ctex} \newcommand{\myauthor }{Donald E. Knuth} \newcommand{\myfont }[1]{\heiti #1} \newcommand{\mycmdA }[2]{ #1_1,#1_2,\\dots,#1_#2 } \newcommand{\mycmdB }[2][n]{ #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},或者写作: \mycmdB[m]{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} |

相关推荐
时间裂缝里的猫-O-5 分钟前
@Linux问题 :bash fork Cannot allocate memory 错误分析与解决方案
linux·chrome·bash
躺不平的小刘18 分钟前
从YOLOv5到RKNN:零冲突转换YOLOv5模型至RK3588 NPU全指南
linux·python·嵌入式硬件·yolo·conda·pyqt·pip
愚昧之山绝望之谷开悟之坡31 分钟前
| `cat /etc/os-release` | 发行版详细信息(如 Ubuntu、CentOS) |
linux·ubuntu·centos
明天见~~2 小时前
Linux下的网络编程
linux·运维·网络
NEXU52 小时前
Linux:网络层IP协议
linux·网络·tcp/ip
Aczone282 小时前
Linux 软件编程(九)网络编程:IP、端口与 UDP 套接字
linux·网络·网络协议·tcp/ip·http·c#
倔强的石头_2 小时前
【Linux指南】Makefile入门:从概念到基础语法
linux
Code_Dragon2 小时前
最近遇到的bug
linux·前端
risc-v@cn2 小时前
【在ubuntu下使用vscode打开c++的make项目及编译调试】
c++·vscode·ubuntu
武文斌772 小时前
计算机网络:网络基础、TCP编程
linux·网络·网络协议·tcp/ip·计算机网络