
В настоящее время я пишу свою диссертацию и хочу иметь полностью готовый шаблон, чтобы просто сосредоточиться на письме. Моя проблема в том, что мне нужно использовать стиль IEEE для размещения ссылок в моем документе, и у меня возникают проблемы с достижением этого. Я видел несколько видео, объясняющих это с помощью файла bibtext, но когда я пытаюсь это сделать, это вообще не работает. Кстати, у меня есть файл bibtext с некоторыми уже записанными ссылками под названием biblio_MT. Кроме того, я хочу добавить новую главу в документ и сделать на нее ссылку в оглавлении. Новая глава должна называться «Anexos», этого я тоже не смог добиться. Мой код следующий:
\documentclass[letterpaper,openright,12pt]{report}
\usepackage[spanish]{babel} %Defino idioma como español
\usepackage{graphicx} % Para Añadir imagenes
\usepackage{subfigure} %Para las subfiguras
\usepackage{caption}
\usepackage[spanish]{babel}
\selectlanguage{spanish}
\usepackage[utf8]{inputenc}
\usepackage[usenames, dvipsnames]{color}
%\usepackage{hyperref} % Para que el pdf referencie directamente las referencias
\usepackage{amssymb,amsmath,amsfonts} %para \textbf y otras cosas
\usepackage{setspace} %sirve para espaciado del documento entre otras cosas
\usepackage{dsfont}% para conjunto entero, reales.
\usepackage{stackrel}%paquete matematico para algunos simbolos
\usepackage{comment}
\usepackage{natbib}
\usepackage{float}
\usepackage[utf8]{inputenc}
\usepackage{enumerate} % enumerados
\usepackage{hyperref}
%\usepackage[latin1]{inputenc}
%\usepackage[sort&compress]{natbib}
%%%%%%%%% TABLAS %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\usepackage{longtable}
\usepackage{multirow} % para las tablas
\usepackage{multicol}% Para separar columnas
\usepackage{booktabs}
%\usepackage{babelbib} %para que las referencias esten en español
\usepackage{listings} %Para agregar codigos
\usepackage{algorithm} %Para escribir pseudocodigos
\usepackage[noend]{algpseudocode} %Para escribir pseudocodigos
%FORMATOS ESPECIFICOS MEMORIA
\setlength{\parindent}{0cm} %0 sangria
\spacing{1.15} %Espaciado
%\usepackage{times} %Letra times new Roman
\usepackage{Helvet}
\usepackage{anysize}% Para definir margenes
\marginsize{2.5cm}{2cm}{2.5cm}{2cm}% Controla los márgenes {izquierda}{derecha}{arriba}{abajo}
% IMAGEN DE FONDO
%La opción pages puede ser all (para todo el documento) o some, para algunas partes del documento
%\usepackage[pages=all]{background}
% configuración
%\%backgroundsetup{
% scale=.2, %escala de la imagen, es recomendable que sea del mismo tamaño que el pdf
% color=black, %fondo a usar para transparencia
% opacity=0.2, %nivel de transparencia
% angle=0, %en caso de querer una rotación
% contents={%
% \includegraphics[width=\paperwidth,height=\paperheight]{Figuras/Logo_Udec.jpg} %nombre de la imagen a utilizar como fondo
% }}
%%Tratando de poner python
\definecolor{mygreen}{rgb}{0,0.6,0}
\definecolor{mygray}{rgb}{0.5,0.5,0.5}
\definecolor{mymauve}{rgb}{0.58,0,0.82}
\lstset{ %
backgroundcolor=\color{white}, % choose the background color
basicstyle=\footnotesize, % size of fonts used for the code
breaklines=true, % automatic line breaking only at whitespace
captionpos=b, % sets the caption-position to bottom
commentstyle=\color{mygreen}, % comment style
escapeinside={\%*}{*)}, % if you want to add LaTeX within your code
keywordstyle=\color{blue}, % keyword style
stringstyle=\color{mymauve}, % string literal style
}
%Formato del titulo de los capitulos
\usepackage{titlesec} %paquete para cambiar el formato de los titulos
\newcommand{\bigrule}{\titlerule[0.5mm]}
{\vspace{-5cm}
\titleformat{\chapter}[display] % cambiamos el formato de los capítulos
{\bfseries\Huge} % por defecto se usarán caracteres de tamaño \Huge en negrita
{% contenido de la etiqueta
%\titlerule % línea horizontal
\filright % texto alineado a la derecha
\Large\chaptertitlename\ % "Capítulo" o "Apéndice" en tamaño \Large en lugar de \Huge
\Large\thechapter} % número de capítulo en tamaño \Large
{0mm} % espacio mínimo entre etiqueta y cuerpo
{\filright} % texto del cuerpo alineado a la derecha
[\vspace{0.5mm} \bigrule] % después del cuerpo, dejar espacio vertical y trazar línea horizontal gruesa
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%Numeracion de paginas en esquina superior derecha
\usepackage{fancyhdr}
% primera pagina de un capitulo
\fancypagestyle{plain}{
\fancyhead[L]{}
\fancyhead[C]{}
\fancyhead[R]{\thepage}
\fancyfoot[L]{}
\fancyfoot[C]{}
\fancyfoot[R]{}
\renewcommand{\headrulewidth}{0pt}
\renewcommand{\footrulewidth}{0pt}
}
\fancyhead[R]{\thepage}
\fancyhead[L]{}
\fancyhead[C]{}
\fancyfoot[L]{}
\fancyfoot[C]{}
\fancyfoot[R]{}
\renewcommand{\headrulewidth}{0 pt}
\pagestyle{fancy}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%\usepackage{hyperref}
\begin{document}
\renewcommand{\contentsname}{Índice General}
\renewcommand{\listfigurename}{Índice de Figuras}
%Redefino algunos casos como tablas, referencias
\renewcommand{\tablename}{Tabla}
\renewcommand{\listtablename}{\'Indice de Tablas}
\renewcommand{\bibname}{ \text{\Large Cap\'itulo 7} \\ Referencias}
%\renewcommand{\bibname}{}
\newcommand{\source}[1]{\caption*{Fuente: {#1}} } % Para poderle añadir la fuente a las figuras
% \NoBgThispage % para evitar el logo udec de fondo en la primera pagina
\begin{titlepage}
\begin{center}
\sffamily{\LARGE \textbf{UNIVERSIDAD DE CONCEPCIÓN}} %\\[-240pt]
\\
\sffamily{\normalsize FACULTAD DE INGENIER\'IA}
\\
\sffamily{\normalsize DEPARTAMENTO DE INGENIER\'IA INDUSTRIAL}
\vfill
%\scalebox{0.37}{\includegraphics{Figuras/Logo_Udec.jpg}} % Para añadir el logo de la escuela
\sffamily{\normalsize \hfill Profesor Patrocinante: $\hspace{2.25cm}$ \\ \hfill \textbf{Maichel M. Aguayo} $\hspace{2.65cm}$ }\\[-35pt]
\scalebox{0.37}{\includegraphics{Logo_Udec.jpg}} % Para añadir el logo de la escuela
\vfill
\sffamily{ \hfill Informe de Memoria de T\'itulo $\hspace{.9cm}$ \\ \hfill Para optar al T\'itulo de: $\hspace{2.165cm}$}\\[-20pt]
\vfill
\sffamily{\normalsize \hfill \textbf{Ingeniero Civil Industrial} $\hspace{1.5cm}$ }\\[50pt]
\vfill
\sffamily{\LARGE Problema de Ruteo de Veh\'iculos con Múltiples Depósitos, Múltiples Productos, Split Delivery y Fixed Destination}\\[100pt]
\end{center}
\vfill
\sffamily{Concepci\'on, Agosto del 2018 \hfill Gonzalo Gálvez Bobadilla}
\newpage
\thispagestyle{empty}
\ \\
\vspace{5cm}
\newpage
\thispagestyle{empty}
\sffamily{UNIVERSIDAD DE CONCEPCI\'ON \hfill Profesor Patrocinante:}\textmd
\\
\sffamily{Facultad de Ingenier\'ia \hfill Maichel M. Aguayo}
\\
\sffamily{Departamento de Ingenier\'ia Industrial}
\vfill
\begin{center}
%\scalebox{0.37}{\includegraphics{IPN.eps}} % Para añadir el logo de la escuela
\vfill
% Genera un espacio
\sffamily{\LARGE Problema de Ruteo de Veh\'iculos con Múltiples Depósitos, Múltiples Productos, Split Delivery y Fixed Destination}\\[60pt]
\vfill
\text{\Large Gonzalo Eduardo Gálvez Bobadilla}
\vfill
\sffamily{Informe de Memoria de T\'itulo \\ Para optar al T\'itulo de}\\[-40pt]
\vfill
\sffamily{\Large{Ingeniero Civil Industrial}}\\[50pt]
\vfill
\sffamily{\Large{Agosto 2018}}\\[10pt]
\end{center}
\end{titlepage}
\newpage
\chapter*{Agradecimientos}
\thispagestyle{empty}
%\setcounter{page}{1}
%\addcontentsline{toc}{chapter}{Agradecimientos}
\begin{quotation}
\thispagestyle{empty}
\noindent \textit{En primer lugar, quiero agradecer a mi madre por todo su amor incondicional y por siempre haberse mantenido firme, incluso en los momentos más difíciles.}\\ \\
\noindent \textit{A mis hermanas, por todo lo que han hecho por mí, que es imposible explicar en palabras.}\\
\noindent \textit{A mi cuñado, por guiarme desde pequeño en el basto mundo de la ingeniería industrial.}\\
\noindent \textit{A mi profesor guía, por todo los conocimientos que me entregó y por jugársela por mí.}\\
\noindent \textit{A mis amigos, por estar siempre ahí, en las buenas y en las malas.}
\end{quotation}
\newpage
\chapter*{Resumen}
\thispagestyle{empty}
%\addcontentsline{toc}{chapter}{Resumen}
\begin{quotation}
El presente trabajo aborda un problema de ruteo de vehículos con múltiples productos, múltiples depósitos, \emph{split delivery} y \emph{fixed destination}. Para este problema se plantea un modelo de programación matemática, el cual fue resuelto en \emph{IBM Cplex Studio IDE 12.7.1} y una heurística diseñada en \emph{Python 3.5}. Se utilizaron instancias de \emph{Coredeaus}, obtenidas desde el sitio web \emph{Networking and Emerging Optimization}, para probar el funcionamiento tanto del modelo como de la heurística. Además de propone una instancia real basada en logística humanitaria, la cual es resuelta con el modelo matemático.\\
Al comparar las soluciones encontradas por el modelo matemático, con las encontradas por la heurística, se observa que esta última encuentra soluciones 13\% peores, sin embargo su tiempo de respuesta es un 98.6\% más rápido. Esto caracteriza a la heurística como un buen método para encontrar soluciones de rápidas.\\
En futuros temas de investigación, se puede analizar la posibilidad de modelar este problema siendo de tipo multi-objetivo, considerando por ejemplo, maximizar la satisfacción de los clientes.
\end{quotation}
\newpage
\pagenumbering{roman}
%\pagenumbering{Roman}
\tableofcontents
\cleardoublepage
\addcontentsline{toc}{chapter}{\'Indice de Figuras} % para que aparezca en el indice de contenidos
\newpage
\listoffigures
\newpage
\cleardoublepage
\addcontentsline{toc}{chapter}{\'Indice de Tablas} % para que aparezca en el indice de contenidos
\listoftables % Genera el Índice de tablas
\newpage
\pagenumbering{arabic}
\chapter{Introducción}
Hola como estas, esto es un test a ver si se pueden inclutir las referencias \cite{varela}
\chapter{Revisión literatura}
%\include{Descripcion_Problema}
\chapter{Modelos matematicos}
\chapter{Heuristica}
\chapter{Resultados}
\chapter{Conclusiones}
\addcontentsline{toc}{chapter}{7.\hspace{0.5cm }Referencias}
\bibliographystyle{IEEEtran}
\bibliography{biblio_MT}
\end{document}
решение1
Этот ответ показывает минимальный код с использованием report
класса (использование других классов, например article
, memoir
, , не так уж сильно отличается). Из этого ответа вы можете в основном узнать, как:
- Создать оглавление
- Создание ссылок для ссылок
- Создавайте цитаты для глав, разделов и т. д.
Код (например, main.tex)
\documentclass{report}
\usepackage[backend=bibtex, style=ieee]{biblatex} % using biblatex with style style=ieee
\addbibresource{reference.bib} % file inside which references are stored
\usepackage[hidelinks, colorlinks=true]{hyperref}
\usepackage{cleveref} % optional for adding suitable perfix to citations of chapters, sections, figures ...etc
%
\begin{document}
%
\tableofcontents % Creating table of contents
%
\chapter{Reference and Citation} \label{ch:reference}
%
\section{Introduction} \label{sec:intro}
In order to cite one reference, you can use cite command like this \cite{Doe_2020}. You can also cite two references like this \cite{Doe_2020,Tenis_2000}.
%
\section{Citing previous sections} \label{sec:citing}
This is to show how to cite previous sections. The references can be found in section \ref{sec:intro}.
\section{Using cleveref package} \label{sec:using}
In section \ref{sec:intro}, you had to write "section" before ref command. Using cleveref, you can cite directly like this \cref{sec:intro} and \cref{sec:citing}. You can even cite two sections directly like this \cref{sec:intro,sec:citing} or even multiple sections in the same time like this \cref{sec:intro,sec:citing,sec:using}.
The same apply for chapters and figures. For example, the first chapter can be cited like this \cref{ch:reference}.
\printbibliography % list of references is printed here
\end{document}
Как вы можете видеть, цитирование разделов, глав, даже рисунков и т. д. связано с созданием, \label{something}
которое после каждого раздела, главы, которые мы хотим процитировать позже. Затем, в месте, где вы хотите добавить ссылку на них, вы просто используете команду \ref{something}
или более продвинутую \cref{something}
.
Главы добавляются командой \chapter{name of chapter}
, и на них автоматически, вместе с разделами, делается ссылка в оглавлении командой \tableofcontents
в нужном месте документа, обычно в начале после заголовка отчета.
Для примера, описанного здесь, вам следует создать bib
файл в той же рабочей папке, которая содержит файл tex с именем reference.bib
и следующим содержимым:
@Book{Doe_2020,
author = {John Doe},
publisher = {John Wiley},
title = {Differential equations : an introduction to modern methods and applications},
year = {2020},
address = {New Jersey},
isbn = {9780471651413},
keywords = {Differential equations},
language = {In English},
}
@Article{Tenis_2000,
author = {Michael Tenis},
journal = {Jounal of Energy},
title = {New article about something},
year = {2000},
month = aug,
number = {7},
pages = {66--88},
volume = {2},
}
Как показано выше, для цитирования ссылок или (библиографии), используемых в основном tex-файле командой \cite{ref-key}
, вам необходимо сначала создать отдельный bib
файл со списком желаемых ссылок, которые вы хотите добавить в свой отчет. Обратите внимание, что существует множество типов ссылок, которые вы можете добавить (например, книга, статья, конференция и т. д.), каждый из которых имеет соответствующий формат типа. Некоторые менеджеры bib могут помочь вам в процессе создания bib-файлов (например,JabRef).
Результат, который вы получите в результате компиляции, будет таким: