Skip to content

Instantly share code, notes, and snippets.

@dinigo
Last active June 27, 2018 14:10
Show Gist options
  • Save dinigo/4548172 to your computer and use it in GitHub Desktop.
Save dinigo/4548172 to your computer and use it in GitHub Desktop.
LaTeX template for IEEEtrans package. I use it for assignments at college.
% -*-coding: utf-8 -*-
% You MUST redefine margins before \documentclass{IEEEtran}
\newcommand{\CLASSINPUTinnersidemargin}{18mm}
\newcommand{\CLASSINPUToutersidemargin}{12mm}
\newcommand{\CLASSINPUTtoptextmargin}{20mm}
\newcommand{\CLASSINPUTbottomtextmargin}{25mm}
\documentclass[10pt,conference,a4paper]{IEEEtran}%
% Using "no-tilde" option with babel package solves a compilation
% error when using more than 100 characters on float's captions.
\usepackage[spanish,es-nosectiondot,es-tabla,es-nolists,es-notilde]{babel}
%\usepackage[spanish,es-nosectiondot,es-tabla,es-nolists]{babel}
% Requiere spanish.ldf para babel versión >= 5.0 (feb 2007) Versiones anteriores
% interfieren con IEEEtran, especialmente en el formato de los títulos de
% section y subsection, por lo que se recomienda no utilizarlas. Si aun así
% se utilizan, comentar la lí­nea anterior y descomentar la siguiente
%\usepackage[spanish]{babel}
% Intenta corregir los efectos indeseados de babel
\renewcommand{\thesubsection}{\Alph{subsection}}
\renewcommand{\thesubsubsection}{\arabic{subsubsection}}
\addto\extrasspanish{\def\tablename{Tabla}}
\addto\extrasspanish{\def\figurename{Fig.}}
% For english version, comment or delete all the lines above up to documentclass
\usepackage[utf8x]{inputenc}
% For codification latin1 (ISO 8859-1) instead of UTF-8.
% Comment the line above and uncomment the line below:
%\usepackage[latin1]{inputenc}
\usepackage{amsmath,amsfonts,amssymb}
\usepackage{times}
\usepackage{graphicx}
\usepackage{url}
% Prevents floats from appearing in secctions in which they werent declared
%\usepackage[above,below]{placeins}
% Other usefull Packages
%\usepackage[caption=false]{subfig} % Subfigures (parametter required).
%\usepackage{colortbl} % Colored tables.
%\usepackage{multirow} % Vertical joined cell tables.
%\usepackage{cite} % Compact refference lists.
%\usepackage{pstool} % Generates .ps or .pdf from psfrag
\DeclareGraphicsExtensions{.png,.eps,.ps,.pdf,.jpg}
% Hack para corregir las cabeceras de tablas de IEEEtran. Con esto figuras y tablas
% tienen el mismo formato.
\makeatletter \def\@IEEEtablestring{} \makeatother
% --------------------------------------------------------------------------------
% Content Starts Here
% --------------------------------------------------------------------------------
\title{Former Title}
\author{%
\IEEEauthorblockN{Surame1, Name1; Surname2, Name2}
\IEEEauthorblockA{mailaddress1@server.com, mailaddress2@server.com}
\IEEEauthorblockA{Working group}
}
\begin{document}
\maketitle
% The abstract, sections and subsections don't need to be closed.
\begin{abstract}
Here's where you place the "abstract"
\end{abstract}
\section{Development}
\subsection{Part1 1}
Here it is some text and a reference to Fig. ~\ref{fig:1}.
% using `\centering` works better with the vertical space when using floats.
\begin{figure}[htb]
\centering
\includegraphics[width=\columnwidth]{folder/file.eps}
\caption{This is the caption text}
\label{fig:graph}
\end{figure}
\begin{table}[htb]
\renewcommand{\arraystretch}{1.2}
\centering
% Number of cells must be declared when opening the table and so the separator.
\begin{tabular}{|c|c|c|c|c|}
\hline
$\theta $ & I2 & I3 & DBF & DBQ \\
% Using double horizontal line to separate the title cells from the data ones.
\hline
\hline
$0 \deg $ & ON & ON & DBF & DBQ \\
\hline
$90 \deg $ & ON & OFF & -DBQ & -DBF \\
\hline
$180 \deg$ & OFF & ON & -DBF & -DBQ \\
\hline
$270 \deg$ & OFF & OFF & DBQ & -DBF \\
\hline
\end{tabular}
\caption{This is the table caption with apears below it.}
\label{tbl:phase}
\end{table}
\subsection{Part1 2}
More text
\subsection{Part1 3}
Some more text
% Those four fields are often optional so you are free to include them in the "Developement" secction.
\section{Equations}
\section{Grapsh}
\section{Results}
\section{Conclussions}
% The following is a bullet list
\begin{itemize}
\item This is the first conclusion.
\item This is the second conclusion.
\item This is the third conclusion.
\end{itemize}
\begin{thebibliography}{2}
\bibitem{ref:strange_book}
Editor, \emph{This is the title of the book} 2008.
\bibitem{ref:strange_article}
Editor, \emph{This is the title of the book} 2008.
\end{thebibliography}
\end{document}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment