[Tex/LaTex] Bibtex problem: It doesn’t always work


My BibTeX just does not work after a certain citation. After this citation, every one is a question mark.

 author = {J.G.Proakis},
 title = {Digital Transmission},
 year = {2001},
 publisher = {McGraw-Hill},

And LaTeX also gives error messages.

*Command \c@lofdepth already defined.
 You requested the `dvips' driver but I think that(crop) the `pdftex' driver works better in the current(crop) context. You can force me to respect your decision(crop) by adding an exclamation point as in [dvips!].
 Font shape `T1/cmss/m/n' in size <40> not available(Font) size <35.83> substituted on input line 52. Font shape `T1/cmss/m/n' in size <40> not available(Font) size <35.83> substituted
 Citation `niklas' on page 9 undefined on input line 310. Citation `niklas' on page 9 undefined
 There were undefined citations.
 Size substitutions with differences(Font) up to 4.17pt have occurred.*

I am going crazy with those errors. When BibTeX does work, LaTeX compiles without those errors.

here is my code

%%% Title page
\Title{A Test of \texttt{Exjobb.cls}}
\Author{Stefan Höst\\\texttt{stefan}}
\Advisor{Stefan Höst}
%%%%% Page numbering for front pages
%%%%% Abstract

%% ToC
%%%%% Page numbering for the main thesis





In the code I cite three references. Only last one works.
My reference.bib is.

author={Zou, W.Y. and Yiyan Wu}, 
journal={Broadcasting, IEEE Transactions on}, title={COFDM: an overview}, 
pages={1 -8}, 
keywords={8-VSB;ACATS;ATV channel model;Advisory Committee on Advanced Television Service;COFDM;Europe;FCC;OFDM;QAM;USA;channel coding;coded OFDM;development;digital audio broadcasting;digital modulation;digital television broadcasting;history;imperfect channel conditions;orthogonal frequency division multiplexing;performance;research;terrestrial HDTV broadcasting;channel coding;digital television;encoding;frequency division multiplexing;high definition television;quadrature amplitude modulation;reviews;television broadcasting;}, 

author={Bingham, J.A.C.}, 
journal={Communications Magazine, IEEE}, title={Multicarrier modulation for data transmission: an idea whose time has come}, 
month={may }, 
pages={5 -14}, 
keywords={channel impairments;coding;data transmission;duplex operation;frequency division multiplexing;general switched telephone network;multicarrier modulation;undistorted channel;data communication systems;encoding;frequency division multiplexing;modulation;}, 

author={Merchan, S. and Armada, A.G. and Garcia, J.L.}, 
journal={Broadcasting, IEEE Transactions on}, title={OFDM performance in amplifier nonlinearity}, 
pages={106 -114}, 
keywords={16QAM;ACTS project;BER degradation;Europe;OFDM performance;OFDM signals;QPSK;RACE project;Signal Processing Worksystem simulator;additive Gaussian noise;amplifier nonlinearity;amplitude clipping;amplitude limiting;bandwidth;bit error rate;digital TV broadcasting;impulsive noise;multipath effects;nonlinear distortion;optimized output power back off;orthogonal frequency division multiplexing;power amplifier efficiency;Gaussian noise;coding errors;digital television;error statistics;frequency division multiplexing;multipath channels;quadrature amplitude modulation;quadrature phase shift keying;radiofrequency amplifiers;television broadcasting;}, 

Best Answer

The problem is not with the bib file. As mico says, there is a missing comma: if you looked at the log file you would see it reported. But that is not the problem.

The problem, I think, is that the custom class you are loading loads tocloft, and you load subfigure. As it happens there is a conflict, because both attempt to define the same counter. This is no problem normally, because tocloft checks if subfigure is being used: but not vice versa, and since your class loads tocloft first, it's going wrong. The solution, I think, will be to edit your class file to load subfigure before tocloft, and to load tocloft with the subfigure option.

The reason you were seeing question-marks instead of citations was that you were being put off by the error and only running latex once, so the citation marks hadn't resolved themselves. In fact if you pressed on despite the error (not a good idea) you would have got citations: the problem had nothing to do with your bibtex.

I hope it's not too harsh to say that this does demonstrate the importance of reading logs and posting MWEs.

Related Question