Skip to content

Commit

Permalink
Test nomenclature grouping
Browse files Browse the repository at this point in the history
  • Loading branch information
zepinglee committed Nov 18, 2024
1 parent 306d1f1 commit 117a047
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 25 deletions.
35 changes: 10 additions & 25 deletions chapters/notation.tex
Original file line number Diff line number Diff line change
@@ -1,27 +1,12 @@
% !TeX root = ../main.tex

\begin{notation}

\begin{notationlist}{2em}
\item[$\displaystyle a$] The number of angels per unit area
\item[$\displaystyle N$] The number of angels per needle point
\item[$\displaystyle A$] The area of the needle point
\item[$\displaystyle \sigma$] The total mass of angels per unit area
\item[$\displaystyle m$] The mass of one angel
\item[$\displaystyle \sum_{i=1}^n a_i$] The sum of $a_i$
\end{notationlist}

\end{notation}



% 也可以使用 nomencl 宏包

% \printnomenclature

% \nomenclature{$\displaystyle a$}{The number of angels per unit are}
% \nomenclature{$\displaystyle N$}{The number of angels per needle point}
% \nomenclature{$\displaystyle A$}{The area of the needle point}
% \nomenclature{$\displaystyle \sigma$}{The total mass of angels per unit area}
% \nomenclature{$\displaystyle m$}{The mass of one angel}
% \nomenclature{$\displaystyle \sum_{i=1}^n a_i$}{The sum of $a_i$}
\printnomenclature

\nomenclature[P]{\(c\)}{Speed of light in a vacuum}
\nomenclature[P]{\(h\)}{Planck constant}
\nomenclature[P]{\(G\)}{Gravitational constant}
\nomenclature[N]{\(\mathbb{R}\)}{Real numbers}
\nomenclature[N]{\(\mathbb{C}\)}{Complex numbers}
\nomenclature[N]{\(\mathbb{H}\)}{Quaternions}
\nomenclature[O]{\(V\)}{Constant volume}
\nomenclature[O]{\(\rho\)}{Friction index}
11 changes: 11 additions & 0 deletions ustcsetup.tex
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,17 @@
% 配置图片的默认目录
\graphicspath{{figures/}}

\usepackage{nomencl}
\makenomenclature

\usepackage{etoolbox}
\renewcommand\nomgroup[1]{%
\item[\bfseries
\ifstrequal{#1}{P}{Physics constants}{%
\ifstrequal{#1}{N}{Number sets}{%
\ifstrequal{#1}{O}{Other symbols}{}}}%
]}

% 数学命令
\makeatletter
\newcommand\dif{% % 微分符号
Expand Down

0 comments on commit 117a047

Please sign in to comment.