I am compiling my thesis where I have a rootfile and each chapter is read in with \include{chapterfolder/chaptername}. Everything works but the references, they are all undefinded. When I run BibTex however, the process goes through without errors ("Process exited normally").
I have tried putting everything, i.e. chaptername.tex and chapterbibfile.bib, in the same folder as the rootfile instead of a subfolder, but the result is the same.
Strange enough I had an old version of this document for the research proposal, where referencing worked (exactly 2 years ago). I am using TeXLive-2015 on a MacBook Pro.
Help is highly appreciated, thank you.
Here's my rootfile:
\documentclass{report}
%\usepackage{etex}
%\reserveinserts{28}
% the latter two are due to the "no-room-for-a-new-dimen" problem, which is discussed and resolved here: http://tex.stackexchange.com/questions/38607/no-room-for-a-new-dimen
% in my case, I had too many packages, and these two lines solve the trick
%\onehalfspacing
\usepackage{atbegshi}% http://ctan.org/pkg/atbegshi THIS REMOVES THE ODD EMPTY PAGE BEFORE THE TITLEPAGE, WHICH ONLY APPEARED WHEN I CHANGED FONT TO 12 PT
\AtBeginDocument{\AtBeginShipoutNext{\AtBeginShipoutDiscard}}
\input{preamble}
\title{
\begin{center}
\begin{large}
University of Neverland\\[0.3cm]
Address line 1\\
Address line 2\\
City\\[1cm]
\end{large}
\begin{huge}
Three Essays on the Economics of \\
Fairy Tales\\
\end{huge}
\vspace{0.5cm}
{\Large \textit{Thesis in the Doctoral Program \\
of Fairy Tale Studies}}\\[1.4cm]
\begin{large}
Supervisor\\
Peter Pan\\[0.3cm]
Co-Supervisor\\
Cinderella\\[0.3cm]
External Referee\\
Snow White\\
\end{large}
\end{center}}
\author{\vspace{1cm}\\
\vspace{0.3cm}Arielle \\
Under the Sea\\
Far Far Away\\
arielle@ocean.com\\
Student ID: 00-000-000}
\date{\vspace{1cm} \today}
\begin{document}
\pagenumbering{gobble} %this eliminates the page on the first page, \thispagestyle{empty} somehow did not work here..
%% my document content
\clearpage\maketitle
\afterpage{\blankpage}
\pagebreak
%% %% %% %% TOC PAGE %% %% %% %%
\setcounter{page}{1}
\fontsize{12}{18}\selectfont
\pagestyle{plain}
\pagenumbering{roman}
\setcounter{tocdepth}{1}
\renewcommand{\contentsname}{Table of Contents} % Changes the default
\tableofcontents
%% %% %% %% TOC PAGE %% %% %% %%
\pagebreak
% SUMMARY
%\include{./preface_summary/summary}
%%% %%% %%% CONTENT / CHAPTERS %%% %%% %%%
\pagebreak
\setcounter{page}{1}
\pagestyle{plain}
\pagenumbering{arabic}
\include{Chapter1_test}
\pagebreak
\include{Chapter2_test}
\pagebreak
\end{document}
My chapter 1 looks like this:
% This is Chapter1_test.tex
%%%%%%% THIS IS FOR THE THESIS VERSION %%%%%%%
\renewcommand{\thefootnote}{\fnsymbol{footnote}} %creates symbol footnotes, which I need for the aknowledgements.
\chapter{This is the First Chapter}
\begin{Large}
\textit{Peter Pan and Arielle}\footnote{We thank Tinkerbell.}
\end{Large}
\bigskip
\renewcommand{\thefootnote}{\arabic{footnote}} \setcounter{footnote}{0} % and this sets footnote nubering back to normal, starting with 1 =)
\fontsize{12}{18}\selectfont
\section{Introduction}
\label{Introduction 1}
This is the intro of the first chapter. Here I cite \cite{Piketty2001} and \cite{Piketty2014capital}
\pagebreak
\addcontentsline{toc}{section}{References}
%\singlespacing
\renewcommand{\bibname}{References} % Changes the default 'Bibliography' into 'References'
\footnotesize
\bibliographystyle{apecon}
\bibliography{myref_chap1}
Chapter 2:
% This is Chapter2_test.tex
%%%%%%% THIS IS FOR THE THESIS VERSION %%%%%%%
\renewcommand{\thefootnote}{\fnsymbol{footnote}} %creates symbol footnotes, which I need for the aknowledgements.
\chapter{This is the Second Chapter}
\begin{Large}
\textit{Arielle}\footnote{I thank Sebastian.}
\end{Large}
\bigskip
\renewcommand{\thefootnote}{\arabic{footnote}} \setcounter{footnote}{0} % and this sets footnote nubering back to normal, starting with 1 =)
\fontsize{12}{18}\selectfont
\section{Introduction}
\label{Introduction 2}
This is the intro of the second chapter. Here I cite \cite{YoungVarner2011} and \cite{Tiebout1956}
\pagebreak
\addcontentsline{toc}{section}{References}
%\singlespacing
\renewcommand{\bibname}{References} % Changes the default 'Bibliography' into 'References'
\footnotesize
\bibliographystyle{apecon}
\bibliography{myref_chap2}
The Preamble:
% This is preamble.tex
% % % THIS IS MY GENERAL PREAMBLE FILE % % %
\usepackage[ansinew]{inputenc}
\usepackage{threeparttable}
\usepackage{fancyhdr}
\usepackage{color}
\usepackage{apacite}
\usepackage[sectionbib]{natbib}
\usepackage{chapterbib}
\usepackage{graphicx}
\usepackage{csvsimple}
\usepackage{subfig}
\usepackage{amsmath}
\usepackage{amssymb}
\usepackage{booktabs}
\usepackage{multirow}
\usepackage{longtable}
\usepackage{appendix}
\usepackage{graphpap}
\usepackage{setspace}
\usepackage{amsfonts}
\usepackage{breqn}
\usepackage{floatrow}
\usepackage{url}
\usepackage[english]{babel}
\usepackage{pdflscape}
\usepackage{afterpage}
\usepackage{capt-of}
\usepackage{lipsum}
\usepackage{comment}
\usepackage{setspace}
\usepackage{here}
\usepackage[applemac]{inputenx}
\usepackage[T1]{fontenc}
\usepackage[colorlinks, linkcolor = black, citecolor = black, filecolor = black, urlcolor = blue]{hyperref}
\usepackage[left=3.5cm,top=3cm,right=3.5cm]{geometry} % This sets the margins
\usepackage[bottom]{footmisc} % This makes sure footnotes are at the bootom of the page.
\usepackage{float}
\floatstyle{plaintop}
\restylefloat{table}
% these three lines put table caption at the top of the table
%\usepackage[tableposition=top]{caption}
\def\citeapos#1{\citeauthor{#1}'s (\citeyear{#1})} % This creates a command for citations with apostrophes.
\def\citeay#1{\citeauthor{#1}, \citeyear{#1}} % This creates a command for Author, year.
%\def\citepnob[#1]#2{\citeauthor{#2},(\citeyear{#2},#1)
\renewcommand{\&}{and}
%% This is to have Chapter names split in Title and Subtitle
%%\newcommand{\Chapter}[2]{\chapter[#1]{#1\\[1ex]\huge#2}}
\newcommand\Chapter[2]{\chapter
[#1\hfil\hbox{}\protect\linebreak{\itshape#2}]%
{#1\\[1ex]\huge#2}%
}
\hbadness=10000
\hfuzz=50pt
\makeatletter
\newcommand\resetsubfigs{\setcounter{sub\@captype}{0}}
\makeatother
\newcommand\blankpage{%
\null
\thispagestyle{empty}%
\addtocounter{page}{-1}%
\newpage}
%% to insert a blank page in the text, use: \afterpage{\blankpage}
The two bib files:
% This is myref_chap1.bib
@book{Piketty2001,
Address = {Paris},
Author = {Piketty, Thomas},
Publisher = {Bernard Grasset},
Title = {{Les hauts revenus en France au XXe si\`{e}cle. In\'{e}galit\'{e}s et redistributions 1901--1998}},
Year = {2001}
}
@book{Piketty2014capital,
title={Capital in the 21st Century},
author={Piketty, Thomas},
publisher={Harvard University Press, Cambridge},
year={2014}
}
The second bib file for the second chapter
% This is myref_chap2.bib
@article{YoungVarner2011,
Author = {Young, Cristobal and Varner, Charles},
Journal = {National Tax Journal},
Month = jun,
Number = {2},
Pages = {255--284},
Title = {{Millionaire Migration and State Taxation of Top Incomes: Evidence From a Natural Experiment}},
Volume = {64},
Year = {2011}
}
@article{Tiebout1956,
Author = {Tiebout, Charles M.},
Journal = {Journal of Political Economy},
Number = {5},
Pages = {416--424},
Title = {{A Pure Theory of Local Expenditures}},
Volume = {64},
Year = {1956}
}
\bibliography{./chapterfolder/chapterbib.bib}, then BibTeX will look for a file calledchapterfolder/chapterbib.bib.bib, and I doubt any file you have actually ends with.bib.bib. Better:\bibliography{./chapterfolder/chapterbib}. Better still: don't sneak pathnames into\inputand\includecommands (though that's not likely the problem here). – jon Feb 03 '16 at 04:33\includes. However, the point about the accidental way your\inputs and\includes work still stands.) I think we're going to need to see the.logon this one. – jon Feb 03 '16 at 05:50preamble.texthat are unrelated to the problem; or (2) if the files posted here do not reproduce the problem, then you need to revise them so that they do. Otherwise, it often turns out that no one can help you. As as aside, although they are called minimal working examples, this does not indicate that creating the MWE requires only a minimal investment of time. – jon Feb 05 '16 at 02:44