elsarticle.cls 要用到的一些包

  • natbib.sty 处理引用 for citation processing,处理各种各样的引用,和 hyperref.sty,hypernat.sty 一起完美工作
  • geometry.sty 页边距设置 for margin settings
  • fleqn.clo 左对齐公式 for left aligned equations
  • txfonts.sty 其他字体,可选的包
    optional font package, if the document is to be formatted with Times and compatible math fonts
  • hyperref.sty 如果文章要使用超链接,则需要这个包
    optional packages if hyperlinking is required in the document
  • endfloat.sty 把所有 floats(图, 表等)放在文末则需要用
    optional packages if floats to be placed at end of the PDF.
  • ams 的数学包比如 amsmath.sty, amsthm.sty, amssymb.sty, amsfonts.sty 都是免费随便用的
  • graphicx.sty, is part of any standard LATEX distribution, is loaded by default.
  • multirow.sty, array.sty 做表格的,进一步增强和调整表格,需要自己 load(\usepackage{})
关于图像格式:
LATEX accepts figures in the postscript format ,比如 eps
while pdfLATEX accepts .pdf, .mps (metapost), .jpg and .png formats. pdfLATEX does not accept graphic files in the postscript format.

elsarticle.cls is built upon article.cls,All options of article.cls can be used with this document class.

TEX needs two compilations to resolve the footnote marks in the preamble part

好神奇!!!竟然需要编译两次,亲自尝试,如果只编译一次,email address 和 url 就不出来,这就是因为脚注还没解析好,牛逼

用 elsarticle.ins 生成 elsarticle.cls

elsarticle.ins is the LATEX installer file 安装文件,用 latex 编译它就可以得到 cls 文件(类文件,class 文件)
先打开 elsarticle 所在路径,然后调用 latex 命令

latex elsarticle.ins
*************************************************************
*                                                           *
* To finish the installation you have to move the following *
* file into a directory searched by TeX:                    *
*                                                           *
*     elsarticle.cls                                        *
*         and                                               *
*     elsarticle-*.bst                                      *
*                                                           *
* To produce the documentation go to the ../contrib folder  *
* and run the file elsdoc.tex through pdfLaTeX              *
* or use the Makefile which is far more easier.             *
*                                                           *
* Happy TeXing!                                             *
*                                                           *
*************************************************************

然后把生成的 cls 文件复制到 D:\texlive\texmf-local\tex\latex\elsevier 路径,也可以放在别的 latex 编译时可以搜索到的路径下
然后更新 latex 的文件数据库,用 texlive 发行版 texhash 命令,miktex 发行版好像是用 mktexlsr

E:\2nd paper\投稿期刊模板\information fusion\elsarticle\elsarticle>texhash
texhash: Updating D:/texlive/texmf-local/ls-R...
texhash: Updated D:/texlive/texmf-local/ls-R.
texhash: Updating D:/texlive/2019/texmf-config/ls-R...
texhash: Updated D:/texlive/2019/texmf-config/ls-R.
texhash: Updating D:/texlive/2019/texmf-var/ls-R...
texhash: Updated D:/texlive/2019/texmf-var/ls-R.
texhash: Updating D:/texlive/2019/texmf-dist/ls-R...
texhash: Updated D:/texlive/2019/texmf-dist/ls-R.
texhash: Done.

E:\2nd paper\投稿期刊模板\information fusion\elsarticle\elsarticle>

frontmatter(title,author,abstract,keyword)

作者们写在一起,机构用脚注表示

each author is connected to an affiliation with a footnote marker; hence all authors are grouped together and affiliations follow;

%% 下面是所有作者一起写的格式
\title{This is a specimen title\tnoteref{t1,t2}}
\tnotetext[t1]{This document is the results of the research
    project funded by the National Science Foundation.}
\tnotetext[t2]{The second title footnote which is a longer
    text matter to fill through the whole text width and
    overflow into another line in the footnotes area of the
    first page.}
\author[1]{Jos Migchielsen\corref{cor1}%
    \fnref{fn1}}
\ead{[email protected]}
\author[2]{CV Radhakrishnan\fnref{fn2}}
\ead{[email protected]}
\author[3]{CV Rajagopal\fnref{fn1,fn3}}
\ead[url]{www.stmdocs.in}
\cortext[cor1]{Corresponding author}
\fntext[fn1]{This is the first author footnote.}
\fntext[fn2]{Another author footnote, this is a very long
    footnote and it should be a really long footnote. But this
    footnote is not yet sufficiently long enough to make two
    lines of footnote text.}
\fntext[fn3]{Yet another author footnote.}
\address[1]{Elsevier B.V., Radarweg 29, 1043 NX Amsterdam,
    The Netherlands}
\address[2]{Sayahna Foundations, JWRA 34, Jagathy,
    Trivandrum 695014, India}
