latex入门

Latex简单实用方法

  • 安装Texstudio

  • 快捷键

    F5 运行

    ctrl T 注释

    ctrl U 去注释

  • LaTex基本用法

    命令以\开头

    中文article \documentclass[UTF8]{ctexart}

    注释 %

    脚注 文字中插入 \footnote{脚注内容}

    空格分行 多个空行不增大段落距离

    自动完成段前缩进

  • 数学公式

    三角 \angle

    角度(小圆圈) \circ

    Π \pi

    引入上标 ^ 2的十次方:2^{10}

    引入下表 _

  • 图片

    插入图片使用graphicx宏包

    导入包 \usepackage{graphicx}

    文字环绕插入图片 \includegraphicx[width=3cm]{xxx.jpg}

    图片浮动

    • 设置浮动环境插入图片

      \begin{figure}[ht]
      
      \centering
      
      \includegraphics[width=6cm]{image.jpg}
      
      \caption{图片标题}
      
      \label{fig:图片标签}
      
      \end{figure}
      
  • 表格

    img

    img

    其中|rrr|表示表格有三列且右对齐

    行与行之间用命令\\隔开

    内部表项用 & 隔开

    表格中横线用\hline产生

  • 无序号脚注

    \renewcommand{\thefootnote}{}
    \footnotetext

  • 插入文件代码

    \VerbatimInput{//文件名}

  • 一些测试

    \documentclass[UTF8]{ctexart}
    \begin{document}
    	你好, world!
    \end{document}
    
    \documentclass[UTF8]{ctexart}
    \title{你好,world!}
    \author{Liam}
    \date{\today}
    \begin{document}
    	\maketitle
    	\section{你好中国}
    	中国在 East Asia.
    	\subsection{Hello Beijing}
    	北京是 capital of China.
    	\subsubsection{Hello Dongcheng District}
    	\paragraph{Tian'anmen Square}
    	is in the center of Beijing
    	\subparagraph{Chairman Mao}
    	is in the center of 天安门广场。
    	\subsection{Hello 北京}
    	\paragraph{北京} is an international city。
    \end{document}
    
  • Latex模板网站

posted @ 2021-07-21 16:38  buchiyexiao  阅读(193)  评论(0)    收藏  举报
Live2D