Learn LaTeX in ten minutes

Table of Contents

1 Create a basic article template

\documentclass[11pt]{article}

\begin{document}
This is a simple example.
\end{document}

2 Adding a title, author and date

\title{My First \LaTeX{} Article}                                                                           
\author{Siqing Mu}
\date{2019-07-26}

这时候我们发现刚添加的信息并没有显示出来,这是怎么回事? 现在我们使用 \maketitle 将上面的信息打印到文档中。

\maketitle

3 Sections

\section{First Section}                                                                                         
This is the first section.
                                                                                                                                                                   
\subsection{First Subsection}                                                                                  
This is the first subsection. 

\subsection{Second Subsection}                                                                                  
This is the second subsection. 

\subsection{Third Subsection}                                                                                  
This is the third subsection. 
                                                                                                              
\section{Second Section}                                                                                       
This is the Second section.                                                                                                                  
        
\subsection{First Subsection}                                                                                  
This is the first subsection. 

\subsection{Second Subsection}                                                                                  
This is the second subsection. 

\subsection{Third Subsection}                                                                                  
This is the third subsection. 
                                                                                                            
\section{Third Section} 
This is the third section.

\subsection{First Subsection}                                                                                  
This is the first subsection. 

\subsection{Second Subsection}                                                                                  
This is the second subsection. 

\subsection{Third Subsection}                                                                                  
This is the third subsection. 
                   
\section*{Unnumbered Section}                                                                               
This is the unnumbered section.

注意看最后一个,通过 \section*{} 中包含星号,使得节编号禁用。

4 Adding a Table of Contents

\tableofcontents

5 Create tables

\section{table}
\begin{center}
\begin{tabular}{|c|c|c|c|c|c|}
 \hline
cell & cell & cell & cell & cell & cell \\
 \hline
cell & cell & cell & cell & cell & cell \\
 \hline
cell & cell & cell & cell & cell & cell\\
 \hline
\end{tabular}
\end{center}

6 Support Chinese Typeset

\usepackage{ctex}
\usepackage{xeCJK}

7 Bold, italics and underlining

Some of the \textbf{greatest}
discoveries in \underline{science} 
were made by \textbf{\textit{accident}}.

8 Create lists

8.1 unordered lists

\begin{itemize}
  \item The individual entries are indicated with a black dot, a so-called bullet.
  \item The text in the entries may be of any length.
\end{itemize}

8.2 ordered lists

\begin{enumerate}
  \item This is the first entry in our list
  \item The list numbers increase with each entry we add
\end{enumerate}

9 Adding images

指定包和图片路径

\usepackage{graphicx}
\graphicspath{ {Pictures/} }

引入图片及设置宽高并保证纵横比,或根据比例缩放

\includegraphics[width=6cm,height=3cm,keepaspectratio]{image.jpg}
\includegraphics[width=\textwidth]{image.jpg}
\includegraphics[scale=0.25]{image.jpg}

也可以用如下形式引入图片

\begin{figure}
\centering
\includegraphics[width=8cm]{Plot}
\caption{My amazing figure}
\end{figure}

10 Source Download

11 Getting Tex and LaTex

12 Reference