SHARE
TWEET

Untitled

a guest May 12th, 2014 157 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. %%%%%%%%%%%%%%%%%%%%%
  2. %     Doc Class     %
  3. %%%%%%%%%%%%%%%%%%%%%
  4. \documentclass[12pt,twoside,danish]{report}
  5. \usepackage{fixltx2e}  
  6. %%%%%%%%%%%%%%%%%%%%%
  7. %     Encoding      %
  8. %%%%%%%%%%%%%%%%%%%%%
  9. \usepackage[utf8x]{inputenc}
  10. \usepackage[T1]{fontenc}
  11. \usepackage{textcomp}
  12.  
  13. %%%%%%%%%%%%%%%%%%%%%
  14. %   Nice chapters   %
  15. %%%%%%%%%%%%%%%%%%%%%
  16. \usepackage{titlesec, blindtext, color}
  17. \definecolor{gray75}{gray}{0.75}
  18. \newcommand{\hsp}{\hspace{20pt}}
  19. \titleformat{\chapter}[hang]{\Huge\bfseries}{\thechapter\hsp\textcolor{gray75}{|}\hsp}{0pt}{\Huge\bfseries}
  20.  
  21. %%%%%%%%%%%%%%%%%%%%%
  22. %      English      %
  23. %%%%%%%%%%%%%%%%%%%%%
  24. \usepackage[english]{babel}
  25.  
  26. %%%%%%%%%%%%%%%%%%%%%
  27. %     Multiline         %
  28. %     Comments          %
  29. %%%%%%%%%%%%%%%%%%%%%
  30. \usepackage{verbatim}
  31.  
  32. %%%%%%%%%%%%%%%%%%%%%
  33. %      Figurer      %
  34. %%%%%%%%%%%%%%%%%%%%%
  35. \usepackage{graphicx}
  36. \usepackage{float}
  37.  
  38. %%%%%%%%%%%%%%%%%%%%%
  39. %    Hyperlinks     %
  40. %%%%%%%%%%%%%%%%%%%%%
  41. %\usepackage[colorlinks,linkcolor=black]{hyperref}
  42. \usepackage[hidelinks]{hyperref}
  43.  
  44. %%%%%%%%%%%%%%%%%%%%%
  45. %     Billeder      %
  46. %%%%%%%%%%%%%%%%%%%%%
  47. \newcommand{\fig}[3]{\includegraphics[#1]{./dele/#2/billeder/#3}}
  48.  
  49. %%%%%%%%%%%%%%%%%%%%%
  50. %    PDF include    %
  51. %%%%%%%%%%%%%%%%%%%%%
  52. \usepackage{pdfpages}
  53.  
  54. %%%%%%%%%%%%%%%%%%%%%
  55. %     Footnotes     %
  56. %%%%%%%%%%%%%%%%%%%%%
  57. \usepackage[bottom]{footmisc}
  58.  
  59. %%%%%%%%%%%%%%%%%%%%%
  60. %     PDF KEYS      %
  61. %%%%%%%%%%%%%%%%%%%%%
  62. \hypersetup{pdftitle={..}}
  63. \hypersetup{pdfauthor={..)}}
  64. \hypersetup{pdfkeywords={..}}
  65. \hypersetup{pdfsubject={..}}
  66.  
  67. %%%%%%%%%%%%%%%%%%%%%
  68. %   Bibliografy     %
  69. %%%%%%%%%%%%%%%%%%%%%
  70. \usepackage[numbers]{natbib}
  71. \bibliographystyle{unsrtnat}
  72.  
  73. %%%%%%%%%%%%%%%%%%%%%
  74. %     Semantics         %
  75. %%%%%%%%%%%%%%%%%%%%%
  76. \usepackage{semantic}
  77.  
  78. %%%%%%%%%%%%%%%%%%%%%
  79. %   Head + foot     %
  80. %%%%%%%%%%%%%%%%%%%%%
  81. \usepackage{fancyhdr}
  82. \pagestyle{fancy}
  83. \fancypagestyle{plain}
  84.  
  85. \renewcommand{\footrulewidth}{0.4pt}
  86. %\renewcommand{\familydefault}{\sfdefault}
  87.  
  88.  
  89. % Nulstilling af felter der ikke bruges
  90. \fancyhf{}
  91.  
  92. % Header
  93. \fancyhead[RO]{\leftmark}       % Right Odd - Chapter name
  94. \fancyhead[LO]{Home automation}         % Left Odd - Title
  95.  
  96. \fancyhead[LE]{\leftmark}       % Left Even - Chapter name
  97. \fancyhead[RE]{Home automation}         % Right Even - Title
  98.  
  99. % Footer
  100. \fancyfoot[RO]{\thepage}        % Right Odd - page number
  101. \fancyfoot[LE]{\thepage}        % Left Even - page number
  102.  
  103. \fancyfoot[RE]{\rightmark}      % Right Even - section name
  104. \fancyfoot[LO]{\rightmark}      % Right Odd - section name
  105.  
  106. %%%%%%%%%%%%%%%%%%%%%
  107. %    Andre items    %
  108. %%%%%%%%%%%%%%%%%%%%%
  109. \usepackage{pifont}
  110. \usepackage{tabularx} % in the preamble
  111. \usepackage[section]{placeins} % Keep floats in their respective sections.
  112.  
  113. %%%%%%%%%%%%%%%%%%%%%
  114. %    Række farver   %
  115. %%%%%%%%%%%%%%%%%%%%%
  116. \definecolor{oddrow}{RGB}{200,200,200}
  117. \definecolor{evenrow}{RGB}{240,240,240}
  118. \usepackage[table]{xcolor}
  119.  
  120. %%%%%%%%%%%%%%%%%%%%%%%%%%%%
  121. % Fancy captions + headers %
  122. %%%%%%%%%%%%%%%%%%%%%%%%%%%%
  123. \usepackage{caption}
  124. \DeclareCaptionFont{white}{\color{white}}
  125. \DeclareCaptionFormat{listing}{\colorbox{gray}{\parbox{\textwidth}{#1#2#3}}}
  126. \captionsetup[lstlisting]{format=listing,labelfont=white,textfont=white}
  127.  
  128. \newcommand{\fancyheader}[1]{\colorbox{gray}{\parbox{\textwidth}{\textcolor{white}{#1}}}\vspace{0.05in}}
  129.  
  130. %%%%%%%%%%%%%%%%%%%%%
  131. % Renews Lowercase  %
  132. %%%%%%%%%%%%%%%%%%%%%
  133. \renewcommand{\chaptermark}[1]{\markboth{\thechapter\ #1}{}}
  134. \renewcommand{\sectionmark}[1]{\markright{\thesection\ #1}{}}
  135.  
  136. %%%%%%%%%%%%%%%%%%%
  137. % Fjerner Indryk  %
  138. %%%%%%%%%%%%%%%%%%%
  139. \setlength{\parindent}{0in}
  140.  
  141. %%%%%%%%%%%%%%%%%%%
  142. %   Code listing  %
  143. %%%%%%%%%%%%%%%%%%%
  144. %Egne farver%
  145. \definecolor{grey}{RGB}{200,200,200}
  146. \definecolor{comments}{RGB}{0,128,0}
  147. \definecolor{define}{RGB}{128,64,0}
  148. \definecolor{enums}{RGB}{43,145,175}
  149.  
  150.  
  151. \usepackage{listings}
  152.  
  153. %ÆØÅ i kode%
  154. \lstset{inputencoding=ansinew}
  155. \lstset{literate=%
  156. {æ}{{\ae}}1
  157. {å}{{\aa}}1
  158. {ø}{{\o}}1
  159. {Æ}{{\AE}}1
  160. {Å}{{\AA}}1
  161. {Ø}{{\O}}1
  162. }
  163.  
  164. %Indstillinger for listings%
  165. \lstset{
  166. language = java,
  167. numbers = left,
  168. breaklines = true,
  169. showstringspaces = false,
  170. basicstyle = \scriptsize\ttfamily,
  171. showspaces = false,
  172. tabsize = 2,
  173. commentstyle = \color{comments},
  174. captionpos = t,
  175. stringstyle = \color{red},
  176. keywordstyle = \color{blue}
  177. }
  178.  
  179. %Ekstra farve til classer%
  180. \lstset{emph={  
  181.     UserInfo, Client, Server, Account, DataPacket, Chat, Todo, FileManager, TcpClient, NetworkStream, MemoryStream, BinaryFormatter, Bitconverter elseif endif
  182.     },emphstyle={\color{magenta}}
  183. }
  184.  
  185. \newcommand{\listcode}[6][ClientProg/LoginWindow.xaml.cs]
  186. {
  187. \lstinputlisting[language = {#2}, linerange={#3-#4}, firstnumber = #3, caption=#5, label=#6]{../Programmering/#1}
  188. }
  189.  
  190. %Omdøbninger%
  191. \renewcommand*\lstlistingname{Code example}
  192. \renewcommand*\lstlistlistingname{Code examples}
  193.  
  194.  
  195. % Tikz - Til tegning af figurer og andre tegninger %
  196. \usepackage{tikz}
  197. \usetikzlibrary{arrows,snakes,backgrounds}
  198. \usepackage{tikz-3dplot}
  199.  
  200.  
  201. % For Blank pages %
  202. \newcommand{\blankpage}{
  203. \newpage
  204. \thispagestyle{empty}
  205. \mbox{}
  206. \newpage
  207. }
  208.  
  209. \usepackage{multirow}
  210.  
  211. \usepackage[numbered]{bookmark}
  212.  
  213. \newcommand{\citat}[1]
  214. {
  215. ``#1''
  216. }
  217.  
  218. %%%%%%%%%%%%%%%%%%%
  219. %   JSON Styling  %
  220. %%%%%%%%%%%%%%%%%%%
  221. \definecolor{background}{HTML}{EEEEEE}
  222. \colorlet{punct}{red!60!black}
  223. \definecolor{delim}{RGB}{20,105,176}
  224. \colorlet{numb}{magenta!60!black}
  225.  
  226. \lstdefinelanguage{json}{
  227.     literate=
  228.      *{0}{{{\color{numb}0}}}{1}
  229.       {1}{{{\color{numb}1}}}{1}
  230.       {2}{{{\color{numb}2}}}{1}
  231.       {3}{{{\color{numb}3}}}{1}
  232.       {4}{{{\color{numb}4}}}{1}
  233.       {5}{{{\color{numb}5}}}{1}
  234.       {6}{{{\color{numb}6}}}{1}
  235.       {7}{{{\color{numb}7}}}{1}
  236.       {8}{{{\color{numb}8}}}{1}
  237.       {9}{{{\color{numb}9}}}{1}
  238.       {:}{{{\color{punct}{:}}}}{1}
  239.       {,}{{{\color{punct}{,}}}}{1}
  240.       {\{}{{{\color{delim}{\{}}}}{1}
  241.       {\}}{{{\color{delim}{\}}}}}{1}
  242.       {[}{{{\color{delim}{[}}}}{1}
  243.       {]}{{{\color{delim}{]}}}}{1},
  244. }
  245.  
  246. %%%%%%%%%%%%%%%%%%%
  247. %   Name of lang  %
  248. %%%%%%%%%%%%%%%%%%%
  249. \newcommand{\name}{HOME\texttrademark}
  250.  
  251. %%%%%%%%%%%%%%%%%%%
  252. %    Nice tilde   %
  253. %%%%%%%%%%%%%%%%%%%
  254. \newcommand{\niceTilde}{\raise.17ex\hbox{$\scriptstyle\sim$}}
  255.  
  256. %%%%%%%%%%%%%%%%%%
  257. %  Strikethrough %
  258. %%%%%%%%%%%%%%%%%%
  259. \usepackage{soul}
  260.  
  261.  
  262.  
  263.  
  264. \begin{document}
  265.  
  266. %------- Appendix ----------------------%
  267. \appendix
  268. \chapter{Transition rules}
  269. \begin{center}
  270. \begin{math}
  271. \mathlig{-><-}{\rightarrow\leftarrow}
  272. \inference[Plus]{a_{1} -> v_{1}\; a_{2} -> v_{2}}{a_{1}+a_{2} -> v}\; Where\; v = v_{1} + v_{2}
  273. \end{math}
  274. \end{center}
  275. \begin{figure}[H]
  276. \caption{Transition rule for Addition}
  277. \end{figure}
  278.  
  279.  
  280. \begin{center}
  281. \begin{math}
  282. \mathlig{-><-}{\rightarrow\leftarrow}
  283. \inference[Plus]{a_{1} -> v_{1}\; a_{2} -> v_{2}}{a_{1} - a_{2} -> v}\; Where\; v = v_{1} - v_{2}
  284. \end{math}
  285. \end{center}
  286. \begin{figure}[H]
  287. \caption{Transition rule for Subtraction}
  288. \end{figure}
  289.  
  290. \begin{center}
  291. \begin{math}
  292. \mathlig{-><-}{\rightarrow\leftarrow}
  293. \inference[Plus]{a_{1} -> v_{1}\; a_{2} -> v_{2}}{a_{1}*a_{2} -> v}\; Where\; v = v_{1} * v_{2}
  294. \end{math}
  295. \end{center}
  296. \begin{figure}[H]
  297. \caption{Transition rule for Multiplication}
  298. \end{figure}
  299.  
  300. \begin{center}
  301. \begin{math}
  302. \mathlig{-><-}{\rightarrow\leftarrow}
  303. \inference[Plus]{a_{1} -> v_{1}\; a_{2} -> v_{2}}{a_{1}/a_{2} -> v}\; Where\; v = v_{1} / v_{2}
  304. \end{math}
  305. \end{center}
  306. \begin{figure}[H]
  307. \caption{Transition rule for Division}
  308. \end{figure}
  309.  
  310. \begin{center}
  311. \begin{math}
  312. \mathlig{-><-}{\rightarrow\leftarrow}
  313. \inference[Plus]{a_{1} -> v_{1}\; a_{2} -> v_{2}}{a_{1}\%a_{2} -> v}\; Where\; v = v_{1} \% v_{2}
  314. \end{math}
  315. \end{center}
  316. \begin{figure}[H]
  317. \caption{Transition rule for Plus}
  318. \end{figure}
  319.  
  320. \end{document}
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top