Last active
December 23, 2015 06:49
-
-
Save arnarthor/6596620 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
% A basic LaTeX document for a handin with a | |
% standard RU title page | |
% If you want the title to appear on a separate | |
% page, change notitlepage to titlepage | |
\documentclass[11pt,a4paper,notitlepage]{amsart} | |
\usepackage[utf8]{inputenc} | |
\usepackage[T1]{fontenc} | |
% If your hand-in is in icelandic change english to icelandic | |
% Note: This has nothing to do with Icelandic characters, they | |
% can always be used. This just tells other packages what | |
% language you are using and changes the hyphenation used by LaTeX | |
% If icelandic is selected, a shorthand, "` and "', is also included | |
% for Icelandic quotation marks. They can also obtained by using | |
% ,, and `` | |
\usepackage[english]{babel} | |
\usepackage{amsmath, amsthm, amssymb, amsfonts} | |
\usepackage{graphicx} | |
\usepackage{enumerate} | |
% To use the whole A4-page | |
% See: ftp://ftp.tex.ac.uk/tex-archive/macros/latex/contrib/geometry/geometry.pdf | |
% and http://en.wikibooks.org/wiki/LaTeX/Document_Structure | |
\usepackage{geometry} | |
% For header and footer | |
% See: ftp://ctan.tug.org/tex-archive/macros/latex/contrib/fancyhdr/fancyhdr.pdf | |
% and http://en.wikibooks.org/wiki/LaTeX/Document_Structure | |
\usepackage{fancyhdr} | |
% For prettier tables | |
% See: http://ctan.mackichan.com/macros/latex/contrib/booktabs/booktabs.pdf | |
% and http://en.wikibooks.org/wiki/LaTeX/Tables | |
\usepackage{booktabs} | |
\usepackage{float} | |
\usepackage{mathtools} | |
\usepackage{listings} | |
\usepackage{color} | |
\definecolor{dkgreen}{rgb}{0,0.6,0} | |
\definecolor{gray}{rgb}{0.5,0.5,0.5} | |
\definecolor{mauve}{rgb}{0.58,0,0.82} | |
\lstset{frame=tb, | |
language=Java, | |
aboveskip=3mm, | |
belowskip=3mm, | |
showstringspaces=false, | |
columns=flexible, | |
basicstyle={\small\ttfamily}, | |
numbers=none, | |
numberstyle=\tiny\color{gray}, | |
keywordstyle=\color{blue}, | |
commentstyle=\color{dkgreen}, | |
stringstyle=\color{mauve}, | |
breaklines=true, | |
breakatwhitespace=true | |
tabsize=3 | |
} | |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% | |
% Setup | |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% | |
% Set the margins of the paper. By default LaTeX uses huge margins | |
\geometry{includeheadfoot, margin=2.5cm} | |
% you can also use | |
% \geometry{a4paper} | |
% End of margins setup | |
% Fill in any relevant information | |
% Leave the fields inside the {} empty if they do not apply | |
\newcommand{\students}{ | |
Árni Fannar Þráinsson, % notice that newlines are not interpreted | |
Sindri Sigurjónsson | |
} | |
\newcommand{\studentemail}{ | |
arni11@ru.is, \ | |
sindris12@ru.is | |
} | |
\newcommand{\semester}{Fall 2013} | |
\newcommand{\coursename}{Reiknirit} | |
\newcommand{\courseid}{T-301-REIR} | |
\newcommand{\ssn}{kt. 0301892219, kt. 040289-2409} | |
\newcommand{\group}{} | |
\newcommand{\assignment}{D4: Stacks and time complexity} | |
\newcommand{\teachingassistant}{Teacher: Magnús Már Halldórsson} | |
\newcommand{\problemtitle}{Problem} | |
\newcommand{\dateofcompilation}{\today} | |
% Setup header and footer | |
% Headers | |
\pagestyle{fancy} % To get the header and footer | |
\chead{\small \textsc{\assignment}} | |
\rhead{\small \textsc{\coursename}} | |
\lhead{\small \textsc{\studentemail}} | |
% Footers | |
%\lfoot{Left footer text} | |
%\cfoot{\thepage} % This is the default behaviour | |
%\rfoot{Right footer text} | |
% If you don't want a line below the header or above the footer, | |
% change the appropriate header/footerrulewidth to 0pt | |
\setlength{\headheight}{15.2pt} % This is set to avoid a warning | |
\renewcommand{\headrulewidth}{0.4pt} | |
\renewcommand{\footrulewidth}{0.4pt} | |
% End of header and footer setup | |
% Setup Problem/Solution environments | |
\theoremstyle{plain} | |
\newtheorem{problem}{Problem} | |
\theoremstyle{remar<k} | |
\newtheorem*{solution}{Solution} | |
% End of Problem/Solution environments setup | |
% Custom problem (so you can provide the problem name) | |
\newenvironment{cproblem}[1]{\begin{trivlist} | |
\item[\hskip \labelsep {\bfseries \problemtitle}\hskip \labelsep {\bfseries#1.}]\begin{itshape}}{\end{itshape}\end{trivlist}} | |
% End of Problem/Solution environments setup | |
% Add the title page command | |
\newcommand{\maketitlepage}[1] | |
{ | |
\begin{titlepage} | |
\begin{center} | |
%\includegraphics[width=0.55\textwidth]{./rulogo}\\[1.5cm] TO INCLUDE A LOGO | |
\textsc{\huge \semester}\\[0.8cm] | |
{\textsc{\Huge \courseid, \coursename}}\\[0.4cm] | |
\textsc{\LARGE }\\[2.5cm] | |
\textbf{\textsc{\Huge #1}}\\[3cm] | |
\textsc{\huge \students}\\[0.4cm] | |
\textsc{\LARGE \ssn}\\[0.4cm] | |
\textsc{\LARGE \group}\\[1cm] | |
\textsc{\Large \dateofcompilation} | |
\end{center} | |
\vfill | |
% You may also want to add the name of your teaching assistant | |
\begin{flushleft} | |
\textsc{\Large \teachingassistant} | |
\end{flushleft} | |
\end{titlepage} | |
} | |
\newcommand{\command}[1]{\texttt{\textbackslash{}#1}} | |
%%%%%%%%%%%%%%%%%%%%%%%% END OF SETUP %%%%%%%%%%%%%%%%%%%%%%%% | |
\begin{document} | |
% Create the title page | |
\maketitlepage{\assignment} | |
\end{document} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment