The PDF is printed on both sides. The thing is, the compilation produced an unexpected blank page, i.e. p53. The strange thing is that a footnote supposed to be on the last but one page, appears on this empty page, p53. (see the following screenshot.)unexpected empty page before final page

I moved the bit to various places in the paper, it consistently produced an empty page or two around the final page of the PDF file. I also compiled the files on my local computer. It produced an empty ending page too and failed to generate any bibliography without errors.

The class file as well as other related files can be downloaded from journal website. The class file is the first one in the list on that page.

The working environment was modified as suggested because of the error reported and solved at: cause of the error. Another related link: problem with CL style file

I reproduced the problem using the modified working environment as well as a minimal text fragment from CL manual. The problem looks like this:blank page problem BTW, I am using PdfLaTex (2020 Lagacy) on Overleaf. Also, when I tried to compile it locally, the PDF document is only 2 pages long because of missing information. My impression is that it has to be more than two pages so that the problem arises.

The code is as follows:

% if your latex compiler failed to compile, uncomment the command below:

%% the fllowing is the suggested change at : https://tex.stackexchange.com/questions/688299/latex-error-command-numdef-already-defined?noredirect=1#comment1707626_688299 

% save the kernel \document and \enddocument


% restore the original below \docucumentclass{clv3}

% add to the standard hooks
   %   \process@queries\clearpage


% alias numdef to cnumdef
\let\numdef\relax \let\endnumdef\relax

%% above is the suggested change
%the following is for tree-drawing
% the following two lines are added by the author to show Chinese characters

% nicer emptyset

\definecolor{darkblue}{rgb}{0, 0, 0.5}
\hypersetup{colorlinks=true,citecolor=darkblue, linkcolor=darkblue, urlcolor=darkblue}



%Document Head
\dochead{CLV3 Class File Manual}

\runningtitle{How to Use CLV3 \LaTeX\ Class File}

\runningauthor{Odi\'e N. Gementera}

\pageonefooter{Action editor: \{action editor name\}. Submission received: DD Month YYYY; revised version received: DD Month YYYY; accepted for publication: DD Month YYYY.}

\title{How to Use CLV3 \LaTeX\ Class File}

\author{Odi\'e N. Gementera\thanks{PITC Building, Pascor Drive, Sto. Ni\~no, Para\~naque City, 1700 Philippines. E-mail: [email protected].}}
\affil{Publishing / SPi}

\author{Another Author\thanks{PITC Building}}
\affil{Publishing / SPi}

\author{And Another Author}
\affil{Publishing / SPi}

\author{And Yet Another}
\affil{Publishing / SPi}


This is the abstract text . . .

Citations in parentheses are declared using the \verb|\cite{}|
command, and appear in the text as follows: 
This technique is widely used \cite{woods}.
The command \verb|\citep{}| (cite parenthetical) is a synonym of \verb|\cite{}|.

Citations used in the sentence are declared using the \verb|\namecite{}|
commands, and appear in the text as follows: 
\namecite{woods} first described this technique.
The command \verb|\citet{}| (cite textual) is a synonym of \verb|\namecite{}|.

This style file is designed to be used with the BibTeX
style file \verb|compling.bst|.  Include the command
\verb|\bibliographystyle{compling}| in your source file.

Citation commands are based on the \verb|natbib| package;
for details on options and further variants of the commands,
see the \verb|natbib| documentation.  In particular, options 
exist to add extra text and page numbers.  For example, 
\verb|\cite[cf.][ch.\ 1]{winograd}| yields: \cite[cf.][ch.\ 1]{winograd}.

The following examples illustrate how citations appear both in the text
and in the references section at the end of this document.
\item Article in journal: 
\item Book: 
\item Article in edited collection/Chapter in book: 
\item Technical report:
\item Thesis or dissertation: 
\item Unpublished item: 
\item Conference proceedings: 
\item Paper published in conference proceedings: 

\section{Definition with Head}

Definition with head is declared by using the environment:
Definition text. . .

This environment will generate the word {\bf ``Definition 1''} in bold on separate
line. The sequence number is generated for every definition environment. Definition 
data will have no indention on the first line while succeeding lines will have hang 


Other items such as Equations, Figures, Tables and References are produced in
the standard \LaTeX\ typesetting.\footnote{Please mind the odd position of this footnote.}



Thanks a lot in advance!~~~

  • Just fyi, a minimal working example should contain the bare minimum code to reproduce an issue. Your example code is identical to egreg's code from one of the questions in your links, and it contains many packages you don't use (e.g. no need to load forest if you don't draw any syntax trees). Additionally, I'm a little bit confused about recreating the problem. You say a footnote appears on an unexpected blank page, but your example code doesn't contain any \footnotes, and I don't see any blank pages when I compile. If you could edit your question, that could help us in solving the issue.
    – gz839918
    Commented Jun 26, 2023 at 3:22
  • Thanks, @gz839918. My paper is a manuscript and fairly long in which I used those packages including forest. It's not convenient to upload (part of) the manuscript text here, so I used different text bits to reproduce the same problem (i.e. blank page). It is interesting to know that you didn't get any blank pages. I will upload one more screenshot showing the issue and try to compile it locally to see if the problem remains. Cheers~!
    – JC Y
    Commented Jun 26, 2023 at 3:48
  • Ahhh, I see what you mean now. When I add a \footnote at the very end of your example code, I also see the footnote text appearing on a mystery blank page. Perhaps you could edit the code in your question by adding a \footnote there so that others will see that when they compile your code.
    – gz839918
    Commented Jun 26, 2023 at 4:58
  • Thank you for the suggestion, @gz839918. I've added the footnote in the question.
    – JC Y
    Commented Jun 26, 2023 at 5:52
  • the newest version of the class no longer redefines \document and \enddocument. So the \let\latexdocument\document stuff is unneeded. Apart from this: the \starttwocolumn command is obviously broken. Make a minimal example (class + text\footnote{some footnote.}\starttwocolumn text is quite enough) and report that to the class maintainer. They should either switch to multicols or at least study its code before starting to change or use core LaTeX commands like \@outputpage and \output. It doesn't make sense to build here an archive of answers with work arounds. Commented Jun 26, 2023 at 7:38

1 Answer 1


To fix your issue, you'll want to delete \starttwocolumn before the bibliography. Then, insert the following code into your preamble:


(Inspired by a previous question.) This should unravel your mystery page problem.

The culprit behind the mystery

The code above is all you need to solve the problem. However, if you're curious to dive deeper into the details about why the clv3 class failed to handle footnotes when they appeared immediately before the bibliography, the culprit is \starttwocolumn, which is a custom-defined macro in the clv3 class for creating a two-column bibliography. Inside the clv3 class file, it's defined as


What does this code actually do? First, it creates a new box called \partialpage. When the macro \starttwocolumn is called, TeX performs something known as an output routine, which is how TeX knows how much stuff to insert onto a page before breaking the page. All this stuff is stored in a special box numbered \box255.

I'm pretty fuzzy on the details of how this works myself, but it seems that TeX takes all the text on the page before it ends (\newpage), unpacks it and repacks it (\vbox{\unvbox255}), then saves it into \partialpage. By the end of the \output routine, box 255 is emptied. However, the contents of footnotes are not saved into \partialpage because LaTeX typesets footnotes after the page is built. As a result, the footnote gets typeset like normal onto an otherwise empty page. Because \twocolumn unboxes \partialpage on the following page, everything that would have been on the previous page is now on the new page. This creates the impression that an entire page was skipped except for a footnote.

  • Thank you so much @gz839918! I tried this both in the manuscript and the test file. The footnotes in both files are in their correction positions now and the unexpected blank page before the final page have disappeared. Unfortunately, both PDF files now include a final blank page at the end (after the final page). I don't know if there is a way to get rid of them too. Anyway, this has already been great improvement.
    – JC Y
    Commented Jun 26, 2023 at 7:50
  • FYI, the compilation gave the following message: Package multicol Warning: I moved some lines to the next page. Footnotes on page 53 might be wrong on input line 89.
    – JC Y
    Commented Jun 26, 2023 at 7:59
  • @JCY The new, blank page after the bibliography is actually unrelated to the footnote issue. (If you comment out the footnote, the extra page still persists.) This occurs because \AtEndDocument is inserting a \clearpage right before the end of the document. If you delete \AtEndDocument{...} from your preamble, that will remove the new page after the bibliography.
    – gz839918
    Commented Jun 26, 2023 at 8:01
  • As for your second comment, does the footnote continue to appear on the wrong page? If so, let me know and I'll do my best to edit my answer to help.
    – gz839918
    Commented Jun 26, 2023 at 8:03
  • The footnotes are in their right positions :-) The blank page after the final page is the only problem now. Thank you so much for your time and effort!
    – JC Y
    Commented Jun 26, 2023 at 8:06

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .