A number of free guides to LaTeX are available. Two of the most useful are

Install

Mac Install Latex: MacTex

MiKTeX is a distribution of the TeX/LaTeX typesetting system for Microsoft Windows. It also contains a set of related programs. MiKTeX provides the tools necessary to prepare documents using the TeX/LaTeX markup language, as well as a simple tex editor: TeXworks. The name comes from Christian Schenk’s login: MiK for Micro-Kid.

Files

style file: .bst reference file: .bib

Document Structure

Elsevier Latex Template

Preamble

% simple.tex - A simple article to illustrate document structure.

\documentclass{article}
% do not use \documentclass[authoryear]{elsarticle}, it will generate some error in references. I don't know why. see [StackExchange](https://tex.stackexchange.com/questions/54480/package-natbib-error-bibliography-not-compatible-with-author-year-citations)
\usepackage{times}

\begin{document}

Title

\title{This is the title}

Author

\author{Author Name\corref{cor1}%
 \fnref{fn1}}
\ead{xmhuang6-c@my.cityu.edu.hk}

\author{Author Name}

\author{Author Name}

\address{Department of Information Systems, City University of Hong Kong, Tat Chee Avenue,  Kowloon, Hong Kong}

Abstract

\begin{abstract}

This is abstract.

\end{abstract}

Keywords

\begin{keyword}

keyword1 \sep keyword12 \sep keyword13

\end{keyword}

Sections

\section{Introduction}

This is Introduction

\section{Literature Review}

\subsection{Subsection1}

\subsection{Subsection2}

\section*{A Title Without Numbers}
Command Level
\part{part} -1
\chapter{chapter} 0
\section{section} 1
\subsection{subsection} 2
\subsubsection{subsubsection} 3
\paragraph{paragraph} 4
\subparagraph{subparagraph} 5

Table

Reference

One Way

\begin{thebibliography}{9}

	\bibitem{lamport94}
	  Leslie Lamport,
	  \emph{\LaTeX: A Document Preparation System}.
	  Addison Wesley, Massachusetts,
	  2nd Edition,
	  1994.

\end{thebibliography}

Another Way

  1. latex paper (doesn’t require .tex extension)
  2. bibtex paper (doesn’t require .bib extension)
  3. latex paper
  4. latex paper
    \section*{References}
    \bibliography{mybibfile}
    
Citation command Natbib output
\citet{goossens93} Goossens et al. (1993)
\citep{goossens93} (Goossens et al., 1993)
\citet*{goossens93} Goossens, Mittlebach, and Samarin (1993)
\citep*{goossens93} (Goossens, Mittlebach, and Samarin, 1993)