1

I want to include a figure from Pdf file to a LaTeX document, which I have done before by using

 \includegraphics{42.pdf}

But today I want to write a paper using latex so I change my document class to

\documentclass[twoside]{article}

then I try to add Pdf figure, then the problem stat, when I try compiling this the document compiles and there is no error in the code, but no figure shows up in Pdf

here is my code

   \documentclass[twoside]{article}
\usepackage{authblk}
\usepackage{graphicx}
\usepackage{caption}
\usepackage{titletoc}
\usepackage[sc]{mathpazo}
\usepackage[T1]{fontenc}
\usepackage[hmarginratio=1:1,top=32mm,columnsep=20pt]{geometry}
\usepackage[font=it]{caption}
\usepackage{multicol}
\usepackage{lettrine}
\usepackage{abstract}
    \renewcommand{\abstractnamefont}{\normalfont\bfseries}
    \renewcommand{\abstracttextfont}{\normalfont\small\itshape}
\usepackage{titlesec}

\title{\vspace{-15mm}
\fontsize{24pt}{8pt}\selectfont
\textbf{Test latex file}}   
\author[1,*]{Andreas}
\author[2,**]{Lulu}

\affil[1]{\normalsize Department of Physics and Astronomy, College of Science}
\affil[2]{\normalsize Department of Physics, College of Science}
\affil[*,**]{a@gmail.com ,s@gmail.com}
\vspace{-5mm}
\date{May 2015}



%%%%%%%%%%%%%%%%%%%%%%%%
\begin{document}

\maketitle


\begin{abstract}
\noindent In quantum optics
\end{abstract}


\begin{multicols}{2}

\section{Introduction} 
test test test 
test test test 
test test test 
test test test 
\begin{figure}[ht]
\centering
\includegraphics[width=8cm]{42.pdf}
\caption{{\protect\footnotesize Test.}}
\end{figure}

\section{Conclusion}
test test test 
test test test 
test test test 
test test test 

\end{multicols}

\end{document}
lulu
  • 11
  • 4
    you haven't really given any information that would allow anyone to help you. make a small, complete, example without all those unrelated packages that shows the problem and post the complete file and the log that you get. Unrelated but you never want to load epsfig unless you need to emulate documents from 1985. – David Carlisle Sep 19 '15 at 20:49
  • 3
    Please read the manual to the multicol package, it does not support floats, so no figure. This has nothing to do with twoside. – daleif Sep 19 '15 at 20:49
  • @DavidCarlisle sorry I always put all the packages that maybe I will need them, anyway I try to shortcut the code – lulu Sep 19 '15 at 21:10
  • @daleif oh, Is there anther way to replace multicol package without changing the page design ? – lulu Sep 19 '15 at 21:18
  • 1
    Not really. Just take a look at the documentation for information about handling floats. But the reason they are incompatible is because the package is trying to solve quite a difficult problem. It isn't an arbitrary whim on the part of the package's creator. So the problem is that any similar package would encounter similar difficulties. – cfr Sep 19 '15 at 21:34

0 Answers0