My MWE is below. I have included all the packages, incase its a package interaction issue.
Code: Select all
%% This is file `elsarticle-template-2-harv.tex',
%%
%% Copyright 2009 Elsevier Ltd
%%
%% This file is part of the 'Elsarticle Bundle'.
%% ---------------------------------------------
%%
%% It may be distributed under the conditions of the LaTeX Project Public
%% License, either version 1.2 of this license or (at your option) any
%% later version. The latest version of this license is in
%% http://www.latex-project.org/lppl.txt
%% and version 1.2 or later is part of all distributions of LaTeX
%% version 1999/12/01 or later.
%%
%% The list of all files belonging to the 'Elsarticle Bundle' is
%% given in the file `manifest.txt'.
%%
%% Template article for Elsevier's document class `elsarticle'
%% with harvard style bibliographic references
%%
%% $Id: elsarticle-template-2-harv.tex 155 2009-10-08 05:35:05Z rishi $
%% $URL: http://lenova.river-valley.com/svn/elsbst/trunk/elsarticle-template-2-harv.tex $
%%
%\documentclass[preprint,authoryear,8pt]{elsarticle}
%% Use the option review to obtain double line spacing
%% \documentclass[authoryear,preprint,review,12pt]{elsarticle}
%% Use the options 1p,twocolumn; 3p; 3p,twocolumn; 5p; or 5p,twocolumn
%% for a journal layout:
% \documentclass[final,authoryear,1p,times]{elsarticle}
%% \documentclass[final,authoryear,1p,times,twocolumn]{elsarticle}
\documentclass[final,authoryear,3p,times,twocolumn]{elsarticle}
%% \documentclass[final,authoryear,3p,times,twocolumn]{elsarticle}
%% \documentclass[final,authoryear,5p,times]{elsarticle}
%% \documentclass[final,authoryear,5p,times,twocolumn]{elsarticle}
%% if you use PostScript figures in your article
%% use the graphics package for simple commands
%% \usepackage{graphics}
%% or use the graphicx package for more complicated commands
%% \usepackage{graphicx}
%% or use the epsfig package if you prefer to use the old commands
%% \usepackage{epsfig}
%% The amssymb package provides various useful mathematical symbols
\usepackage{amssymb}
%% The amsthm package provides extended theorem environments
%% \usepackage{amsthm}
%% The lineno packages adds line numbers. Start line numbering with
%% \begin{linenumbers}, end it with \end{linenumbers}. Or switch it on
%% for the whole article with \linenumbers after \end{frontmatter}.
%% \usepackage{lineno}
%% natbib.sty is loaded by default. However, natbib options can be
%% provided with \biboptions{...} command. Following options are
%% valid:
%% round - round parentheses are used (default)
%% square - square brackets are used [option]
%% curly - curly braces are used {option}
%% angle - angle brackets are used <option>
%% semicolon - multiple citations separated by semi-colon (default)
%% colon - same as semicolon, an earlier confusion
%% comma - separated by comma
%% authoryear - selects author-year citations (default)
%% numbers- selects numerical citations
%% super - numerical citations as superscripts
%% sort - sorts multiple citations according to order in ref. list
%% sort&compress - like sort, but also compresses numerical citations
%% compress - compresses without sorting
%% longnamesfirst - makes first citation full author list
%%
%% \biboptions{longnamesfirst,comma}
% \biboptions{}
%%%%%%%%%%%
\usepackage[T1]{fontenc}
\usepackage{prettyref}
\usepackage{url}
\usepackage{amsmath}
\usepackage{graphicx}
\usepackage{amssymb}
\usepackage{mathtools}
\usepackage{xcolor}
\usepackage{amsfonts}
\usepackage{nicefrac}
\usepackage{capt-of}
\usepackage{algorithm}
\usepackage{algorithmic}
\usepackage{float}
\usepackage{xspace}
\usepackage{algorithmwh}
\usepackage{verbatim}
\usepackage{mathdots}
\usepackage{bm}
\usepackage{amsmath,amssymb}
% for GNUMERIC
%\usepackage{ucs}
%%\usepackage{utf8}{inputenc}
%\usepackage[latin1]{inputenc}
\usepackage{array}
%\newcommand{\head}[2]{\multicolumn{1}{>{\centering\arraybackslash}p{#1}|}{\textbf{#2}}}
\newcommand{\head}[1]{\textbf{#1}}
\newcolumntype{C}[1]{>{\centering\arraybackslash}p{#1}}
\usepackage{amsfonts}
\newcommand{\tickYes}{\checkmark}
\usepackage{pifont}
\newcommand{\tickNo}{\hspace{1pt}\ding{55}}
\usepackage{graphicx}
\usepackage{caption}
\usepackage{subcaption}
\usepackage{rotating} %table in landscape
\usepackage{color}
\usepackage{array}
\usepackage{longtable}
\usepackage{calc}
\usepackage{multirow}
\usepackage{hhline}
\usepackage[framed,numbered]{mcode}
\usepackage{ifthen}
\usepackage{lscape}
\def\inputGnumericTable{}
\makeatletter
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% LyX specific LaTeX commands.
\newcommand{\lyxline}[1][1pt]{%
\par\noindent%
\rule[.5ex]{\linewidth}{#1}\par}
\newcommand{\noun}[1]{\textsc{#1}}
%% Because html converters don't know tabularnewline
\providecommand{\tabularnewline}{\\}
%%%%%%%%%HUGHs MACROS%%%%%%%%%%%%%%%%%%%%%%%%%%%
%\newcommand{\argmax}{\operatornamewithlimits{argmax}}
%\newcommand{\max}{\operatornamewithlimits{max}}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% User specified LaTeX commands.
\newcommand{\x}{\mathrm{x}}
%\newcommand{\bx}{\bm{\x}}
\newcommand{\z}{\mathrm{z}}
\newcommand{\bz}{\bm{\z}}
\newcommand{\ert}[1]{\emph{\textcolor{red}{#1}}}
\newcommand{\cn}{\textcolor{blue}{$^{[\text{\emph{citation needed}}]}$}}
\newcommand{\todo}[1]{\textcolor{red}{[TO DO: {#1}]}}
\newcommand{\draft}[1]{\textcolor{blue}{[DRAFT: {#1}]}}
\newcommand{\checkme}[1]{\textcolor{Maroon}{{#1} (check!)}}
\newcommand{\maybe}[1]{\textcolor{OliveGreen}{Maybe: {#1} (?)}}
\newcommand{\expect}[1]{\mathbb{E}\left({#1}\right)}
\newcommand{\expectnb}[1]{\mathbb{E}\text{ }{#1}}
\newcommand{\cov}{\text{cov}}
\newcommand{\st}{\textsuperscript{st}\ }
\newcommand{\nd}{\textsuperscript{nd}\ }
\newcommand{\rd}{\textsuperscript{rd}\ }
\newcommand{\thh}{\textsuperscript{th}\ }
\newcommand{\ith}{$i$\thh}
\usepackage{cite}
\usepackage{lettrine}
\usepackage[active]{srcltx}
\newrefformat{tab}{Table \ref{#1}}
\newrefformat{fig}{Fig. \ref{#1}}
\makeatother
\usepackage{hyperref} %this needs to go last because of package interaction
%%%%%%%%%%%%%
\begin{document}
\begin{frontmatter}
\begin{figure}[H]
\begin{center}
{\includegraphics[width=3.5in,keepaspectratio]{images/blah}}
\caption{blah}
\label{blah}
\end{center}
\end{figure}
\end{document}