Latex + IEEEtran模板 + 样例 + 数学符号表
用Latex写一篇IEEEtran模板的文章,根据师兄楚楚可薇的文章记录一些事宜,便于日后查看,如有总结错误的地方,欢迎指正。
【2022.9.22 追加前言】
根据第7部分中的样例全文基本可以学会使用该博客讲到的知识点,但标题中带有(更)
的部分建议再看一眼,里面有后续遇到的问题的注意事项,第8部分为写论文时特殊符号写法的索引,第9部分为后续补充。文献引用bib格式转bibitem格式移步VS CODE + Latex。
1. 引用包
\documentclass[conference,a4paper]{
IEEEtran} %导入IEEEtran的A4格式模板
\usepackage[inner=0.9055in,outer=0.5118in,top=0.5in]{
geometry} %左边距inner,右边距outer,上边距top
\usepackage{
amsmath} %数学公式包
\allowdisplaybreaks[3] %导入数学公式包的前提下,允许跨页,1,2,3,4表示允许程度,但equation环境不可换页
%长公式跨页可用align公式
\usepackage{
bbm} %粗体、双线体
\usepackage{
multirow} %纵向合并单元格
\usepackage{
booktabs} %三线表
\usepackage{
color}
\usepackage{
amssymb} %数学定理和证明过程包
\let\labelindent\relax
\usepackage{
enumitem} %调整垂直/水平间距/标签样式
\usepackage{
amsthm} %定理环境
\newtheorem{
ownlemma}{
Lemma} %引理。定理将两个lemma改为theorem 即可
\newtheorem{
owncorollary}{
Corollary} %推论
\newtheorem{
owndefinition}{
Definition} %定义
\newtheorem{
ownproperty}{
Property} %性质
\usepackage{
algorithm} %代码环境
\usepackage[noend]{
algpseudocode} %伪代码中 类似 if...end if去掉end if语句
\renewcommand{
\algorithmicrequire}{
Input:}
\renewcommand{
\algorithmicensure}{
Output:}
\renewcommand{
\algorithmiccomment}[1]{
// #1} %C语言的注释格式
\bibliographystyle{
IEEEtran} %引用文献格式
\usepackage[numbers, sort & compress]{
natbib} %压缩引用序号
\usepackage{
soul} %高亮显示,为提高本文可读性而添加,实际论文不需要该包
2. 文章开始,标题,作者
Latex中,begin和end成对出现。
注意此处的.bib文件需导入所有文章使用到的全部参考文献,写法见VS CODE + Latex第二部分仅使用Latex。下方代码的文件名需与之对应,且存放于同一文件目录下
。
\begin{
document} %文章开头第一句
... %文章内容全部位于该位置
\bibliography{
NameofReference} %参考文献.bib文件名
\end{
document} %文章结尾最后一句
标题
\titile{
Title of the Paper}
作者
\author{
My_name$^\S$,MyTheacher$^\S{
}^{
*}$\\
$^\S$NameofCollege, NameofSchool\\
}
\maketitle
样例:其中 \\
表示换行,空一行表示分段
\begin{
document}
\title{
This is a Sample}
\author{
Qiuqiu Qiu$^\S$,San Zhang$^\S{
}^{
*}$\\
$^\S$School of Electrical Engineering \& Intelligentization, University\\
}
\maketitle
\end{
document}
3. 引用
所引文献需在 bib 文件中,引用时,若位于句末,则序号在逗号或句号前面;若引用其他文章的定理/引理/推论
,例如 \cite[lemma 1]{Name} 表示引用文章Name的Lemma1.
3.1 文献:
例如:
bib中有文章:
@article{
blaum1993new,
title={
{
New Array Codes for Multiple Phased Burst Correction}},
author={
Blaum, Mario and Roth, Ron M},
journal={
IEEE Transactions on Information Theory},
volume={
39},
number={
1},
pages={
66--77},
year={
1993},
publisher={
IEEE}
}
引用时:
...decoding method \cite{
blaum1993new}. %括号里为文章别名。
3.2 脚注:
\foodnote{
content of foodnote}
同一页面最下方有如下显示:
4. 摘要及关键词
摘要
\begin{
abstract}
Here is the abstract of this paper.
...
\end{
abstract}
关键词:逗号隔开关键字,最后一个关键词后加句号。
\begin{
IEEEkeywords}
keyword1, keyword2, ..., last keyword.
\end{
IEEEkeywords}
5. 正文部分
The main body of the paper :
\section{
section 1}
Here is the section 1,usually an introduction.
The second paragraph of this section.\\ %空一行表示分段,\\表示换行
The third paragraph of this section.
\section{
section 2}
Here is the section 2.
\subsection{
subsection 1}
Here is the subsection 1 of section 2.
\subsection{
subsection 2}
Here is the subsection 2 of section 2.\\
...
\section{
section 3}
Here is the section 3.
\subsection{
subsection 1}
Here is the subsection 1 of section 3.
\subsection{
subsection 2}
Here is the subsection 2 of section 3.\\
...
\section{
section 4}
Here is the section 4.
\section{
last section}
Here is the last section,usually an conclusion.
6. 公式
公式、变量等两端用&
夹起来。
例如:
$p$, $\mathcal{
C}(p,n,r)$, $\mathbb{
F}_2[x]/M_p(x)$\\ %注意此处的 F
$M_p(x)=1+x+\cdots+x^{
p-1} \:(\bmod\: 1+x^p)$\\ %居中的点,_下标,^上标
$N_p(x)=1+x+\ldots+x^{
p-1}$\\ %靠下的点
$[c_{
i,j}]_{
i=0,j=0}^{
p-2,n-1},c_[i,j]\in \mathbb{
F}_2,n\leq p$\\ % \in 属于,\leq 小于等于
$c_j(x) = \sum\nolimits_{
i=0}^{
p-2}c_{
i,j}x^i$
(i.e., $c_0(x) = c_{
0,0} + c_{
1,0}x + c_{
2,0}x^2+ \ldots + c_{
n-2,0}x^{
n-2}$)\\
6.1 矩阵(更)
2022.09.22更
在编写 “A Matrix” 矩阵时,注意到右下角的一块矩阵使用的是 smallmatrix
,这是因为在双栏模板中,如果矩阵较大时使用 bmatrix 会导致部分矩阵超出排版位置,甚至与另一栏中的文字重叠,矩阵没有那么大的时候,右下方的矩阵也用bmatrix
即可。
\textbf{
Matrix multiplication:}
\[
\mathbf{
H}_{
r \times n} \cdot % 注意区分 \cdot 和 \cdots
\begin{
bmatrix}
c_0(x) & c_1(x) & \cdots & c_{
n-1}