\address[3]{STM Document Engineering Pvt Ltd., Mepukada,
    Malayinkil, Trivandrum 695571, India}

效果

同一个机构的作者写在一起,相关机构跟在后面

authors of same affiliations are grouped together and the relevant affiliation follows this group

%% 下面是不同机构作者分开写的格式
\title{This is a specimen title\tnoteref{t1,t2}}
\tnotetext[t1]{This document is the results of the research
    project funded by the National Science Foundation.}
\tnotetext[t2]{The second title footnote which is a longer
    text matter to fill through the whole text width and
    overflow into another line in the footnotes area of the
    first page.}
\author{Jos Migchielsen\corref{cor1}%
    \fnref{fn1}}
\ead{[email protected]}
\address{Elsevier B.V., Radarweg 29, 1043 NX Amsterdam,
    The Netherlands}
\author{CV Radhakrishnan\fnref{fn2}}
\ead{[email protected]}
\address{Sayahna Foundations, JWRA 34, Jagathy,
    Trivandrum 695014, India}
\author{CV Rajagopal\fnref{fn1,fn3}}
\ead[url]{www.stmdocs.in}
\address{STM Document Engineering Pvt Ltd., Mepukada,
    Malayinkil, Trivandrum 695571, India}
\cortext[cor1]{Corresponding author}
\fntext[fn1]{This is the first author footnote.}
\fntext[fn2]{Another author footnote, this is a very long
    footnote and it should be a really long footnote. But this
    footnote is not yet sufficiently long enough to make two lines
    of footnote text.}
\fntext[fn3]{Yet another author footnote.}

效果

doubleblind 选项

不显示作者和机构和邮箱信息
To hide author name, affiliation, email address etc. for double blind refereeing purpose.

\documentclass[preprint,12pt,doubleblind]{elsarticle}
%\newpageafter{title}%标题后新起一页
%\newpageafter{author}
%\newpageafter{abstract}

用 enumerate 改变列表 list 的计数器 counter 和属性

\begin{enumerate}[1.]
    \item The enumerate environment starts with an optional
    argument ‘1.’, so that the item counter will be suffixed
    by a period.
    \item You can use ‘a)’ for alphabetical counter and ’(i)’ for
    roman counter.
    \begin{enumerate}[a)]
        \item Another level of list with alphabetical counter.
        \item One more item before we start another.
        \begin{enumerate}[(i)]
            \item This item has roman numeral counter.
            \item Another one before we close the third level.
            \end{enumerate}
        \item Third item in second level.
    \end{enumerate}
    \item All list items conclude with this step.
\end{enumerate}
\begin{enumerate}[Step 1.]
    \item This is the first step of the example list.
    \item Obviously this is the second step.
    \item The final step to wind up this example.
\end{enumerate}

空格

上图的 negative space 用于减小距离

The \quad and \qquad commands are often used to adjust aligned formulas or to add space before text in a math formula. The size of \quad (= 1 em) and \qquad (= 2 em) depends on the current font.

18 mu = 1 em

\mspace{3mu} adds a space that is 1/6 em long.

The \, and \! commands are the most useful for fine tuning math formulas,

一些示例

$\sin(x)/\!\log(x)$  \\ %用\!减小距离
$\sqrt{5}\,\text{side}$\\ % \,拉开距离
$\int_{0}^{\pi}\sin x dx=2$\\
$\int_{0}^{\pi}\sin x \, dx=2$\\
$f(1/\sqrt{n})$\\
$f(1/\sqrt{n}\,)$\\
$f: A \to B$\\
$f \colon A \to B$\\ %\colon的spacing效果比:好
$|-f(x)|$\\  %这样写的话,spacing不对
$\left|-f(x)\right|$\\  % 要用\left|和\right|

利用已有符号创建新符号

\[
\overset{\alpha}{a} \qquad
\underset{\boldsymbol{\cdot}}{X} \qquad
\overset{\alpha}{ a_{i} } \qquad
\overset{\alpha}{a}_{i}
\]

\phantom 命令调整对齐,产生一个空格

\[
A = \begin{pmatrix}
\phantom{-}1 & \phantom{-}3 & \phantom{-}1\\
\phantom{-}2 & \phantom{-}1 & \phantom{-}1\\
-2 & \phantom{-}2 & -1\\
\end{pmatrix}
\]
\begin{align*}
a + b + c & + d \phantom{ {}+e } = 0,\\
c & + d + e = 5.
\end{align*}

\ 段内强制换行
\newpage 强制换页

本文转载自:https://blog.csdn.net/qq_36607894/article/details/100560421?utm_medium=distribute.pc_relevant.none-task-blog-BlogCommendFromBaidu-8.control&depth_1-utm_source=distribute.pc_relevant.none-task-blog-BlogCommendFromBaidu-8.control

最后修改:2023 年 08 月 18 日
如果觉得我的文章对你有用,请随意赞赏