You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

272 lines
9.8 KiB

6 years ago
6 years ago
  1. # The ITMorelia Thesis Class
  2. This respository is a sample project of a Thesis using the `itmorelia-thesis-class` with LaTeX. **If you want know what sections should be included and its content visit the *Wiki* of this repository**.
  3. # Repository structure
  4. Below you can see the repository's contents. The repository is made of 27 files and 2 folders. The folder `Chapters` includes each `.tex` file that will be included in your thesis; later you will learn how to included. On the other hand, the folder `FrontBackMatter` includes `.tex` files related with common chapters/section required in the thesis layout: *Titlepage, Abstract, Colophon, Dedication, Glossary, and others*; you can include as much as you need.
  5. In the `root` path, there are files related with the organization and the structure of the **Thesis** (the `thesisStructure.tex` and `precontent.tex` files). Also, in `root` is included the main file that gives the special format to the document (`itmthesis.cls`), and finally the `Reference.bib` file to include a bibliography to your work.
  6. ```bash
  7. .
  8. ├── Chapters
  9. │ ├── A01.tex
  10. │ ├── Chapter01.tex
  11. │ ├── Chapter02.tex
  12. │ └── Chapter0A.tex
  13. ├── configuration.tex
  14. ├── FrontBackMatter
  15. │ ├── Abstract.tex
  16. │ ├── Bibliography.tex
  17. │ ├── Colophon.tex
  18. │ ├── Contents.tex
  19. │ ├── Declaration.tex
  20. │ ├── Dedication.tex
  21. │ ├── Foreword.tex
  22. │ ├── glossary-entries.tex
  23. │ ├── Glossary.tex
  24. │ ├── Resumen.tex
  25. │ ├── Titleback.tex
  26. │ ├── TitlepageIng.tex
  27. │ └── TitlepageMC.tex
  28. ├── itm.jpg
  29. ├── itmthesis.cls
  30. ├── precontent.tex
  31. ├── README.md
  32. ├── Reference.bib
  33. ├── sepLogo.jpg
  34. ├── tecnmBW.png
  35. ├── thesisStructure.pdf
  36. └── thesisStructure.tex
  37. ```
  38. # The `thesisStructure.tex` file
  39. The main file in the project is the `thesisStructure.tex` file. The file is mainly divided in five parts: 1)Configuration, 2)Front Matter, 3) Main contents, 4) References and 5)Back Matter.
  40. The file contents is show next, a detailed explaination is presented in the next sections.
  41. ``` tex
  42. % Engineering, master and phd degree thesis format, September 2021, for the "Instituto Tecnológico de Morelia"
  43. \documentclass[listings,drafting,spanish]{itmthesis} %itm thesis class definition
  44. \input{configuration}% configuration & packages required
  45. \begin{document}
  46. \pagenumbering{roman} % Roman page numbering
  47. \input{precontent} %Includes titlepage, dedication, Foreword, abstract, publication, acknowledgement
  48. \include{FrontBackMatter/Contents} % Contents, list of figures/tables/listings and acronyms
  49. \pagenumbering{arabic} % Arabic page numbering
  50. %-=-=-=-=-=-=-=-=-=-=-=-=-
  51. % Thesis Main Contents
  52. \include{Chapters/Chapter01} % Chapter 1
  53. \cleardoublepage
  54. \include{Chapters/Chapter02} % Chapter 2
  55. %-=-=-=-=-=-=-=-=-=-=-=-=-
  56. % Apendix
  57. \appendix
  58. \include{Chapters/Chapter0A} % Appendix A
  59. %-=-=-=-=-=-=-=-=-=-=-=-=-
  60. % References
  61. \cleardoublepage
  62. \include{FrontBackMatter/Bibliography}
  63. %-=-=-=-=-=-=-=-=-=-=-=-=-
  64. % Back Matter
  65. \cleardoublepage
  66. \include{FrontBackMatter/Colophon}
  67. \cleardoublepage
  68. \include{FrontBackMatter/Declaration}
  69. %-=-=-=-=-=-=-=-=-=-=-=-=-
  70. \end{document}
  71. ```
  72. ## 1) Configuration section ##
  73. ### Class' options ###
  74. The code next only refers to the configuration of the `itmthesis` class:
  75. ``` tex
  76. % 1)Configuration:
  77. \documentclass[listings,drafting,spanish]{itmthesis} %itm thesis class
  78. \input{configuration}% configuration and packages
  79. \input{FrontBackMatter/glossary-entries}
  80. ```
  81. From here the document class, for the Protocol, is defined with `\documentclass[<options>]{itmthesis}`, and this file determine the way the PDF file is generated by the options. The options defined are:
  82. - `drafting`: The options prints the date of compilation at the end of each page. Suitable opton to know that the latest version is on review or writing process.
  83. - `listing`: The option loads the `listings` package and configures the compilation to generates a gray scale listings outputs.
  84. - `spanish`: The option enables the babel package to print-out the sectional units on spanish language; otherwise, english will be used.
  85. ### `configuration.tex` file ###
  86. Then, `\input` command is used to include files with `LaTeX` commands. Specifically, the `configuration` file includes all the required packages and its configuration, variable(title, author, university, and so on), and command definitions. The complete code is shown next and sectioned on: 1)Listing configuration, 2)Command and Variable definitions, 3)Short descriptions on Math, 4)Packages, and 5)Text space configuration(indent, interline space, and paragraph space); however, the sections that user should modify are only 2), 4) and 5).
  87. ``` tex
  88. %!TeX root=./thesisStructure.tex
  89. %Add here the packages, variables, definitions, environments and specific elements created only for your thesis
  90. % 1 Code listing setup
  91. %------------------
  92. \RequirePackage{listings}
  93. \RequirePackage{xcolor}
  94. \definecolor{gray97}{gray}{0.97}
  95. \definecolor{gray45}{gray}{0.45}
  96. \newcaptionname{spanish}{\lstlistlistingname}{Sección de Códigos}
  97. \renewcommand{\lstlistingname}{Código}
  98. \renewcommand{\lstlistlistingname}{Códigos}
  99. \lstset{ frame=Ltb,
  100. framerule=0pt,
  101. aboveskip=0.2cm,
  102. framextopmargin=3pt,
  103. framexbottommargin=3pt,
  104. framexleftmargin=0.4cm,
  105. framesep=0pt,
  106. rulesep=.4pt,
  107. backgroundcolor=\color{gray97},
  108. rulesepcolor=\color{black},
  109. %
  110. stringstyle=\ttfamily,
  111. showstringspaces = false,
  112. %basicstyle=\small\ttfamily,
  113. %basicstyle=\small,
  114. commentstyle=\color{gray45}\ttfamily,
  115. keywordstyle=\bfseries,
  116. %
  117. numbers=left,
  118. numbersep=15pt,
  119. numberstyle=\tiny,
  120. numberfirstline = false,
  121. breaklines=true,
  122. }
  123. % 2 Commands and variables
  124. % 2.1 Thesis's title page config
  125. %------------------
  126. \newcommand{\myTitle}{Un Título de la Tesis no Muy Complicado y Largo Pero Capaz de Definir Concretamente}
  127. \newcommand{\mySubtitle}{Caso de Estudio a Nivel Maestría}
  128. \newcommand{\myDegree}{Maestría en Ciencias en Ingeniería Electrónica}
  129. % 2.2 Autores:
  130. \newcommand{\myName}{Gerardo Marx Chávez-Campos}
  131. \newcommand{\myNumber}{D01120294}
  132. %\newcommand{\myPartner}{Otro autor}
  133. %----------------
  134. % 2.3 Mesa de revisión
  135. %Director:
  136. \newcommand{\myProf}{Homer Simpson}
  137. %Codirector:
  138. \newcommand{\myOtherProf}{James Clerk Maxwell \xspace}
  139. %Revisor 1:
  140. \newcommand{\mySupervisor}{Piere Simon Laplace\xspace}
  141. %Revisor 2:
  142. \newcommand{\myOtherSupervisor}{Jean-Baptiste Joseph Fourier\xspace}
  143. %--------------
  144. % 2.4 Datos del instituto:
  145. \newcommand{\myFaculty}{Maestría en Ingeniería Electrónica}
  146. \newcommand{\myDepartment}{División de Estudios de Posgrado e Investigación}
  147. \newcommand{\myUni}{Instituto Tecnológico de Morelia}
  148. \newcommand{\myLocation}{Morelia, Michoacán, México}
  149. \newcommand{\myTime}{Abril 2021}
  150. \newcommand{\myThesisVersion}{Rev 2.0}
  151. %---------------------
  152. % 3 USEFUL COMMANDS
  153. %---------------------
  154. \newcommand{\ie}{i.\,e.}
  155. \newcommand{\Ie}{I.\,e.}
  156. \newcommand{\eg}{e.\,g.}
  157. \newcommand{\Eg}{E.\,g.}
  158. %-------------------------
  159. % 4. Required packages for
  160. % figures, plots, subfigures
  161. %-------------------------
  162. \usepackage{float}
  163. \usepackage{subfigure}
  164. \usepackage{tikz}
  165. \usepackage{booktabs} %Beautiful tables
  166. \usepackage{todonotes} %Todo list for comments
  167. \usepackage[version-1-compatibility]{siunitx} %easy writting of SI units
  168. \usepackage{pgfplots}
  169. \pgfplotsset{compat=1.10}
  170. \decimalpoint %Decimal point enable
  171. \usepackage[acronym]{glossaries}
  172. %-------------------------
  173. % 5. setting space for indentation
  174. % space between paragraphs and
  175. % baseline.
  176. % Uncomment to set parameters
  177. %-------------------------
  178. % \setlength{\parindent}{4em}
  179. \setlength{\parskip}{1em}
  180. %\renewcommand{\baselinestretch}{2.0} % Interlineado
  181. ```
  182. Thus, if you require to change the thesis' title modify `\myTitle` definition on section *2.1*. If you need to change your data as an author modify `\myname` on section *2.2*, and the same foe the other options as the reviewing group (*2.3*), and institution (*2.4*).
  183. On the other hand, if you want to add new packages to your Protocol, you can added on the main file; the `thesisStructure.tex` file. However, to maintain a clean code you should add on the `configuration` file, specifically on section *4*.
  184. Finally to set specific values of separation for tabulation, paragraphs or text separation between text(interline), please modify section *5*. Here you can use several measurement units as `em`, `cm` , `in` or lines `2`(just a number). E.g:
  185. ``` tex
  186. \setlength{\parindent}{4em}
  187. \setlength{\parskip}{1cm}
  188. \renewcommand{\baselinestretch}{2.0} % Interlineado
  189. ```
  190. ### `glossary-entries.tex` file ###
  191. This file includes each entry for acronyms and glossary entries, the syntax of each entry is shown below:
  192. ``` tex
  193. \makeglossaries
  194. \newglossaryentry{latex}
  195. {
  196. name=latex,
  197. description={Es un lenguaje de marcado o sintaxis especialmente diseñado para documentos científicos}
  198. }
  199. \newglossaryentry{maths}{
  200. name=matemáticas,
  201. description={Las matemáticas son sólo una aproximación a la realidad de la vida}}
  202. \newglossaryentry{formula}{
  203. name=formula,
  204. description={A mathematical expression}}
  205. \newacronym{ecm}{ECM}{Error Cuadrático Medio}
  206. \newacronym{ls}{LS}{Mínimos Cuadrados, \textit{Least Squares}}
  207. ```
  208. To learn how to call an entry on the code, see the code on `Cahpter02.tex`.
  209. ## 2) Front Matter ##
  210. Explain this:
  211. ``` tex
  212. % 2)Front Matter:
  213. \pagenumbering{roman} % Roman page numbering
  214. \input{precontent} %Includes titlepage, dedication, Foreword, abstract, publication, acknowledgement
  215. \include{FrontBackMatter/Contents} % Contents, list of figures/tables/listings and acronyms
  216. \pagenumbering{arabic} % Arabic page numbering
  217. ```
  218. ## Chapters
  219. ## Apendix
  220. ## including images
  221. # The `configuration` file
  222. # Defined variables
  223. # Titlepage
  224. # Glossary
  225. # References