diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000000000000000000000000000000000000..18ad43196797a66e390be334b4c624cdc8e73378 --- /dev/null +++ b/.gitignore @@ -0,0 +1,291 @@ +**/.vscode +**/out + +## Core latex/pdflatex auxiliary files: +*.aux +*.lof +*.log +*.lot +*.fls +*.out +*.toc +*.fmt +*.fot +*.cb +*.cb2 +.*.lb + +## Intermediate documents: +*.dvi +*.xdv +*-converted-to.* +# these rules might exclude image files for figures etc. +# *.ps +# *.eps +# *.pdf + +## Generated if empty string is given at "Please type another file name for output:" +.pdf + +## Bibliography auxiliary files (bibtex/biblatex/biber): +*.bbl +*.bcf +*.blg +*-blx.aux +*-blx.bib +*.run.xml + +## Build tool auxiliary files: +*.fdb_latexmk +*.synctex +*.synctex(busy) +*.synctex.gz +*.synctex.gz(busy) +*.pdfsync + +## Build tool directories for auxiliary files +# latexrun +latex.out/ + +## Auxiliary and intermediate files from other packages: +# algorithms +*.alg +*.loa + +# achemso +acs-*.bib + +# amsthm +*.thm + +# beamer +*.nav +*.pre +*.snm +*.vrb + +# changes +*.soc + +# comment +*.cut + +# cprotect +*.cpt + +# elsarticle (documentclass of Elsevier journals) +*.spl + +# endnotes +*.ent + +# fixme +*.lox + +# feynmf/feynmp +*.mf +*.mp +*.t[1-9] +*.t[1-9][0-9] +*.tfm + +#(r)(e)ledmac/(r)(e)ledpar +*.end +*.?end +*.[1-9] +*.[1-9][0-9] +*.[1-9][0-9][0-9] +*.[1-9]R +*.[1-9][0-9]R +*.[1-9][0-9][0-9]R +*.eledsec[1-9] +*.eledsec[1-9]R +*.eledsec[1-9][0-9] +*.eledsec[1-9][0-9]R +*.eledsec[1-9][0-9][0-9] +*.eledsec[1-9][0-9][0-9]R + +# glossaries +*.acn +*.acr +*.glg +*.glo +*.gls +*.glsdefs +*.lzo +*.lzs + +# uncomment this for glossaries-extra (will ignore makeindex's style files!) +# *.ist + +# gnuplottex +*-gnuplottex-* + +# gregoriotex +*.gaux +*.glog +*.gtex + +# htlatex +*.4ct +*.4tc +*.idv +*.lg +*.trc +*.xref + +# hyperref +*.brf + +# knitr +*-concordance.tex +# TODO Uncomment the next line if you use knitr and want to ignore its generated tikz files +# *.tikz +*-tikzDictionary + +# listings +*.lol + +# luatexja-ruby +*.ltjruby + +# makeidx +*.idx +*.ilg +*.ind + +# minitoc +*.maf +*.mlf +*.mlt +*.mtc[0-9]* +*.slf[0-9]* +*.slt[0-9]* +*.stc[0-9]* + +# minted +_minted* +*.pyg + +# morewrites +*.mw + +# newpax +*.newpax + +# nomencl +*.nlg +*.nlo +*.nls + +# pax +*.pax + +# pdfpcnotes +*.pdfpc + +# sagetex +*.sagetex.sage +*.sagetex.py +*.sagetex.scmd + +# scrwfile +*.wrt + +# sympy +*.sout +*.sympy +sympy-plots-for-*.tex/ + +# pdfcomment +*.upa +*.upb + +# pythontex +*.pytxcode +pythontex-files-*/ + +# tcolorbox +*.listing + +# thmtools +*.loe + +# TikZ & PGF +*.dpth +*.md5 +*.auxlock + +# todonotes +*.tdo + +# vhistory +*.hst +*.ver + +# easy-todo +*.lod + +# xcolor +*.xcp + +# xmpincl +*.xmpi + +# xindy +*.xdy + +# xypic precompiled matrices and outlines +*.xyc +*.xyd + +# endfloat +*.ttt +*.fff + +# Latexian +TSWLatexianTemp* + +## Editors: +# WinEdt +*.bak +*.sav + +# Texpad +.texpadtmp + +# LyX +*.lyx~ + +# Kile +*.backup + +# gummi +.*.swp + +# KBibTeX +*~[0-9]* + +# TeXnicCenter +*.tps + +# auto folder when using emacs and auctex +./auto/* +*.el + +# expex forward references with \gathertags +*-tags.tex + +# standalone packages +*.sta + +# Makeindex log files +*.lpz + +# xwatermark package +*.xwm + +# REVTeX puts footnotes in the bibliography by default, unless the nofootinbib +# option is specified. Footnotes are the stored in a file with suffix Notes.bib. +# Uncomment the next line to have this generated file ignored. +#*Notes.bib \ No newline at end of file diff --git a/Makefile b/Makefile new file mode 100644 index 0000000000000000000000000000000000000000..9969e3b57647049643319472c46f9a2ad7dcc204 --- /dev/null +++ b/Makefile @@ -0,0 +1,125 @@ +################################################################################ +# +# Makefile for modularily built academic documents +# +# This makefile defines a modular build system for academic LaTeX documents +# (Bachelors / Masters Theses, Papers, Posters, etc.). It relies on `latexmk` +# for building the main document and any standalone chapters to handle the +# multiple runs required for resolving references, citations, et cetera. +# Output for the main document is emitted into the subfolder `out`. +# +# Building any TikZ graphics or other embedded elements generated from LaTeX +# as standalone objects is supported. It is assumed that a single run of +# `pdflatex` suffices to build any of those objects. Any .tex-file located in +# the subfolder 'pics' is discovered as a standalone object; its output +# can be included using `\includegraphics{pics/out/<object>.pdf}`. +# +# Automatic building of Python-generated LaTeX standalone files is also +# supported. Every script `<name>.py` in the `py2tex` subfolder is expected to +# generate a file `py2tex/out/<name>.tex`, which is then compiled to +# `py2tex/out/<name>.pdf`. +# +# Created 2021, Frederik Hennig <frederik.hennig@fau.de> +# +################################################################################ + +# Universal output directory name +OUT := out + +################################################################################ +# Command Definitions # +################################################################################ + +MKDIR := mkdir -p + +PYTHON := python + +LATEX_ARGS := -interaction=nonstopmode -output-directory=$(OUT) +PDFLATEX := pdflatex $(LATEX_ARGS) +LUALATEX := lualatex $(LATEX_ARGS) +LUALATEXMK := latexmk -lualatex $(LATEX_ARGS) +PDFLATEXMK := latexmk -pdf $(LATEX_ARGS) + +# Change these to LUALATEX and LUALATEXMK if you want to use luatex. +LATEX_STANDALONE := $(PDFLATEX) +LATEXMK := $(PDFLATEXMK) + +################################################################################ +# Folders and File Discovery # +################################################################################ + +PICS := pics +PICS_OUT := $(PICS)/$(OUT) +PICS_SOURCES := $(wildcard $(PICS)/*.tex) +PICS_PDF_FILES := $(patsubst $(PICS)/%.tex, $(PICS_OUT)/%.pdf, $(PICS_SOURCES)) + +PYTEX := py2tex +PYTEX_OUT := py2tex/out +PYTEX_SOURCES := $(wildcard $(PYTEX)/*.py) +PYTEX_PDF_FILES := $(patsubst $(PYTEX)/%.py, $(PYTEX_OUT)/%.pdf, $(PYTEX_SOURCES)) + +################################################################################ +# Pseudo-Targets # +################################################################################ + +.PHONY: all, clean, FORCE, pics, thesis + +all: chapter1 thesis + +clean: + rm -rf $(OUT) + rm -rf $(PICS_OUT) + rm -rf $(PYTEX_OUT) + +FORCE: ; + +################################################################################ +# Directories # +################################################################################ + +dir_guard = $(MKDIR) $(@D) + +outdir: + $(MKDIR) $(OUT) + +################################################################################ +# TikZ Pictures # +################################################################################ + +pics: $(PICS_PDF_FILES) + +$(PICS_OUT)/%.pdf: $(PICS)/%.tex + $(dir_guard) + cd $(PICS) && $(LATEX_STANDALONE) $(notdir $<) + +################################################################################ +# Python Plots # +################################################################################ + +py2tex: $(PYTEX_PDF_FILES) + +$(PYTEX_OUT)/%.pdf: $(PYTEX)/%.py + $(dir_guard) + cd $(PYTEX) && $(PYTHON) $(notdir $<) + cd $(PYTEX) && $(LATEX_STANDALONE) out/$(basename $(notdir $<)).tex + +################################################################################ +# Output Documents # +################################################################################ + +$(OUT)/%.pdf: FORCE + $(dir_guard) + $(LATEXMK) $(*F).tex + +################################################################################ +# Standalone Chapters and Thesis # +################################################################################ + +# Make sure to add pics, plots or any other targets as dependencies to +# all chapters that require input from these targets + +chapter1: $(OUT)/chapter1.pdf + +chapter2: pics py2tex $(OUT)/chapter2.pdf + +thesis: pics py2tex $(OUT)/thesis.pdf diff --git a/README.md b/README.md index ef4402b42d35f5bf2ec61a74d106beaca3cb3572..da88828af4d2165beae207c90ee5328dcf2d697b 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,51 @@ # lssthesis-memoir -Template for student theses written at LSS, based on the memoir document class. \ No newline at end of file +Template for student theses written in LaTeX at LSS, based on the memoir document class. + +This repository contains a template for bachelor's and master's thesis written at the Chair for System Simulation at FAU, based on the memoir document class ([https://ctan.org/pkg/memoir](https://ctan.org/pkg/memoir)) and the *lsspub* template. This template consists of the *lsspub-memoir* document class ([includes/lsspub-memoir.cls](includes/lsspub-memoir.cls)), a sample document structure, and a *Makefile* defining a build system for modular and reproducible thesis building from scratch. + +# Build System + +## Overview + +Contained in this repository is a *make*-based build system constructed for incremental building of your thesis. In this system, measures have been taken to only rebuild those parts of your document that actually have changed. The entire document can simply be built by running the command `make thesis` in the root directory. For the main document, as well as for individual chapters, it uses [latexmk](https://ctan.org/pkg/latexmk), which runs `pdflatex` (or, if desired, `luatex`) together with `bibtex` (or, in our case, `biber`) as many times as necessary to construct a PDF file from your document sources. All output files are written to an `out` folder. Any output files may be removed by calling `make clean`. Apart from building the entire thesis, the system also supports building individual chapters by calling `make chapterX`, provided a standalone file `chapterX.tex` is present in the root folder. Simply calling `make` without further arguments causes all standalone chapters and the thesis to be built. + +## Standalone Chapters + +The Makefile contains the option to build single chapters individually. For this, both a file `chapterX.tex` must be present in the root directory, and the target `chapterX` must be added to the bottom of the Makefile, with any required dependencies. +## Standalone and Python-Generated Pictures + +LaTeX theses are seldom monolithic; they contain pictures, diagrams, plots and tables of many a kind. Some of these are static; they may simply be saved alongside the `.tex` files and included into the document. But very often, such pictures are dynamically generated from raw data using scripts. Furthermore, many pictures and diagrams can be written in [TikZ](https://www.ctan.org/pkg/pgf) (a very powerful graphics package for LaTeX, check it out!), which may be done directly within the main LaTeX document. However, such graphics will often take a long time to build, slowing down typesetting of the entire document even if they were not changed. Also, when creating them, having to build the entire document if you are just interested in getting a single picture right is also very annoying. The solution is to set your TikZ pictures in *standalone* LaTeX documents, which translate to an individual PDF file for each picture, which may then be included into your main document using `\includegraphics`. + +Building of dynamically generated external files should not be left to the user (in this case, you), to make sure they are always reproducable and up-to-date. Hence, this repository offers a few tools to automate this process. The *Makefile* of this repository contains code to build standalone TikZ-pictures and any standalone `.tex` files generated from Python scripts automatically, and only if their sources have changed. This works in the following way: + +### Standalone LaTeX / TikZ Pics + +The Makefile treats every `.tex` file in the `pics` subfolder as a source for a standalone picture. It calls `pdflatex` for every such file, and writes the generated PDF file to `pics/out`. Hence, any picture generated this way must be included in the main document from the `pics/out`-folder. Example: The file [SpheresInBox2D.tex](pics/SpheresInBox2D.tex) in this template will be compiled to `pics/out/SpheresInBox2D.pdf` which must be included using `\includegraphics{pics/out/SpheresInBox2D.tex}`. + +### Python-Generated LaTeX code + +The Makefile searches the subfolder `py2tex` for Python scripts, which are expected to generate a `.tex` file in `py2tex/out` with the same name as the script. These files are then compiled using `pdflatex`. This may for example be used to automatically build script-generated tables, or [matplotlib](https://matplotlib.org/) graphs using [tikzplotlib](https://github.com/nschloe/tikzplotlib). For example, the script `py2tex/WildGrowthOfSpheres.py` of this template uses matplotlib and tikzplotlib to write TikZ-code for a plot to `py2tex/out/WildGrowthOfSpheres.tex`, which is then rendered to `py2tex/out/WildGrowthOfSpheres.pdf`. + +## To Makefile or not To Makefile? + +It is recommended that noone should just use some Makefile from the internet without understanding what it does. You should hence take a few minutes and familiarize yourself with the inner workings of the Makefile. It is not meant as a final solution, but as a starting point for anyone wanting to reliably build their thesis, ready to be extended for individual needs. If you do not feel confident with using this Makefile, but still employ techniques for incremental and reliable document building (which is highly recommended!), you might be better off setting up your own Makefile from scratch. Advice for combining LaTeX with `make` can be found on the internet. + +# Repository Details +### Authors: + +**lsspub-memoir + Build Infrastructure:** + * Frederik Hennig ([frederik.hennig@fau.de](mailto:frederik.hennig@fau.de)) + +based on +**LaTeX style for LSS publications (lsspub.sty, v1.2):** + * Markus Stürmer + * Matthias Hofmann + * Markus Holzer + +based on +**LaTeX-Style for Thesis-Titelblatt:** + * Marcus Mohr + +### Version History: + * Version 1, October 2021: Template clean-up and documentation of structure and build system \ No newline at end of file diff --git a/abstract.tex b/abstract.tex new file mode 100644 index 0000000000000000000000000000000000000000..ef56269a0dacc7bce8ce00d158514c9f275170de --- /dev/null +++ b/abstract.tex @@ -0,0 +1,20 @@ +\setlength{\absparsep}{\parskip} + +\thispagestyle{empty} +\begin{abstract} + + + +\end{abstract} +\cleardoublepage + + +\thispagestyle{empty} +\begin{otherlanguage}{ngerman} +\begin{abstract} + + + +\end{abstract} +\end{otherlanguage} +\cleardoublepage \ No newline at end of file diff --git a/acronyms.tex b/acronyms.tex new file mode 100644 index 0000000000000000000000000000000000000000..f0f66a7ba3cb58ce6fc02ee4cae9cd184f3d8b5d --- /dev/null +++ b/acronyms.tex @@ -0,0 +1,96 @@ + +\DeclareAcronym{CFD}{ + short=CFD, + long={Computational Fluid Dynamics} +} + +\DeclareAcronym{SIMT}{ + short=SIMT, + long={single-instruction multiple-threading} +} + +\DeclareAcronym{BGK}{ + short=BGK, + long={Bhatnagar-Gross-Krook} +} + +\DeclareAcronym{FD}{ + short=FD, + long={finite difference} +} + +\DeclareAcronym{FV}{ + short=FV, + long={finite volume} +} + +\DeclareAcronym{LB}{ + short=LB, + long={lattice Boltzmann}, + short-indefinite=an +} + +\DeclareAcronym{LBM}{ + short=LBM, + long={lattice Boltzmann method} +} + +\DeclareAcronym{NSE}{ + short=NSE, + long={Navier-Stokes equations} +} + +\DeclareAcronym{PDF}{ + short=PDF, + long={particle distribution function} +} + +\DeclareAcronym{SRT}{ + short=SRT, + long={single relaxation-time} +} + +\DeclareAcronym{TRT}{ + short=TRT, + long={two relaxation-time} +} + +\DeclareAcronym{MRT}{ + short=MRT, + long={multiple relaxation-time} +} + +\DeclareAcronym{SoA}{ + short=SoA, + long={structure of arrays} +} + +\DeclareAcronym{AoS}{ + short=AoS, + long={array of structures} +} + +\DeclareAcronym{MPI}{ + short=MPI, + long={message-passing interface} +} + +\DeclareAcronym{GPU}{ + short=GPU, + long={graphics processing unit} +} + +\DeclareAcronym{AST}{ + short=AST, + long={abstract syntax tree} +} + +\DeclareAcronym{MLUPS}{ + short={MLUP/S}, + long={million lattice updates per second} +} + +\DeclareAcronym{MLUPSC}{ + short={MLUP/SC}, + long={million lattice updates per second and core} +} diff --git a/chapter1.tex b/chapter1.tex new file mode 100644 index 0000000000000000000000000000000000000000..5374bbceba547a40fb7e8b920888254f4ed9bde5 --- /dev/null +++ b/chapter1.tex @@ -0,0 +1,15 @@ +\documentclass{includes/lsspub-memoir} + +\input{preamble.tex} + +% Adapt this for the correct chapter number +% For chapter N, set to N-1 +\setcounter{chapter}{0} + +\begin{document} + \input{chapters/1/c1.tex} + + \appendix + \printbibliography + +\end{document} \ No newline at end of file diff --git a/chapter2.tex b/chapter2.tex new file mode 100644 index 0000000000000000000000000000000000000000..ae83e3a1494ae1692dfd7db6bac2a9e0bff76da1 --- /dev/null +++ b/chapter2.tex @@ -0,0 +1,15 @@ +\documentclass{includes/lsspub-memoir} + +\input{preamble.tex} + +% Adapt this for the correct chapter number +% For chapter N, set to N-1 +\setcounter{chapter}{1} + +\begin{document} + \input{chapters/2/c2.tex} + + \appendix + \printbibliography + +\end{document} \ No newline at end of file diff --git a/chapters/1/c1.tex b/chapters/1/c1.tex new file mode 100644 index 0000000000000000000000000000000000000000..50df3a431286f84f690b3f3384f128160c078ae9 --- /dev/null +++ b/chapters/1/c1.tex @@ -0,0 +1,3 @@ +\chapter{Introduction} + + diff --git a/chapters/2/TenDimensionalSpheres.tex b/chapters/2/TenDimensionalSpheres.tex new file mode 100644 index 0000000000000000000000000000000000000000..9950c2f54cfbbd2bb94aa016b62e4fc4a6eb089f --- /dev/null +++ b/chapters/2/TenDimensionalSpheres.tex @@ -0,0 +1,58 @@ +\section{The Case Of Ten-Dimensional Spheres} + +The sphere of radius $r$ around a center point $\vec{x}$ in $n$-dimensional euclidean space is defined as +the set of points exactly a distance $r$ from that center; consicely +\begin{equation} + \label{eq:ndimSphere} + S_r (\vec{x}) := \left\{ + \vec{y} \in \mathbb{R}^n \; \left\vert \; \left\Vert \vec{x} - \vec{y} \right\Vert_2 = r \right. + \right\}. +\end{equation} +Now, we take $2^n$ of those spheres with unit radius and place them within +a hypercube box of sidelength $4$, centered around the origin. The sphere center +points hence become $\vec{x} = (\pm 1, \pm 1, \dots, \pm 1) \in \mathbb{R}^n$. Now, at the origin, +we place a smaller sphere that just fits within the open space between the large spheres. This setup in +two dimensions is illustrated in figure \ref{fig:boxedSpheres2d}. + +\begin{figure}[h] + \begin{center} + \includegraphics{pics/out/SpheresInBox2D.pdf} + \end{center} + \caption{Boxed spheres in 2 dimensions} + \label{fig:boxedSpheres2d} +\end{figure} + +By the Pythagorean theorem, we find the distance of each sphere's center to the origin +to be +\begin{equation} + \label{eq:sphereDistanceToOrigin} + d := \sqrt{ (\pm 1)^2 + \cdots \pm 1)^2 } + = \sqrt{n}. +\end{equation} +Thus, we also obtain the small, central sphere's radius: +\begin{equation} + \label{eq:smallSphereRadius} + s := \sqrt{n} - 1 +\end{equation} +In two dimensions, this obviously becomes $\sqrt{2} - 1 \approx 0.414$. In three dimensions, packing +a small ball between eight unit balls, we obtain $s = \sqrt{3} - 1 \approx 0.732$. The small sphere appears +to be growing at an alarming rate. Indeed, in four-dimensional space, as $s = \sqrt{4} = 1 = 2 - 1 = 1$, it +is already as large as its containing spheres! And it's still growing larger. + +Figure \ref{fig:WildGrowthOfSpheres} extrapolates the consequences of this wild growth. Remember now that within our +enclosing hypercube, it is always only a distance of two from the center to the boundary. Now, consider nine dimensions: +With $n = 9$, the central sphere's radius becomes $s = \sqrt{9} - 1 = 3 - 1 = 2$. It has reached the boundary, and is now preparing to +break out of this geometric prison we tried to hold it in. With $n = 10$, it reaches a radius of $s \approx 2.16$, and the walls are breached. + +\begin{figure}[h] + \begin{center} + \includegraphics{py2tex/out/WildGrowthOfSpheres.pdf} + \end{center} + \caption{Wild growth of enclosed spheres} + \label{fig:WildGrowthOfSpheres} +\end{figure} + +But how is this possible if the small sphere still touches all of the large spheres in the center volume, by construction? +The answer challenges our everyday understanding of spheres as perfectly smooth, round objects, because in higher dimensions, spheres +develop spikes. They squeeze through the gaps between their larger neighbors, seeking daylight. And there it seems inhumanly cruel of us that +we tried to confine such a marvelous object. Shame! diff --git a/chapters/2/c2.tex b/chapters/2/c2.tex new file mode 100644 index 0000000000000000000000000000000000000000..d6bfe755da9e195c07537cbd7d681257aeb55c13 --- /dev/null +++ b/chapters/2/c2.tex @@ -0,0 +1,6 @@ +\chapter{Fundamentals} + +In this chapter, it is attempted to convey to the reader an impression of the unexpected, but beautiful, +consequences of abstract mathematics. + +\input{chapters/2/TenDimensionalSpheres.tex} diff --git a/includes/common_includes.sty b/includes/common_includes.sty new file mode 100644 index 0000000000000000000000000000000000000000..ad0dd03e2d857ec207fc68f83d0658016b5d2979 --- /dev/null +++ b/includes/common_includes.sty @@ -0,0 +1,32 @@ + +% Graphics +\RequirePackage{graphicx} +\RequirePackage{xcolor} + +% Hyperref +\RequirePackage[pdftex]{hyperref} +\RequirePackage{url} + +\hypersetup{colorlinks=true} +\hypersetup{linkcolor=black} +\hypersetup{citecolor=black} + +% Math +\RequirePackage{amsmath} +\RequirePackage{amssymb} +\RequirePackage{physics} + +% Figures and other captions +\RequirePackage[font=small, labelfont=sc]{caption} +\RequirePackage{subcaption} + +% Acronyms +\RequirePackage{acro} + +% Text Magic +\RequirePackage[all, defaultlines=4]{nowidow} +\RequirePackage{csquotes} + +% TikZ +\RequirePackage{tikz} +\usetikzlibrary{positioning,calc,decorations.pathreplacing,shapes,arrows.meta,decorations.markings,quotes} diff --git a/includes/i10logo.pdf b/includes/i10logo.pdf new file mode 100644 index 0000000000000000000000000000000000000000..79a88c81f3d6872e12b8cce3bdb01af06e6d0a91 Binary files /dev/null and b/includes/i10logo.pdf differ diff --git a/includes/lsspub-memoir.cls b/includes/lsspub-memoir.cls new file mode 100644 index 0000000000000000000000000000000000000000..4db860efcf23515d4bfbc8078bd3da091371bec8 --- /dev/null +++ b/includes/lsspub-memoir.cls @@ -0,0 +1,212 @@ +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +% % +% LSSPUB-MEMOIR.CLS (1.0) % +% (October 2021/Frederik Hennig) % +% % +% LaTeX document class for LSS publications % +% % +% based on % +% % +% LaTeX style for LSS publications (lsspub.sty, v1.2) % +% (Nov 2011/Markus Stürmer) % +% (Jan 2013/Matthias Hofmann) % +% (Aug 2013/Markus Stürmer) % +% (Mai 2020/Markus Holzer) % +% % +% based on % +% % +% LaTeX-Style for Thesis-Titelblatt % +% (Marcus Mohr: Oct 2000) % +% (Changed: Jul 2001/Marcus Mohr) % +% % +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +% +% lsspub always activates english and ngerman for babel, but choses +% ngerman as default unless \usepackage[english]{lsspub} +% +% The title pages remain German. +% +% This style defines the following commands to set values: +% +% \lssauthor{...} sets the author(s) +% \lsstitle{...} sets the title +% \lsstype{...} describes the type (e.g. Technical Report or Master's Thesis +% \lssinstitute{...} allows to change the insitute description, defaults to +% % Lehrstuhl für Systemsimulation +% % Friedrich-Alexander-Universität Erlangen-Nürnberg +% % Erlangen, Germany +% +% This style defines the following commands to retrieve values: +% +% \lsstheauthor what has been set using \lssauthor +% \lssthetitle what has been set using \lsstitle +% \lssthetype what has been set using \lsstype +% \lsstheinstitute what has been set using \lssinstitute + +% This style defines the following macros: +% +% \makelsstitlepage create a title page (using lssauthor, lsstitle and lsstype) +% +% \makelssthesis[date]{supervisor}{advisor}{period} +% create the first three pages of a thesis, date is \today by default +% \makelsstitle creates a header (e.g. for first page of a technical report) +% optional parameter: the date to be added (no date by default) +% +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +% +% -------------------------- Copyright Message -------------------------------- +% +\typeout{**************************************************} +\typeout{ LaTeX style for LSS-Publications} +\typeout{**************************************************} +% +% ------------------------- Setup Document Class ----------------------------- +% +\LoadClass[11pt, twoside, a4paper, openright]{memoir} + +% Change this line if you intend to write in german +\RequirePackage[ngerman,main=english]{babel} +%\RequirePackage[english,main=ngerman]{babel} + +\semiisopage[9] +\checkandfixthelayout + +\nonfrenchspacing + +% Change this line if you'd like your chapter headings to be styled differently. +% Several chapter styles, and instructions to create your own, are available in +% the memoir manual. +\chapterstyle{default} + +% Change this line to set your preferred page style. +% Various page styles are listed in the memoir manual. +\pagestyle{ruled} + +\makeoddfoot{plain}{}{}{\thepage} +\setsecnumdepth{subsection} +\maxsecnumdepth{subsection} +\maxtocdepth{subsection} +% +% ------------------------- Load Graphics Packages ----------------------------- +% +\RequirePackage{fix-cm} +\RequirePackage[T1]{fontenc} +\RequirePackage[utf8]{inputenc} +\RequirePackage{graphicx} +\RequirePackage{scalefnt} +% +% --------------------------- LSS Colors ------------------------------- +\RequirePackage{xcolor} +\definecolor{lssblue}{rgb}{0.121,0.231,0.4} +\definecolor{lssred}{rgb}{0.76,0.3,0.19} +% +% --------------------------- Define Some Fonts ------------------------------- +% +%\newfont{\fonta}{cmssdc10 scaled 1628} +%\newfont{\fontb}{cmss10 scaled 1080} +%\newfont{\fontc}{cmssdc10 scaled 1600} +%\newfont{\fontd}{cmss10 scaled 1500} +\newcommand{\fonta}{\fontsize{15.5pt}{18.6pt}\fontfamily{cmss}\fontseries{sbc}\fontshape{n}\selectfont} +\newcommand{\fontb}{\fontsize{10.8pt}{12.96pt}\fontfamily{cmss}\fontseries{m}\fontshape{n}\selectfont} +\newcommand{\fontc}{\fontsize{16pt}{19.2pt}\fontfamily{cmss}\fontseries{sbc}\fontshape{n}\selectfont} +\newcommand{\fontd}{\fontsize{15pt}{18pt}\fontfamily{cmss}\fontseries{m}\fontshape{n}\selectfont} +\newcommand{\fonte}{\fontsize{10.8pt}{12.96pt}\fontfamily{cmr}\fontseries{m}\fontshape{n}\selectfont} +\newcommand{\fontf}{\fontsize{16.28pt}{19.4pt}\fontfamily{cmss}\fontseries{sbc}\fontshape{n}\selectfont} +% ----------------------------- Define Command -------------------------------- +% + +\makeatletter + +\newcommand{\lssauthor}[1]{\def\@lssauthor{#1}} +\newcommand{\lsstitle}[1]{\def\@lsstitle{#1}} +\newcommand{\lsstype}[1]{\def\@lsstype{#1}} +\newcommand{\lssinstitute}[1]{\def\@lssinstitute{#1}} + +\lssinstitute{Lehrstuhl für Informatik 10 (Systemsimulation)\\Friedrich-Alexander-Universität Erlangen-Nürnberg}% + +\lssauthor{} +\lsstitle{} +\lsstype{} +\newcommand{\makelsstitlepage}{\lsstitlepage{\@lsstitle}{\@lssauthor}{\@lsstype}} +\newcommand{\makelssthesis}[4][\today]{\lssthesis{#1}{\@lsstitle}{\@lssauthor}{\@lsstype}{#2}{#3}{#4}} +\newcommand{\makelsstitle}[1][]{\title{\@lsstitle}\date{#1}\author{\@lssauthor\ifx\@lssinstitute\@empty\relax\else\\\\\@lssinstitute}\maketitle} + +\newcommand{\lsstheauthor}{\@lssauthor} +\newcommand{\lssthetitle}{\@lsstitle} +\newcommand{\lssthetype}{\@lsstype} +\newcommand{\lsstheinstitute}{\@lssinstitute} +% +% ----------------------------- Define Command -------------------------------- +% +\newcommand{\lsstitlepage}[3]{% +\thispagestyle{empty}% +\vspace*{0.0cm}% +\begin{center}% +{\fonta FRIEDRICH-ALEXANDER-UNIVERSITÄT ERLANGEN-NÜRNBERG}\\% +{\fontb TECHNISCHE FAKULTÄT} {\fonte •} {\fontb DEPARTMENT INFORMATIK}\\[2cm]% +{\fontf Lehrstuhl für Informatik 10 (Systemsimulation)}\\[2.5ex]% +\includegraphics[scale=0.4]{includes/i10logo}\\[3.5cm] +\parbox{\textwidth}{\centering \fontc #1}\\[0.8cm]%\\[0.8cm]% +{\fontd #2}\\% +\vspace*{\fill}% +{\fontd #3} +\end{center} +\cleardoublepage} +% +% ----------------------------- Define Command -------------------------------- +% +\newcommand{\lssthesis}[7]{% +% +% +\lsstitlepage{#2}{#3}{#4} +% +% +\vspace*{-0.5cm} +\begin{center} +% +% +\thispagestyle{empty} +% +% +% +\vspace*{5cm} +\parbox{\textwidth}{\centering \fontc #2}\\[0.8cm] +% +% +{\fontd #3}\\[1ex] +{\fontb #4}\\[2cm] +% +% +\begin{tabular}{lp{0.5\textwidth}} +\fontd Aufgabensteller: & \fontd #5\\[1ex] +\fontd Betreuer: & \fontd #6\\[1ex] +\fontd Bearbeitungszeitraum: & \fontd #7 +\end{tabular}\\ +% +% +\vspace*{\fill} +% +% +\end{center} +\cleardoublepage +\thispagestyle{empty} +\begin{otherlanguage}{ngerman} +\noindent\textbf{Erklärung:}\\[2ex] +Ich versichere, dass ich die Arbeit ohne fremde Hilfe und ohne Benutzung +anderer als der angegebenen Quellen angefertigt habe und dass die Arbeit +in gleicher oder ähnlicher Form noch keiner anderen Prüfungsbehörde +vorgelegen hat und von dieser als Teil einer Prüfungsleistung angenommen +wurde. Alle Ausführungen, die wörtlich oder sinngemäß +übernommen wurden, sind als solche gekennzeichnet.\\[\lineskip] + +\noindent{}Der Universität Erlangen-Nürnberg, vertreten durch den Lehrstuhl für +Systemsimulation (Informatik 10), wird für Zwecke der Forschung und +Lehre ein einfaches, kostenloses, zeitlich und örtlich unbeschränktes +Nutzungsrecht an den Arbeitsergebnissen der \lssthetype{} einschließlich etwaiger Schutzrechte und Urheberrechte eingeräumt.\\[1.5cm] +% +Erlangen, den #1 \hfill \makebox[6cm]{\dotfill} +\cleardoublepage +\end{otherlanguage} +} + +\makeatother diff --git a/includes/lsspublogo.eps b/includes/lsspublogo.eps new file mode 100644 index 0000000000000000000000000000000000000000..0529fccaf26f6d6301d8579e1dbf393c793906ca --- /dev/null +++ b/includes/lsspublogo.eps @@ -0,0 +1,48 @@ +%!PS-Adobe-3.0 EPSF-3.0 +%%BoundingBox: 0 0 368 116 +%%HiResBoundingBox: 0 0 368.01 116 +gsave +/c {setrgbcolor} bind def +/tc {0 0 0 c} bind def +/mc {0.65 0.65 0.65 c} bind def +/bc {no c} bind def +/a {arc} bind def +/l {lineto} bind def +/m {moveto} bind def +/rf {rectfill} bind def +/t {translate} bind def +/s {t 0 1 m 1 1 1 180 270 a 2 0 1 0 90 a} bind def +[29 0 8.7 29 0 0] concat +0.3 0.1 t +tc +0 0 1.75 1.75 rf +1.75 1.75 1.75 1.75 rf +0 2.5 1 1 rf +2.5 0 1 1 rf +-0.3 0.3 t +mc +0 0 1.75 1.75 rf +1.75 1.75 1.75 1.75 rf +0 2.5 1 1 rf +2.5 0 1 1 rf +4.3 -0.3 t +tc +0 0 m +3.25 1 1 270 0 a +4.25 0 l +6.25 1 1 270 0 a +1 1 l +1 3.5 l +0 3.5 l +1.25 1.25 s +3 0 s +-3 1.25 t +6 0 m +6 1 l +4 0 1 90 180 a +3 1 l +1 0 1 90 180 a +fill +grestore +showpage +%%EOF diff --git a/includes/lsspublogo.pdf b/includes/lsspublogo.pdf new file mode 100644 index 0000000000000000000000000000000000000000..1a2beea0c6fc1bef16775c9f2f16733d1e3aca5e Binary files /dev/null and b/includes/lsspublogo.pdf differ diff --git a/pics/SpheresInBox2D.tex b/pics/SpheresInBox2D.tex new file mode 100644 index 0000000000000000000000000000000000000000..14e7e0e684f69a8c2fc8ac7084355ee14ba1cf0c --- /dev/null +++ b/pics/SpheresInBox2D.tex @@ -0,0 +1,24 @@ +\documentclass{graphic_standalone} + +\begin{document} + \begin{tikzpicture}[x=1.5cm, y=1.5cm] + \draw[black, thick] (-2, -2) rectangle (2, 2); + \foreach \x in {-1, 1}{ + \foreach \y in {-1, 1}{ + \filldraw[fill=black!20!white, draw=black] (\x, \y) circle (1); + } + } + + \filldraw[fill=lssblue!20!white, draw=lssblue] (0,0) circle (0.414); + + \draw[lssblue, thick, decorate, decoration={brace}] (-0.3, -0.3) -- (0, 0) + node[midway, above, sloped] {$s$}; + + \draw[black!80!white, thick, decorate, decoration={brace}] (-1, -1) -- (-0.3, -0.3) + node[midway, above, sloped] {$r = 1$}; + + \draw[lssred, thick, decorate, decoration={brace}] (-2, -2) -- (-1,-1) + node[pos=0.6, above, sloped] {$d = \sqrt{2}$}; + + \end{tikzpicture} +\end{document} diff --git a/pics/graphic_standalone.cls b/pics/graphic_standalone.cls new file mode 100644 index 0000000000000000000000000000000000000000..d61d8cc20d80331616cc9a9bee5e0a5caf3b8d43 --- /dev/null +++ b/pics/graphic_standalone.cls @@ -0,0 +1,9 @@ +\LoadClass{standalone} + +\RequirePackage{../includes/common_includes} + +\RequirePackage{xcolor} +\definecolor{lssblue}{rgb}{0.121,0.231,0.4} +\definecolor{lssred}{rgb}{0.76,0.3,0.19} + +% Add any other packages or definitions you need for your standalone pictures diff --git a/preamble.tex b/preamble.tex new file mode 100644 index 0000000000000000000000000000000000000000..76b6ab55825ff87636a053bea9fb9458124f65ba --- /dev/null +++ b/preamble.tex @@ -0,0 +1,20 @@ + +% Common Packages +\usepackage{includes/common_includes} + +% Bibliography + +\usepackage[backend=biber, % replace bibtex with biber (bibliography backend engine) + bibstyle=ieee, % write literature lists in IEEE style + citestyle=numeric-comp, % \cite uses a numeric key + sortcites=true, + maxbibnames=30, + bibencoding=utf8] +{biblatex} +\addbibresource{sources.bib} + +% Other includes + +\input{acronyms.tex} + +\usepackage{lipsum} diff --git a/py2tex/WildGrowthOfSpheres.py b/py2tex/WildGrowthOfSpheres.py new file mode 100644 index 0000000000000000000000000000000000000000..95720b8652d875396286b5a7b39cd3e623241e88 --- /dev/null +++ b/py2tex/WildGrowthOfSpheres.py @@ -0,0 +1,39 @@ +import numpy as np +import matplotlib.pyplot as plt +import tikzplotlib as tikzplt + +from os import path + +OUTDIR = "out" + +SCRIPT_FILENAME = path.split(__file__)[1] +OUTPUT_FILENAME = path.join(OUTDIR, path.splitext(SCRIPT_FILENAME)[0] + ".tex") + +LSSBLUE = (0.121,0.231,0.4) +LSSRED = (0.76,0.3,0.19) +LSSGREEN = "#1F6622" + +cm = 1/2.54 +W, H = 13, 5 + +TIKZPLOT_PARAMS = { + 'standalone' : True, + 'strict': True, + 'extra_axis_parameters' : ["scaled x ticks=false", "scaled y ticks=false"], + 'axis_width': f"{W}cm", + 'axis_height': f"{H}cm", +} + +fig, ax = plt.subplots(figsize=(W*cm, H*cm)) + +ns = np.arange(1, 13, step=1) +radii = np.sqrt(ns) - 1 + +ax.grid() +ax.set_xlabel(r'$n$') +ax.set_ylabel(r'$s$') + +ax.plot(ns, radii, marker='s', color=LSSRED, lw=0.5, markersize=4) + +fig.tight_layout() +tikzplt.save(OUTPUT_FILENAME, figure=fig, **TIKZPLOT_PARAMS) diff --git a/sources.bib b/sources.bib new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/thesis.tex b/thesis.tex new file mode 100644 index 0000000000000000000000000000000000000000..120ec886a18a3f88e254f1932fbf00484672f939 --- /dev/null +++ b/thesis.tex @@ -0,0 +1,71 @@ +\documentclass[english]{includes/lsspub-memoir} + +\input{preamble.tex} + +% Thesis Options + +\lsstitle{ + Your Title +}% +\lssauthor{Your Name}% +\lsstype{Bachelorarbeit}% + +\hypersetup{pdfauthor=\lsstheauthor} +\hypersetup{pdftitle=\lssthetitle} +\hypersetup{pdfsubject={\lssthetype, Informatik 10, Universität Erlangen-Nürnberg}} + + +% Main Document + +\begin{document} + + + %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + % Front Matter + \frontmatter + + % Generate the title page and declaration + \makelssthesis[\today]{Your Supervisor}{Your Advisor}{Start Date - End Date} + + \input{abstract.tex} + + % Table of Contents + \tableofcontents* + \cleardoublepage + + % Various lists + % You may put these at the end of the document, too, if you'd like. + \listoffigures + \cleardoublepage + + \listoftables + \cleardoublepage + + \printacronyms[name = {List of Acronyms}] + \addcontentsline{toc}{chapter}{List of Acronyms} + \cleardoublepage + %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + + + + %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + % Main Matter - Actual Contents + \mainmatter + + \input{chapters/1/c1.tex} + \input{chapters/2/c2.tex} + + %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + + + + %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + % Back Matter - Appendices, Bibliography, etc. + \backmatter + \appendix + + \cleardoublepage + \printbibliography + %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + +\end{document} \ No newline at end of file