1

I am trying to get rid of extra empty page in \frontmatter of \documentclass[twoside]{book} between passages of Abbreviations and List of symbols. I am using for printing and managing list of symbols package nomenclature.

MWE:

% arara: lualatex: { shell: true }
% arara: nomencl
% arara: makeglossaries
% arara:  lualatex: { synctex: true, shell: true }
% arara:  lualatex: { synctex: true, shell: true }

\documentclass [a4paper, 12pt, twoside] {book}              
\usepackage [czech] {babel} 
\usepackage [utf8] {inputenc}
\usepackage{amssymb}            
\usepackage [left=2.5cm, right=2cm, bottom=3cm] {geometry}      
\linespread{1.0}
\usepackage{array}

\usepackage{booktabs}
\usepackage{longtable}

\setlength{\tabcolsep}{10pt}
\renewcommand{\arraystretch}{1.2}   

%List of Abbreviations
\usepackage[xindy={language=czech, codepage=utf8}, automake, abbreviations,%
                    stylemods=longbooktabs%
                    ]{glossaries-extra}

\makeglossaries

\setglossarystyle{long-booktabs}
\renewcommand*{\entryname}{Acronym}
\renewcommand*{\descriptionname}{Description}

\setabbreviationstyle[acronym]{long-short-user}

\usepackage[intoc]{nomencl}

\usepackage{ifthen}
  \renewcommand{\nomgroup}[1]{%
  \item[\bfseries
  \ifthenelse{\equal{#1}{P}}{Physics Constants}{%
  \ifthenelse{\equal{#1}{O}}{Other Symbols}{%
  \ifthenelse{\equal{#1}{N}}{Number Sets}{}}}%
  ]}

% This will add the units
%----------------------------------------------
\newcommand{\nomunit}[1]{%
\renewcommand{\nomentryend}{\hspace*{\fill}#1}}
%----------------------------------------------

\makenomenclature
\renewcommand{\nomname}{Symbol definitions}

%Abbreviations
\newacronym{abc}{ABC}{beginning of alphabet}
\newacronym{def}{DEF}{another part of alphabet}

\begin{document}

\nonfrenchspacing

\frontmatter                                        
\pagestyle{plain}

\glsaddall
\printglossary[type=\acronymtype, nonumberlist, nopostdot, title=Abbreviations] 

%Symbols
\nomenclature[P]{$c$}{Speed of light in a vacuum inertial system
    \nomunit{$299,792,458\, m/s$}}

\nomenclature[N]{$\mathbb{R}$}{Real Numbers}
\nomenclature[O]{$V$}{Constant Volume}

\printnomenclature

\clearpage

\end{document}

On final note: I have only beginner knowledge of LaTeX, solution to this might be easy, but I can't find it. Also, if you compile MWE, you get 2 blank pages on the beginning. I don't know why, in original document, that I am working with, those don't appear, so no need to resolve that issue.

Any help is appreciated.

Regards, Tomáš

2

The empty pages are inserted because the list of abbreviations and the list of symbols are each treated like a chapter, which are only supposed to start on left hand pages. To avoid this problem, one can temporally change the definition of \cleardoublepage:

% !TeX program = txs:///arara
% arara: lualatex: { shell: true }
% arara: nomencl
% arara: makeglossaries
% arara:  lualatex: { synctex: true, shell: true }
% arara:  lualatex: { synctex: true, shell: true }

\documentclass [a4paper, 12pt, twoside] {book}              
\usepackage [czech] {babel} 
\usepackage [utf8] {inputenc}
\usepackage{amssymb}            
\usepackage [left=2.5cm, right=2cm, bottom=3cm] {geometry}      
\linespread{1.0}
\usepackage{array}

\usepackage{booktabs}
\usepackage{longtable}

\setlength{\tabcolsep}{10pt}
\renewcommand{\arraystretch}{1.2}   

%List of Abbreviations
\usepackage[xindy={language=czech, codepage=utf8}, automake, abbreviations,%
                    stylemods=longbooktabs%
                    ]{glossaries-extra}

\makeglossaries

\setglossarystyle{long-booktabs}
\renewcommand*{\entryname}{Acronym}
\renewcommand*{\descriptionname}{Description}

\setabbreviationstyle[acronym]{long-short-user}

\usepackage[intoc]{nomencl}

\usepackage{ifthen}
  \renewcommand{\nomgroup}[1]{%
  \item[\bfseries
  \ifthenelse{\equal{#1}{P}}{Physics Constants}{%
  \ifthenelse{\equal{#1}{O}}{Other Symbols}{%
  \ifthenelse{\equal{#1}{N}}{Number Sets}{}}}%
  ]}

% This will add the units
%----------------------------------------------
\newcommand{\nomunit}[1]{%
\renewcommand{\nomentryend}{\hspace*{\fill}#1}}
%----------------------------------------------

\makenomenclature
\renewcommand{\nomname}{Symbol definitions}

%Abbreviations
\newacronym{abc}{ABC}{beginning of alphabet}
\newacronym{def}{DEF}{another part of alphabet}

\begin{document}

\nonfrenchspacing

\frontmatter                                        
\pagestyle{plain}

{
\let\cleardoublepage\clearpage
\glsaddall
\printglossary[type=\acronymtype, nonumberlist, nopostdot, title=Abbreviations] 

%Symbols
\nomenclature[P]{$c$}{Speed of light in a vacuum inertial system
    \nomunit{$299,792,458\, m/s$}}

\nomenclature[N]{$\mathbb{R}$}{Real Numbers}
\nomenclature[O]{$V$}{Constant Volume}

\printnomenclature
}
\clearpage

\end{document}
  • Thank you very much, worked perfectly :) Since it is temporarily, the changed state of \cleardoublepage ends after "}" after \printnomenclature? – Tomáš Kruliš Apr 10 at 15:10
  • @TomášKruliš Exactly, the redefinition only affects the things inside {...}, everything else will be left untouched – user185220 Apr 10 at 15:11

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.