适用于XDUTS的常见示例/代码片段 #40
Replies: 39 comments 127 replies
|
使用 \documentclass{xdupgthesis}
\usepackage{subcaption}
\begin{document}
\chapter{子图}
\begin{figure}
\centering
\subcaptionbox{a1\label{a1}}{\includegraphics[width=.3\linewidth]{example-image}}\hfill
\subcaptionbox{a2\label{a2}}{\includegraphics[width=.3\linewidth]{example-image}}\hfill
\subcaptionbox{a3\label{a3}}{\includegraphics[width=.3\linewidth]{example-image}}
\caption{aaa}
\label{aaa}
\end{figure}
\figurename~\ref{a1}
\figurename~\ref{a2}
\figurename~\ref{a3}
\figurename~\ref{aaa}
\begin{figure}
\centering
\subcaptionbox{b1\label{b1}}{\includegraphics[width=.3\linewidth]{example-image}}\hfill
\subcaptionbox{b2\label{b2}}{\includegraphics[width=.3\linewidth]{example-image}}\hfill
\subcaptionbox{b3\label{b3}}{\includegraphics[width=.3\linewidth]{example-image}}\hfill
\subcaptionbox{b4\label{b4}}{\includegraphics[width=.3\linewidth]{example-image}}\hfill
\subcaptionbox{b5\label{b5}}{\includegraphics[width=.3\linewidth]{example-image}}\hfill
\subcaptionbox{b6\label{b6}}{\includegraphics[width=.3\linewidth]{example-image}}
\caption{bbb}
\label{bbb}
\end{figure}
\figurename~\ref{b1}
\figurename~\ref{b2}
\figurename~\ref{b3}
\figurename~\ref{b4}
\figurename~\ref{b5}
\figurename~\ref{b6}
\figurename~\ref{bbb}
\end{document} |
|
利用 @proceedings{xxx,
editor = {牛志明 and 斯温兰德 and 雷光春},
title = {综合湿地管理国际研讨会论文集},
address = {北京},
publisher = {海洋出版社},
year = {2012},
}
@book{yyy,
author = {Fan, Xuetong and Sommers, Christopher H.},
title = {Food Irradiation Research and Technology},
edition = {2},
address = {Ames, Iowa},
publisher = {Blackwell Publishing},
year = {2013},
pages = {25--26},
}\documentclass{xdupgthesis}
\xdusetup{info/bib-resource=reference.bib}
\AtBeginDocument{
\DeclareNameFormat{firstauthor}{\namepartfamily}
\DeclareCiteCommand{\firstauthor}{}{\printnames[firstauthor]{labelname}}{}{}
\NewDocumentCommand{\facite}{m}{\firstauthor{#1}等人\cite{#1}}}
\begin{document}
\chapter{参考文献作者引用}
\section{仅引用第一作者}
\firstauthor{xxx}\par\firstauthor{yyy}
\section{引用第一作者和序号}
\facite{xxx}提出\par\facite{yyy}提出
\end{document} |
|
使用 \documentclass{xdupgthesis}
\usepackage{xcolor}
\usepackage{tabularray}
\begin{document}
\chapter{跨页表格}
我们发现\tablename~\ref{ltab} 是一个很长的表格。
\begin{longtblr}
[
caption = {一个很长的表格},
label = {ltab}
]
{
colspec = {Q[c,m]X[l,m]},
hline{1,Z} = {wd=.08em},
hline{2} = {wd=.05em},
row{even[2-Z]} = {bg=gray9!50},
row{1} = {font=\bfseries},
rowhead = 1,
}
Lorem ipsum dolor sit amet & consectetur adipisicing elit sed do eiusmod \\
tempor incididunt & ut labore et dolore magna aliqua Ut enim ad minim veniam \\
quis nostrud & exercitation ullamco laboris nisi ut aliquip ex ea commodo aute irure dolor in reprehenderit in voluptate velit esse \\
consequat Duis & aute irure dolor in reprehenderit in voluptate velit esse \\
cillum dolore eu & fugiat nulla pariatur Excepteur sint occaecat cupidatat non \\
proident sunt & in culpa qui officia deserunt mollit anim id est laborum \\
tempor incididunt & ut labore et dolore magna aliqua Ut enim ad minim veniam \\
quis nostrud & exercitation ullamco laboris nisi ut aliquip ex ea commodo aute irure dolor in reprehenderit in voluptate velit esse \\
consequat Duis & aute irure dolor in reprehenderit in voluptate velit esse \\
cillum dolore eu & fugiat nulla pariatur Excepteur sint occaecat cupidatat non \\
proident sunt & in culpa qui officia deserunt mollit anim id est laborum \\
tempor incididunt & ut labore et dolore magna aliqua Ut enim ad minim veniam \\
quis nostrud & exercitation ullamco laboris nisi ut aliquip ex ea commodo aute irure dolor in reprehenderit in voluptate velit esse \\
consequat Duis & aute irure dolor in reprehenderit in voluptate velit esse \\
cillum dolore eu & fugiat nulla pariatur Excepteur sint occaecat cupidatat non \\
proident sunt & in culpa qui officia deserunt mollit anim id est laborum \\
tempor incididunt & ut labore et dolore magna aliqua Ut enim ad minim veniam \\
quis nostrud & exercitation ullamco laboris nisi ut aliquip ex ea commodo aute irure dolor in reprehenderit in voluptate velit esse \\
consequat Duis & aute irure dolor in reprehenderit in voluptate velit esse \\
cillum dolore eu & fugiat nulla pariatur Excepteur sint occaecat cupidatat non \\
proident sunt & in culpa qui officia deserunt mollit anim id est laborum \\
tempor incididunt & ut labore et dolore magna aliqua Ut enim ad minim veniam \\
quis nostrud & exercitation ullamco laboris nisi ut aliquip ex ea commodo aute irure dolor in reprehenderit in voluptate velit esse \\
consequat Duis & aute irure dolor in reprehenderit in voluptate velit esse \\
cillum dolore eu & fugiat nulla pariatur Excepteur sint occaecat cupidatat non \\
proident sunt & in culpa qui officia deserunt mollit anim id est laborum \\
tempor incididunt & ut labore et dolore magna aliqua Ut enim ad minim veniam \\
quis nostrud & exercitation ullamco laboris nisi ut aliquip ex ea commodo aute irure dolor in reprehenderit in voluptate velit esse \\
consequat Duis & aute irure dolor in reprehenderit in voluptate velit esse \\
cillum dolore eu & fugiat nulla pariatur Excepteur sint occaecat cupidatat non \\
proident sunt & in culpa qui officia deserunt mollit anim id est laborum \\
\end{longtblr}
\end{document} |
|
使用 \documentclass{xdupgthesis}
\begin{document}
\chapter{多图并列(非子图)}
\begin{figure}[h]
\centering
\captionbox{a1\label{a1}}[.5\linewidth]{\includegraphics[width=.8\linewidth]{example-image}}%
\captionbox{a2\label{a2}}[.5\linewidth]{\includegraphics[width=.8\linewidth]{example-image}}
\end{figure}
\begin{figure}[h]
\centering
\captionbox{a3\label{a3}}[.33\linewidth]{\includegraphics[width=.8\linewidth]{example-image}}%
\captionbox{a4\label{a4}}[.33\linewidth]{\includegraphics[width=.8\linewidth]{example-image}}%
\captionbox{a5\label{a5}}[.33\linewidth]{\includegraphics[width=.8\linewidth]{example-image}}
\end{figure}
\figurename~\ref{a1}
\figurename~\ref{a2}
\figurename~\ref{a3}
\figurename~\ref{a4}
\figurename~\ref{a5}
\end{document} |
|
你好,我想将4张图片排成一列作为一个子图,一共排版这样5列,我写了如下代码,但是排版效果却与预期不同,是哪里出现问题了呢 \begin{figure}
\centering
\subcaptionbox[width=.15\textheight]{场景1\label{pic3_22_a}}{
\newline
\includegraphics[width=0.15\textwidth]{./photos/ch3/ch3errormap1_2gt.png}
\newline
\includegraphics[width=0.15\textwidth]{./photos/ch3/ch3errormap1_6gt.png}
\newline
\includegraphics[width=0.15\textwidth]{./photos/ch3/ch3errormap1_10gt.png}
\newline
\includegraphics[width=0.15\textwidth]{./photos/ch3/ch3errormap1_14gt.png}
\newline
}
\hfill
\subcaptionbox[height=.15\textheight]{场景2\label{pic3_22_b}}{
\newline
\includegraphics[width=0.15\textwidth]{./photos/ch3/ch3errormap1_2chazhi.png}
\newline
\includegraphics[width=0.15\textwidth]{./photos/ch3/ch3errormap1_6chazhi.png}
\newline
\includegraphics[width=0.15\textwidth]{./photos/ch3/ch3errormap1_10chazhi.png}
\newline
\includegraphics[width=0.15\textwidth]{./photos/ch3/ch3errormap1_14chazhi.png}
\newline
}\hfill
\subcaptionbox[height=.15\textheight]{场景3\label{pic3_22_c}}{
\newline
\includegraphics[width=0.15\textwidth]{./photos/ch3/ch3errormap1_2net1.png}
\newline
\includegraphics[width=0.15\textwidth]{./photos/ch3/ch3errormap1_6net1.png}
\newline
\includegraphics[width=0.15\textwidth]{./photos/ch3/ch3errormap1_10net1.png}
\newline
\includegraphics[width=0.15\textwidth]{./photos/ch3/ch3errormap1_14net1.png}
\newline
}\hfill
\subcaptionbox[height=.15\textheight]{场景4\label{pic3_22_d}}{
\newline
\includegraphics[width=0.15\textwidth]{./photos/ch3/ch3errormap1_2net2.png}
\newline
\includegraphics[width=0.15\textwidth]{./photos/ch3/ch3errormap1_6net2.png}
\newline
\includegraphics[width=0.15\textwidth]{./photos/ch3/ch3errormap1_10net2.png}
\newline
\includegraphics[width=0.15\textwidth]{./photos/ch3/ch3errormap1_14net2.png}
\newline
}\hfill
\subcaptionbox[height=.15\textheight]{场景5\label{pic3_22_e}}{
\newline
\includegraphics[width=0.15\textwidth]{./photos/ch3/ch3errormap1_2maan.png}
\newline
\includegraphics[width=0.15\textwidth]{./photos/ch3/ch3errormap1_6maan.png}
\newline
\includegraphics[width=0.15\textwidth]{./photos/ch3/ch3errormap1_10maan.png}
\newline
\includegraphics[width=0.15\textwidth]{./photos/ch3/ch3errormap1_14maan.png}
\newline
}
\end{figure}
下面是编译后生成的pdf的预览效果 |
|
只有最后一行图使用 \documentclass{xdupgthesis}
\usepackage{subcaption}
\begin{document}
\chapter{title}
\begin{figure}
\setlength{\lineskip}{0pt}
\centering
\includegraphics[width=.2\linewidth]{example-image}%
\includegraphics[width=.2\linewidth]{example-image}%
\includegraphics[width=.2\linewidth]{example-image}%
\includegraphics[width=.2\linewidth]{example-image}%
\includegraphics[width=.2\linewidth]{example-image}\\
\includegraphics[width=.2\linewidth]{example-image}%
\includegraphics[width=.2\linewidth]{example-image}%
\includegraphics[width=.2\linewidth]{example-image}%
\includegraphics[width=.2\linewidth]{example-image}%
\includegraphics[width=.2\linewidth]{example-image}\\
\includegraphics[width=.2\linewidth]{example-image}%
\includegraphics[width=.2\linewidth]{example-image}%
\includegraphics[width=.2\linewidth]{example-image}%
\includegraphics[width=.2\linewidth]{example-image}%
\includegraphics[width=.2\linewidth]{example-image}\\
\subcaptionbox{a1\label{a1}}{\includegraphics[width=.2\linewidth]{example-image}}%
\subcaptionbox{a2\label{a2}}{\includegraphics[width=.2\linewidth]{example-image}}%
\subcaptionbox{a3\label{a3}}{\includegraphics[width=.2\linewidth]{example-image}}%
\subcaptionbox{a4\label{a4}}{\includegraphics[width=.2\linewidth]{example-image}}%
\subcaptionbox{a5\label{a5}}{\includegraphics[width=.2\linewidth]{example-image}}
\caption{title}
\end{figure}
\end{document}使用 \documentclass{xdupgthesis}
\usepackage{subcaption}
\begin{document}
\chapter{title}
\begin{figure}
\centering
\subcaptionbox{a1\label{a1}}{%
\begin{minipage}{.2\linewidth}%
\setlength{\lineskip}{0pt}%
\includegraphics[width=\linewidth]{example-image}\\
\includegraphics[width=\linewidth]{example-image}\\
\includegraphics[width=\linewidth]{example-image}\\
\includegraphics[width=\linewidth]{example-image}
\end{minipage}%
}\hfill%
\subcaptionbox{a2\label{a2}}{%
\begin{minipage}{.2\linewidth}%
\setlength{\lineskip}{0pt}%
\includegraphics[width=\linewidth]{example-image}\\
\includegraphics[width=\linewidth]{example-image}\\
\includegraphics[width=\linewidth]{example-image}\\
\includegraphics[width=\linewidth]{example-image}
\end{minipage}%
}\hfill%
\subcaptionbox{a3\label{a3}}{%
\begin{minipage}{.2\linewidth}%
\setlength{\lineskip}{0pt}%
\includegraphics[width=\linewidth]{example-image}\\
\includegraphics[width=\linewidth]{example-image}\\
\includegraphics[width=\linewidth]{example-image}\\
\includegraphics[width=\linewidth]{example-image}
\end{minipage}%
}\hfill%
\subcaptionbox{a4\label{a4}}{%
\begin{minipage}{.2\linewidth}%
\setlength{\lineskip}{0pt}%
\includegraphics[width=\linewidth]{example-image}\\
\includegraphics[width=\linewidth]{example-image}\\
\includegraphics[width=\linewidth]{example-image}\\
\includegraphics[width=\linewidth]{example-image}
\end{minipage}%
}\hfill%
\subcaptionbox{a5\label{a5}}{%
\begin{minipage}{.2\linewidth}%
\setlength{\lineskip}{0pt}%
\includegraphics[width=\linewidth]{example-image}\\
\includegraphics[width=\linewidth]{example-image}\\
\includegraphics[width=\linewidth]{example-image}\\
\includegraphics[width=\linewidth]{example-image}
\end{minipage}%
}
\caption{title}
\end{figure}
\end{document} |
|
您好,可以提供一份算法伪代码的模板吗 |
|
|
使用 \documentclass{xdupgthesis}
\xdusetup{style/add-alg-rule-vspace=true}
\usepackage{algorithm}
\usepackage[commentColor=black,beginComment=//~,beginLComment=//~,endLComment=]{algpseudocodex}
\tikzset{algpxIndentLine/.style={draw=black}}
\algrenewcommand{\algorithmicrequire}{\textbf{输入:}}
\algrenewcommand{\algorithmicensure}{\textbf{输出:}}
\begin{document}
\chapter{算法环境}
\begin{algorithm}
\caption{这是一个算法}
\begin{algorithmic}[1]
\Require $x \in \{0,1\}$
\Ensure $y \in \{1,2\}$
\State $y \gets x+1$
\State \Return $y$
\While{condition}
\State body
\EndWhile
\For{$n = 1, \dots, 10$}
\State body
\EndFor
\If{condition}
\State body
\ElsIf{condition}
\State body
\Else
\State body
\EndIf
\State $x \gets y^2$
\LComment{The next two lines
increment both $x$ and $y$.}
\State $x \gets x + 1$
\Comment{Increment $x$.}
\State $y \gets y + 1$
\Comment{Increment $y$.}
\end{algorithmic}
\end{algorithm}
\end{document} |
|
在 \documentclass{xdupgthesis}
\usepackage{algpseudocodex}
\NewDocumentEnvironment{algframe}{+b}{\setlength{\fboxsep}{3pt}\setlength{\fboxrule}{.4pt}\fbox{\parbox{\dimexpr\linewidth-2\fboxsep-2\fboxrule}{#1}}}{}
\begin{document}
\chapter{figure浮动体与算法}
\begin{figure}
\begin{algframe}
\begin{algorithmic}[1]
\Require $x \in \{0,1\}$
\Ensure $y \in \{1,2\}$
\State $y \gets x+1$
\State \Return $y$
\end{algorithmic}
\end{algframe}
\caption{这是一个算法}
\end{figure}
\end{document} |
|
通过对照表列格式设置接口,可以自定义对照表列格式以及增加列间距。 % los.tex
XXX & XXX \\
XXX & XXX XXX XXX XXX XXX XXX XXX XXX XXX XXX XXX XXX \\
XXX XXX & XXX \\% loa.tex
XXX & XXX & XXX XXX XXX XXX XXX XXX XXX XXX XXX \\
XXX XXX & XXX & XXX \\
XXX & XXX XXX XXX & XXX \\\documentclass{xdupgthesis}
\xdusetup{
style / customize-los = false,
style / customize-loa = false,
style / colspec-los = {>{\hskip1cm}Q[l,h]<{\hskip2cm}X[l,h]},
style / colspec-loa = {>{\hskip1cm}Q[l,h]<{\hskip1cm}X[-1,l,h]X[-1,l,h]},
info / los = los.tex,
info / loa = loa.tex,
}
\begin{document}
\end{document} |
|
推荐使用Times风格数学字体,例如 除了Computer Modern字体外,其他字体均使用 \documentclass{xdupgthesis}
\xdusetup{style/math-font=xits}
\begin{document}
\chapter{unicode-math下数学符号加粗}
意大利体英文字符\textit{x}, \textit{A}, \textit{α}, \textit{G}。\par
不加粗数学符号$x,A,\alpha,G$。\par
加粗数学符号$\symbfit{x},\symbfit{A},\symbfit{\alpha},\symbfit{G}$。
\end{document}\documentclass{xdupgthesis}
\xdusetup{style/math-font=cm}
\usepackage{bm}
\begin{document}
\chapter{传统数学下数学符号加粗}
意大利体英文字符\textit{x}, \textit{A}, \textit{α}, \textit{G}。\par
不加粗数学符号$x,A,\alpha,G$。\par
加粗数学符号$\bm{x},\bm{A},\bm{\alpha},\bm{G}$。
\end{document} |
|
在使用 \documentclass{xdupgthesis}
\xdusetup{style/math-font=xits}
\begin{document}
\begin{equation}
\sum_{i=1}^\alpha a^i+b+\symcal{C}+\symcal{K}
\end{equation}
\end{document}\documentclass{xdupgthesis}
\xdusetup{style/math-font=xits}
\AtBeginDocument{\setmathfont{latinmodern-math.otf}[range={\sum,\symcal}]}
\begin{document}
\begin{equation}
\sum_{i=1}^\alpha a^i+b+\symcal{C}+\symcal{K}
\end{equation}
\end{document}\documentclass{xdupgthesis}
\xdusetup{style/math-font=xits}
\AtBeginDocument{\setmathfont{latinmodern-math.otf}[range={\sum,\symcal,\symbb}]}
\AtBeginDocument{\setmathfont{texgyrepagella-math.otf}[range={\symbb}]}
\begin{document}
\begin{equation}
\sum_{i=1}^\alpha a^i+b+\symcal{C}+\symcal{K}+\symbb{C}+\symbb{K}+\symbb{E}
\end{equation}
\end{document} |
|
下面给出一些 \documentclass{xdupgthesis}
\xdusetup{style/latin-font=tcc,style/math-font=xits}
\usepackage{xcolor}
\usepackage{tabularray}
\begin{document}
\chapter{tabularray示例}
以下表格内容均来自马建峰的博士学位论文《速率兼容LDPC码及其在H-ARQ系统中的应用》、崔海森的硕士学位论文《Repetier-Host源码分析与二次开发》和丁洁琼的硕士学位论文《基于RGB-D的SLAM算法研究》。数据内容没有修改,仅对个别样式进行了美化。
\section{设置单元格模式}
\begin{table}
\centering
\caption{$R=\frac{1}{2}$的校验矩阵}
\begin{tblr}{colspec={*{24}{X[c,m]}},cells={mode=math},columns={colsep=0pt},hlines,vlines}
-1 & 94 & 73 & -1 & -1 & -1 & -1 & -1 & 55 & 83 & -1 & -1 & 7 & 0 & -1 & -1 & -1 & -1 & -1 & -1 & -1 & -1 & -1 & -1 \\
-1 & 27 & -1 & -1 & -1 & 22 & 79 & 9 & -1 & -1 & -1 & 12 & -1 & 0 & 0 & -1 & -1 & -1 & -1 & -1 & -1 & -1 & -1 & -1 \\
-1 & -1 & -1 & 24 & 22 & 81 & -1 & 33 & -1 & -1 & -1 & 0 & -1 & -1 & 0 & 0 & -1 & -1 & -1 & -1 & -1 & -1 & -1 & -1 \\
61 & -1 & 47 & -1 & -1 & -1 & -1 & -1 & 65 & 25 & -1 & -1 & -1 & -1 & -1 & 0 & 0 & -1 & -1 & -1 & -1 & -1 & -1 & -1 \\
-1 & -1 & 39 & -1 & -1 & -1 & 84 & -1 & -1 & 41 & 72 & -1 & -1 & -1 & -1 & -1 & 0 & 0 & -1 & -1 & -1 & -1 & -1 & -1 \\
-1 & -1 & -1 & -1 & 46 & 40 & -1 & 82 & -1 & -1 & -1 & 79 & 0 & -1 & -1 & -1 & -1 & 0 & 0 & -1 & -1 & -1 & -1 & -1 \\
-1 & -1 & 95 & 53 & -1 & -1 & -1 & -1 & -1 & 14 & 18 & -1 & -1 & -1 & -1 & -1 & -1 & -1 & 0 & 0 & -1 & -1 & -1 & -1 \\
-1 & 11 & 73 & -1 & -1 & -1 & 2 & -1 & -1 & 47 & -1 & -1 & -1 & -1 & -1 & -1 & -1 & -1 & -1 & 0 & 0 & -1 & -1 & -1 \\
12 & -1 & -1 & -1 & 83 & 24 & -1 & 43 & -1 & -1 & -1 & 51 & -1 & -1 & -1 & -1 & -1 & -1 & -1 & -1 & 0 & 0 & -1 & -1 \\
-1 & -1 & -1 & -1 & -1 & 94 & -1 & 59 & -1 & -1 & 70 & 72 & -1 & -1 & -1 & -1 & -1 & -1 & -1 & -1 & -1 & 0 & 0 & -1 \\
-1 & -1 & 7 & 65 & -1 & -1 & -1 & -1 & 39 & 49 & -1 & -1 & -1 & -1 & -1 & -1 & -1 & -1 & -1 & -1 & -1 & -1 & 0 & 0 \\
43 & -1 & -1 & -1 & -1 & 66 & -1 & 41 & -1 & -1 & -1 & 26 & 7 & -1 & -1 & -1 & -1 & -1 & -1 & -1 & -1 & -1 & -1 & 0 \\
\end{tblr}
\end{table}
\section{三线表}
\begin{table}
\centering
\caption{不同码率$R$的码属性}
\begin{tblr}{colspec={X[2,c,m]*{3}{X[c,m]}},hline{1,Z}={wd=.08em},hline{2}={wd=.05em},cell{1-2}{2-Z}={mode=math}}
Code rate & \frac{1}{2} & \frac{2}{3} & \frac{3}{4} \\
Model matrix size & 12*24 & 8*24 & 6*24 \\
Information portion & Irregular & Irregular & Regular \\
\end{tblr}
\end{table}
\section{合并单元格}
\begin{table}
\centering
\caption{Complexity Comparison: Puncturing and Extending}
\begin{tblr}{colspec={*{3}{Q[c,m]}},cell{3,4,7,8}{2,3}={mode=math},hlines,vlines,cell{1,5}{1}={c=3}{}}
Encoding & & \\
& puncturing & extending \\
XOR & (k^2-k)(\frac{1}{R_0}-1) & (k^2-k)(\frac{1}{R_i}-1) \\
OR & k^2(\frac{1}{R_0}-1) & k^2(\frac{1}{R_i}-1) \\
Decoding (per iteration) & & \\
& puncturing & extending \\
addition & \frac{3tk}{R_0} & \frac{3tk}{R_i} \\
table-lookup & \frac{2tk}{R_0} & \frac{2tk}{R_i} \\
\end{tblr}
\end{table}
\begin{table}
\centering
\caption{Complexity Comparison: Puncturing and Extending (重制版)}
\begin{tblr}{colspec={*{4}{Q[c,m]}},cell{2,3,5,6}{3,4}={mode=math},hlines,vlines,cell{1,4}{1}={r=3}{}}
Encoding & & puncturing & extending \\
& XOR & (k^2-k)(\frac{1}{R_0}-1) & (k^2-k)(\frac{1}{R_i}-1) \\
& OR & k^2(\frac{1}{R_0}-1) & k^2(\frac{1}{R_i}-1) \\
Decoding (per iteration) & & puncturing & extending \\
& addition & \frac{3tk}{R_0} & \frac{3tk}{R_i} \\
& table-lookup & \frac{2tk}{R_0} & \frac{2tk}{R_i} \\
\end{tblr}
\end{table}
\section{手动换行与X列自动换行}
\begin{table}
\centering
\caption{OBJ文件中的常见关键字}
\begin{tblr}{colspec={Q[c,m]X[c,m]},hlines,vlines,cell{2-Z}{1}={mode=math},row{1}={font=\bfseries},cell{2-Z}{2}={halign=l}}
关键字 & 说明 \\
v & 表示本行指定一个顶点。此前缀后跟3个单精度浮点数,分别表示该顶点的X、Y、Z坐标值。 \\
vt & 表示本行指定一个纹理坐标。此前缀后跟两个单精度浮点数。分别表示此纹理坐标的U、V值。 \\
vn & 表示本行指定一个法线向量。此前缀后跟3个单精度浮点数,分别表示该法向量的X、Y、Z坐标值。 \\
vp & 参数空间顶点 \\
p & 点 \\
l & 线 \\
f & {表示本行指定一个面(Face)。\\一个面实际上就是一个三角形图元。} \\
curv & 曲线 \\
curv2 & 2D曲线 \\
surf & 曲面 \\
\end{tblr}
\end{table}
\section{字体切换}
\begin{table}
\centering
\caption{注册表的五个分支}
\begin{tblr}{colspec={Q[l,m]X[l,m]},hlines,vlines,cell{2-Z}{1}={font=\ttfamily},row{1}={cmd=\bfseries,halign=c}}
名称 & 作用 \\
HKEY\_CLASSES\_ROOT & 有关文件关联和COM的设置信息,这是\texttt{HKLM\textbackslash SOFTWARE\textbackslash Classes}和\texttt{HKCU\textbackslash SOFTWARE\textbackslash Classes}两棵子树合并后的一个视图 \\
HKEY\_CURRENT\_USER & 有关当前用户的信息,这是一个符号链接,指HKU中对应于当前用户的子键 \\
HKEY\_LOCAL\_MACHINE & 有关当前系统的信息 \\
HKEY\_USERS & 有关该机器上所有用户账户的信息 \\
HKEY\_CURRENT\_CONFIG & 有关当前硬件配置的信息,这是一个符号链接,指向\texttt{HKLM\textbackslash SYSTEM\textbackslash CurrentControlSet\textbackslash Hardware Profiles\textbackslash Current} \\
\end{tblr}
\end{table}
\section{颜色}
\begin{table}
\centering
\caption{X80传感器分布图}
\begin{tblr}{colspec={X[c,m]X[c,m]},hlines,vlines}
传感器模块 & 位置 \\
红外传感器\#1 & A 左前方 \\
红外传感器\#2 & B 前方中间 \\
红外传感器\#3 & C 前方中间 \\
红外传感器\#4 & D 右前方 \\
红外传感器\#5 & E 右边 \\
红外传感器\#6 & F 尾部 \\
红外传感器\#7 & G 左边 \\
超声波传感器\#1 & H 左前方 \\
超声波传感器\#2 & I 前方中间 \\
超声波传感器\#3 & J 右前方 \\
人体移动感知传感器\#1 & K 左边 \\
人体移动感知传感器\#2 & L 右边 \\
正交编码器\#1 & M 左边,使用通道 1 \\
正交编码器\#2 & N 右边,使用通道 2 \\
\end{tblr}
\end{table}
\begin{table}
\centering
\caption{X80传感器分布图 (重置版本)}
\begin{tblr}{colspec={X[c,m]X[c,m]},hline{1,Z}={wd=.08em},hline{2}={wd=.05em},row{even[2-Z]}={bg=gray9!40},row{1}={font=\bfseries}}
传感器模块 & 位置 \\
红外传感器\#1 & A 左前方 \\
红外传感器\#2 & B 前方中间 \\
红外传感器\#3 & C 前方中间 \\
红外传感器\#4 & D 右前方 \\
红外传感器\#5 & E 右边 \\
红外传感器\#6 & F 尾部 \\
红外传感器\#7 & G 左边 \\
超声波传感器\#1 & H 左前方 \\
超声波传感器\#2 & I 前方中间 \\
超声波传感器\#3 & J 右前方 \\
人体移动感知传感器\#1 & K 左边 \\
人体移动感知传感器\#2 & L 右边 \\
正交编码器\#1 & M 左边,使用通道 1 \\
正交编码器\#2 & N 右边,使用通道 2 \\
\end{tblr}
\end{table}
\end{document} |
|
下面给出一些关于相似性检测的信息,以下信息仅供参考,有任何后果概不负责。 在关于知网学位论文检测系统的说明及修改指导意见和关于知网学位论文检测系统的说明及修改指导意见中均有如下表述:
在关于2023年夏季硕士研究生申请学位工作的通知[中矿大京研学位字(2023)4号]-中国矿业大学(北京)研究生院中的附件7 学术不端行为检测常见问题解答.docx有如下表述:
|
|
可以利用 \documentclass{xdupgthesis}
\usepackage{tabularray}
\usepackage[export]{adjustbox}
\newlength{\SmallImgHeight}
\setlength{\SmallImgHeight}{40pt}
\newlength{\SubCaptionHeight}
\setlength{\SubCaptionHeight}{25pt}
\newlength{\BigImgHeight}
\setlength{\BigImgHeight}{\SubCaptionHeight}
\addtolength{\BigImgHeight}{\the\SmallImgHeight}
\addtolength{\BigImgHeight}{\the\SmallImgHeight}
\NewDocumentCommand{\InsSmallImg}{m}{\includegraphics[width=\linewidth,height=\SmallImgHeight,valign=c]{#1}}
\NewDocumentCommand{\InsBigImg}{m}{\includegraphics[width=\linewidth,height=\BigImgHeight,valign=c]{#1}}
\ExplSyntaxOn
\NewChildSelector{everyfour}[1][]{\int_step_inline:nnnn{1}{4}{\l_tblr_childs_total_tl}{\clist_put_right:Nn\l_tblr_childs_clist{##1}}}
\ExplSyntaxOff
\begin{document}
\chapter{title}
\begin{figure}
\begin{tblr}
{
colspec = {X[1.5,c,m]X[c,m]X[c,m]X[c,m]X[c,m]X[c,m]},
cell{everyfour[1-Z]}{1} = {r=3}{},
columns = {colsep=3pt},
column{1} = {leftsep=0pt},
column{Z} = {rightsep=0pt},
stretch = 0,
rows = {rowsep=0pt},
row{even[1-Z]} = {cmd={\small\setlength{\baselineskip}{10pt}}},
row{even[1-Z]} = {ht=\SubCaptionHeight},
cell{everyfour[1-Z]}{1} = {cmd=\InsBigImg},
cell{odd[1-Z]}{2-Z} = {cmd=\InsSmallImg},
}
example-image-a.pdf & example-image-b.pdf & example-image-b.pdf & example-image-b.pdf & example-image-b.pdf & example-image-b.pdf \\
& Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg \\
& example-image-b.pdf & example-image-b.pdf & example-image-b.pdf & example-image-b.pdf & example-image-b.pdf \\
Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg \\
example-image-a.pdf & example-image-b.pdf & example-image-b.pdf & example-image-b.pdf & example-image-b.pdf & example-image-b.pdf \\
& Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg \\
& example-image-b.pdf & example-image-b.pdf & example-image-b.pdf & example-image-b.pdf & example-image-b.pdf \\
Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg \\
example-image-a.pdf & example-image-b.pdf & example-image-b.pdf & example-image-b.pdf & example-image-b.pdf & example-image-b.pdf \\
& Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg \\
& example-image-b.pdf & example-image-b.pdf & example-image-b.pdf & example-image-b.pdf & example-image-b.pdf \\
Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg \\
example-image-a.pdf & example-image-b.pdf & example-image-b.pdf & example-image-b.pdf & example-image-b.pdf & example-image-b.pdf \\
& Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg \\
& example-image-b.pdf & example-image-b.pdf & example-image-b.pdf & example-image-b.pdf & example-image-b.pdf \\
Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg \\
example-image-a.pdf & example-image-b.pdf & example-image-b.pdf & example-image-b.pdf & example-image-b.pdf & example-image-b.pdf \\
& Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg \\
& example-image-b.pdf & example-image-b.pdf & example-image-b.pdf & example-image-b.pdf & example-image-b.pdf \\
Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg & Teg Teg Teg Teg Teg Teg \\
\end{tblr}
\caption{title}
\end{figure}
\end{document} |
|
使用 \documentclass{xdupgthesis}
\begin{document}
\chapter{图表并列}
\begingroup
\setlength{\parindent}{0pt}
\begin{minipage}{.5\linewidth}
\centering
\includegraphics[width=.9\linewidth]{example-image}
\captionof{figure}{title}
\end{minipage}%
\begin{minipage}{.5\linewidth}
\captionof{table}{title}
\centering
\begin{tabular}{|c|c|c|c|}
\hline
test & test & test & test \\
\hline
test & test & test & test \\
\hline
test & test & test & test \\
\hline
test & test & test & test \\
\hline
test & test & test & test \\
\hline
test & test & test & test \\
\hline
\end{tabular}
\end{minipage}
\endgroup
\end{document} |
|
开发者你好,请问硕士论文中可以使用“有序列表”和“无序列表”吗? 如果可以,应该如何正确使用 enumerate 和 itemize 环境,自己使用后感觉间距不太对,应该如何调整呢?麻烦解答一下,谢谢! |
|
使用 # draw.py
import matplotlib
import matplotlib.pyplot as plt
if __name__ == '__main__':
matplotlib.rcParams['font.family'] = 'serif'
matplotlib.rcParams['font.size'] = '10'
matplotlib.rcParams['pgf.texsystem'] = 'xelatex'
matplotlib.rcParams['pgf.preamble'] = r'\usepackage{XeCJK}'
matplotlib.rcParams['legend.frameon'] = 'True'
fig, main_ax = plt.subplots(constrained_layout=True)
fig_size = (220, 100)
fig.set_figwidth(fig_size[0] / 72.27)
fig.set_figheight(fig_size[1] / 72.27)
main_ax.plot([1, 2, 3, 4, 5], [1, 2, 3, 4, 9], label='第一条line')
main_ax.plot([1, 2, 3, 4, 5], [1, 3, 3, 7, 3], label='第二条line')
main_ax.legend()
pfg_file = 'fig.pgf'
plt.savefig(pfg_file, transparent=True)
plt.close()% main.tex
\documentclass{xdupgthesis}
\usepackage{pgf}
\begin{document}
\begin{figure}
\centering
\input{fig.pgf}
\caption{Matplotlib+PGF示例}
\end{figure}
\end{document} |
|
使用去除页面命令时,保留索引和对照表,中英文摘要和正文,出现缩略语对照表未加空百页,单独一页后面紧跟第一章。 |
|
虽然学校没有明确规定一定要使用中易字体,但是仍然建议优先使用中易字体和Times New Roman,如果存在字体缺失,参考 #40 (comment) 自行安装对应字体,Overleaf用户参考 #236 。默认的字体配置仅仅是因为该字体内置于TeX Live中,任何平台均可直接编译,默认字体配置不意味着最佳配置。 \documentclass{xdupgthesis}
\xdusetup{style={cjk-font=win,latin-font=tac}}
\begin{document}
\end{document} |
|
介绍 Windows 平台安装 TeX Live 和 TeXstudio 的关键步骤。其他平台可作参考,macOS 需安装 MacTeX,Linux 需安装 TeX Live,具体方法可自行查阅。TeXstudio 仅为编辑器,用户可根据个人习惯选择适合的编辑器,此处以较为常见的 TeXstudio 为例。 以下所有内容仅仅是参考,本质上与 XDUTS 无关,仅仅是为了方便新用户使用而撰写,用户完全可以根据自身的情况进行环境安装和配置。 TeX Live卸载旧版本如果系统中已安装 TeX Live 且版本非最新,建议先卸载旧版本后再安装新版本。可按以下步骤操作:
安装最新版本以下为 TeX Live 最新版的下载地址,其中一个为校内镜像站,下载时可免流量: 下载任意一个 下载完成后,使用文件资源管理器打开 TeXstudio下载与安装TeXstudio 可通过以下镜像站下载,例如 建议在安装好 TeX Live 后再安装 TeXstudio,默认安装即可。 配置以下关于编译命令的设置是必要的: 设置完毕后,③的位置如图所示即可,点击①会编译文件,但是不编译参考文献,时间较短,点击②会三次编译,需要编译参考文献的时候再点击,编译时间较长。④必须设置为 XeLaTeX,⑤默认设置为 biber,如果在代码中配置了 bibtex,可以根据情况修改。点击⑥可以查看 PDF。 |
|
推荐在使用 PowerPoint、Visio 等绘图软件制作图片时,优先打印为 PDF 格式,不建议选择导出,导出可能会导致部分内容错位。只要软件支持直接生成 PDF 格式,均应优先选择 PDF,而非 通常情况下,直接打印的 PDF 文件四周可能带有空白边距。对此,可以使用 TeX Live 内置工具进行裁剪。例如,假设 |
|
给一个对照表的配置,该配置对每一项中多行之间的间距做了优化。 \documentclass{xdupgthesis}
\xdusetup{
style / customize-los = true,
style / customize-loa = true,
info / los = los.tex,
info / loa = loa.tex,
}
\usepackage{tabularray}
\NewTblrTheme{mylosloatheme}{\SetTblrTemplate{head,foot}{empty}}
\begin{document}
\end{document}% los.tex
\begin{tblr}[long,label=none,entry=none,theme=mylosloatheme]
{
columns={valign=m,co=-1},
rows={halign=l},
cells={font=\rmfamily\zihao{-4}\setlength{\baselineskip}{15pt}},
abovesep=0pt,
belowsep=4.3415pt,
}
符号 & 符号名称 \\
XXX & XXX \\
XXX & XXX XXX XXX XXX XXX XXX XXX XXX XXX XXX XXX XXX \\
XXX XXX & XXX \\
\end{tblr}% loa.tex
\begin{tblr}[long,label=none,entry=none,theme=mylosloatheme]
{
columns={valign=m,co=-1},
rows={halign=l},
cells={font=\rmfamily\zihao{-4}\setlength{\baselineskip}{15pt}},
abovesep=0pt,
belowsep=4.3415pt,
}
缩略语 & 英文全称 & 中文对照 \\
XXX & XXX & XXX XXX XXX XXX XXX XXX XXX XXX XXX \\
XXX XXX & XXX & XXX \\
XXX & XXX XXX XXX & XXX \\
\end{tblr} |
|
对于部分Overleaf或者TeXPage编译超时的,可以在项目根目录新建 即可在一定程度上突破编译时长的限制。原理为默认点击编译按钮是进行多次编译,使用上述方法设置以后,仅进行一次编译。 |
\setlength{\lineskip}{1pt}
\setlength{\normallineskip}{1pt}
\setlength{\lineskiplimit}{1pt}
\setlength{\normallineskiplimit}{1pt}放在导言区中,上述设置可以保证至少1pt的行距,避免正文中行内公式挤压行距。 |







































Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
在此处,用户可以提出仅限于实际文章撰写中的需求,例如,子图子表如何编写。
不应在此处讨论XDUTS的bug或者功能建议。简单来讲,此处所交流的内容实际上与XDUTS无关,仅仅为了帮助部分对LaTeX不熟悉的用户能够实现更好的排版效果。
此处内容较多,用户可使用
Ctrl+F来查找相关内容。All reactions