0

I adapted the nomenclature from this post here: How to achieve nomenclature entries like: symbol, Description, Dimension and unit, etc? but I had diffulties to adapt it for my own purpose.

This is the code im currently working with:

\newcommand{\nomunit}[1]{\hfill\makebox[2em]{#1\hfill}\ignorespaces}
\newcommand{\insertnomheaders}{\item[\bfseries Symbol]%
\textbf{Description}\nomunit{\textbf{Units}}}

\renewcommand\nomgroup[1]{%
\item[\large\bfseries
\ifstrequal{#1}{A}{Acronyms}{%
    \ifstrequal{#1}{R}{Roman Symbols}{%
        \ifstrequal{#1}{G}{Greek Symbols}}}]
\insertnomheaders}

\renewcommand*{\nompreamble}{\markboth{\nomname}{\nomname}}

\newcommand{\nomdescr}[1]{\parbox[t]{12cm}{\RaggedRight #1}}
 \newcommand{\nomwithdim}[4]{\nomenclature[#1]{#2}%
{\nomdescr{#3}\nomunit{#4}}}
\makenomenclature

\begin{document}
\mbox{}
\nomwithdim{R}{\(a,b,c\)}{half axes of ellipsoid}{\si{m}}
\nomwithdim{R}{\(C\)}{dimensionless coefficient (e.g.\ for drag model)}
\nomwithdim{G}{\( \varepsilon_0 \)}{vacuum permittivity}

\printnomenclature[6em]
\end{document}

What I want to have in the end is Acronyms with only symbol and description without units and Greek & Romand symbols with symbol description and units

The original design is fine but I have difficulties to delete the dimension and for acronyms both dimension and units without getting errors.

Thank you for your help.

This is how it should look like

0

I found a solution for my problem. I figured out that changing the code is harder than rewriting it. In case you are interested, here is what I did:

\DeclarePairedDelimiter{\abs}{\lvert}{\rvert}
\newcommand{\units}[1]{\hfill\makebox[2em]{#1\hfill}\ignorespaces}

\newcommand{\nomsubtitle}[1]{\item[\large\bfseries #1]}
\renewcommand\nomgroup[1]{\def\nomtemp{\csname nomstart#1\endcsname}\nomtemp}

\newcommand{\nomstartR}{\nomsubtitle{Roman Symbols}%
\item[\bfseries Symbol]%
\textbf{Description}\units{\textbf{Unit}}}

\newcommand{\nomstartG}{\nomsubtitle{Greek Symbols}%
\item[\bfseries Symbol]%
\textbf{Description}\units{\textbf{Unit}}}

\newcommand{\nomstartA}{\nomsubtitle{Acronyms}%
\item[\bfseries Acronym]\textbf{Description}}


\renewcommand*{\nompreamble}{\markboth{\nomname}{\nomname}}

\newcommand{\nomdescr}[1]{\parbox[t]{12cm}{\RaggedRight #1}}

\newcommand{\nomtypeA}[3][]{\nomenclature[A#1]{#2}{\nomdescr{#3}}}
\newcommand{\nomwithunits}[4]{\nomenclature[#1]{#2}%
{\nomdescr{#3}\units{#4}}} %neuer Befehl zum Gesamtergebnis der Symbole
\newcommand{\nomtypeR}[4][]{\nomwithunits{R#1}{#2}{#3}{#4}}
\newcommand{\nomtypeG}[4][]{\nomwithunits{G#1}{#2}{#3}{#4}}


\makenomenclature

\begin{document}

\mbox{}

\nomtypeA{Cd}{Cadmium}
\nomtypeA{\ce{CdAc2}}{Cadmium acetat dihydrate}
\nomtypeA{CdSe}{Cadmium selenide}
\nomtypeA{i.e.}{For example}
\nomtypeA{ODE}{1-Octadecene}
\nomtypeA{QD}{Quantum Dots}
\nomtypeA{Se}{Selenium}
\nomtypeA{TDPA}{Tetradecylphosphonic acid}
\nomtypeA{TOP}{Trioctylphosphine}

\nomtypeG{$\alpha$}{Angle of a triangle}{-}

\nomtypeR{A}{This is a test}{kg}
{end{document}

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.