[Tex/LaTex] How to insert a JPEG picture using LaTeX

errorsjpeg

I try to insert a picture using the code below

\usepackage{pgf}

\begin{figure}[h]
\centering
\includegraphics[width=2.5in]{image/Test}
\caption{Example TA}
\label{fig:Reinforcement}
\end{figure}

However, the error says Missing $ inserted; may someone help me?

Best Answer

To end this I include here a complete MWE that compiles without errors (notice, that the used figure is part of package MWE you should have installed but must not be loaded). It contains everything needed to print a figure in LaTeX:

\documentclass{article}
\usepackage{graphicx}

\begin{document}

\begin{figure}%                 use [hb] only if necceccary!
  \centering
  \includegraphics[width=10cm]{example-image-a}
  \caption{test figure}
  \label{fig:test}
\end{figure}

\end{document}