Archive for the ‘Artikel’ Category.

Beamer Slides Template using Source Sans Fonts

Here’s a short example for a Beamer slide template using the Adobe Source Sans fonts.

\documentclass[12pt,ngerman]{beamer}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{booktabs}
\usepackage{babel}
\usepackage{graphicx}
\usepackage{csquotes}
\usepackage{paralist}
\usepackage{xcolor}
\usepackage{listings}
\usepackage{sourcesanspro}
\usepackage{sourcecodepro}
 
\definecolor{colBack}{rgb}{1,1,0.8}
\definecolor{colKeys}{rgb}{0,0,1}
\definecolor{colIdentifier}{rgb}{0,0,0}
\definecolor{colComments}{rgb}{1,0,0}
\definecolor{colString}{rgb}{0,0.5,0}
 
\lstset{%
    float=hbp,%
    basicstyle=\ttfamily\footnotesize, %
    identifierstyle=\color{colIdentifier}, %
    keywordstyle=\color{colKeys}, %
    stringstyle=\color{colString}, %
    commentstyle=\color{colComments}, %
    columns=flexible, %
    tabsize=2, %
    frame=single, %
    extendedchars=true, %
    showspaces=false, %
    showstringspaces=false, %
    numbers=left, %
    numberstyle=\tiny, %
    breaklines=true, %
    backgroundcolor=\color{colBack}, %
    breakautoindent=true, %
    captionpos=b%
}
 
\author{Uwe Ziegenhagen}
\title{Titel der Präsentation}
\institute{Köln}
 
\begin{document}
\frame{
	\maketitle
}
 
\frame[containsverbatim]{
\frametitle{Titel der Folie}
\framesubtitle{Untertitel der Folie}
 
\begin{itemize}
\item Erstes Item
\item Zweites Item
\item Drittes Item
\end{itemize}
 
\lstinputlisting[language={[LaTeX]TeX},basicstyle=\ttfamily\tiny,linerange={1-12},caption={Auszug aus der Präambel dieser Präsentation},label={lis:tex01}]{\jobname.tex}
}
 
\end{document}

source1

source2

Uwe

Uwe Ziegenhagen likes LaTeX and Python, sometimes even combined. Do you like my content and would like to thank me for it? Consider making a small donation to my local fablab, the Dingfabrik Köln. Details on how to donate can be found here Spenden für die Dingfabrik.

More Posts - Website

Animating TikZ Graphics

After drawing the cubic Bezier a few days ago I wanted to animate it. Using the animate package this is fairly simple:

\documentclass{article}
\usepackage[paperwidth=5.5cm,paperheight=5.3cm,left=0cm,right=0cm,bottom=0cm,top=0.25cm]{geometry}
\usepackage{tikz}
\definecolor{fom}{RGB}{0,153,139}
 
\newcommand{\dat}{0.7} % 0.67
\usepackage{animate}
 
\begin{document}
 
\begin{animateinline}[poster=last, controls, palindrome]{10}
\multiframe{70}{Ry=0.1+0.01}{
\begin{tikzpicture}[x=4cm,y=4cm]
\draw[line width=1pt,lightgray] (0,0) -- (1,1);
\draw (0,0) -- (1,0) -- (1,1) -- (0,1) -- (0,0); 
\draw (0,0) -- (0.17,0.67); 
\draw (1,1) -- (0.83,\Ry); 
 
\draw [magenta,fill=magenta](0.17,0.67) circle (.5ex); 
\draw [fom,fill=fom](0.83,\Ry) circle (.5ex); 
 
\draw[line width=1pt] (0,0) .. controls (0.17,0.67) and (0.83,\Ry) .. (1,1);
 
\node[label={[label distance=0.0cm,text depth=-1ex,rotate=90]left:Fortschritt in \%}] at (-0.1,.8) {};
\node[label={[label distance=0.0cm,text depth=-1ex]right:Zeit-Achse}] at (0,-0.05) {};
\end{tikzpicture}}
\end{animateinline}
 
\end{document}

I am animating in the TeX code (not externally) so I use animateinline with 10 frames per second. Inside this environment I prepare 70 frames, where I have the y-coordinate of the second point loop from 0.1 in steps of 0.01. The looping is controlled via Ry (that translates to \Ry in the loop). That’s it!

Here is the resulting PDF: bezier

PS: I used pdflatex from the TeX Live 2014.

Uwe

Uwe Ziegenhagen likes LaTeX and Python, sometimes even combined. Do you like my content and would like to thank me for it? Consider making a small donation to my local fablab, the Dingfabrik Köln. Details on how to donate can be found here Spenden für die Dingfabrik.

More Posts - Website

Installing & using the nonfreefonts in TeX Live 2013

Update 2017-12-10: Markus Kohm told me there were some changes:

  • getnonfreefonts --all does not work anymore
  • the best way is getnonfreefonts --sys

Original article:

Since there was a question on TSX how to use Arial in a LaTeX document I had a closer look on the nonfreefonts stuff and want to share this knowledge.

What’s it all about?

There are various fonts available on CTAN which — due to copyright/licensing stuff — can’t make it to the TeX Live DVD. These fonts are:

  • Arial by URW
  • Classico by URW
  • DayRoman by Apostrophiclabs
  • Euro symbols by Adobe
  • GaramondNo8 by URW
  • GaramondNo8 Expert by Michael Sharpe
  • LetterGothic by URW
  • LuxiMono by Bigelow & Holmes
  • VnTeX nonfree by Hàn Thế Thành
  • Webomints by Galapagos Design Group

How to install them

Since they’re not on the DVD these fonts need to be installed separately. Font installation for TeX is always tidious (copy these files there, some other files there, update this file) so Reinhard Kotucha created a script which does these nasty things for us. The good thing is, this script works on all TeX Live platforms.

Step 1: Getting the script

If you’re on any Linux/Unix platform run:


wget http://tug.org/fonts/getnonfreefonts/install-getnonfreefonts
texlua install-getnonfreefonts

If you’re on Windows, either install wget (always a good idea) or visit http://www.tug.org/fonts/getnonfreefonts/ with your browser and download the installer linked there. Afterwards just run texlua on the file, it will take care of the script-installation.


J:\>texlua install-getnonfreefonts
Detected System: win32
Detected Installation: C:/texlive/2013
mkdir C:/texlive/2013/texmf-dist/scripts/getnonfreefonts ...             [done]
Installing texmf-dist/scripts/getnonfreefonts/getnonfreefonts.pl ...     [done]
Installing texmf-dist/doc/man/man1/getnonfreefonts.1 ...                 [done]
Installing texmf-dist/doc/man/man1/getnonfreefonts-sys.1 ...             [done]
Installing texmf-dist/doc/man/man1/getnonfreefonts.man1.pdf ...          [done]
Installing texmf-dist/doc/man/man1/getnonfreefonts-sys.man1.pdf ...      [done]
md5sum: eb97b3fe32b28ead5183275ad32699b8 getnonfreefonts.pl ...            [ok]
md5sum: f850d910dd96ee27cecdb3772047d247 getnonfreefonts.1 ...             [ok]
md5sum: fb2b0f7699db8e627d4e26b730e94928 getnonfreefonts-sys.1 ...         [ok]
md5sum: 415b51f7c80a4abe8d0a667a04c9d525 getnonfreefonts.man1.pdf ...      [ok]
Creating wrappers in 'bin/win32' ...                                           1
 Datei(en) kopiert.
        1 Datei(en) kopiert.
  [done]
texhash: Updating C:/texlive/2013/texmf-dist/ls-R...
texhash: Updated C:/texlive/2013/texmf-dist/ls-R.
texhash: Done.

J:\>

Step 2: Installing the fonts

Just run getnonfreefonts --all to install all the fonts in your user texmf directory ($TEXMFHOME) or
getnonfreefonts-sys --all to install to the system directory ($TEXMFLOCAL).

J:\>getnonfreefonts --all
--2014-03-30 09:51:38--  http://tug.org/~kotucha/getnonfreefonts/getfont2013
Resolving tug.org... 130.225.2.178
Connecting to tug.org|130.225.2.178|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 23858 (23K)
Saving to: `getfont2013'

100%[======================================>] 23,858      --.-K/s   in 0.1s

2014-03-30 09:51:38 (223 KB/s) - `getfont2013' saved [23858/23858]

------------------------------------------
Installation directory: C:/Users/Uwe/texmf
------------------------------------------

Package 'arial-urw':
====================

--2014-03-30 09:51:39--  http://ctan.org/tex-archive/fonts/urw/arial.zip
Resolving ctan.org... 176.28.54.184
Connecting to ctan.org|176.28.54.184|:80... connected.
HTTP request sent, awaiting response... 302 Moved Temporarily
Location: http://mirrors.ctan.org/fonts/urw/arial.zip [following]
--2014-03-30 09:51:39--  http://mirrors.ctan.org/fonts/urw/arial.zip
Resolving mirrors.ctan.org... 176.28.54.184
Reusing existing connection to ctan.org:80.
HTTP request sent, awaiting response... 302 Found
Location: ftp://ftp.tu-chemnitz.de/pub/tex/fonts/urw/arial.zip [following]
--2014-03-30 09:51:39--  ftp://ftp.tu-chemnitz.de/pub/tex/fonts/urw/arial.zip
           => `arial.zip'
Resolving ftp.tu-chemnitz.de... 134.109.228.1
Connecting to ftp.tu-chemnitz.de|134.109.228.1|:21... connected.
Logging in as anonymous ... Logged in!
==> SYST ... done.    ==> PWD ... done.
==> TYPE I ... done.  ==> CWD /pub/tex/fonts/urw ... done.
==> SIZE arial.zip ... 249649
==> PASV ... done.    ==> RETR arial.zip ... done.
Length: 249649 (244K)

100%[======================================>] 249,649      656K/s   in 0.4s

2014-03-30 09:51:40 (656 KB/s) - `arial.zip' saved [249649]

4ad05e902e727fecc4f55f8d737e10a5  arial.zip                 [MD5sum ok]

Extracting 'arial.zip'...                                   [done]
Installing 'ua1.map'...                                     Creating new config
file c:/users/uwe/.texlive2013/texmf-config/web2c/updmap.cfg
[done]

Step 3: Using the fonts

Under http://www.tug.dk/FontCatalogue/lettergothic/
you will find an example how to use for example the lettergothic font.

\documentclass[12pt,ngerman]{scrartcl}
 
\usepackage[scaled]{ulgothic}
\renewcommand*\familydefault{\ttdefault} %% Only if the base font of the document is to be typewriter style
\usepackage[T1]{fontenc}
 
\begin{document}
 
\noindent Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nullam dictum felis a nibh, eu condimentum lectus auctor. Cras quis euismod lorem. Aliquam in nisi felis. Etiam sit amet mauris at magna rhoncus commodo. Nulla neque ipsum, condimentum in nibh sed, eleifend consectetur est. Suspendisse ac laoreet urna. Vivamus sit amet tempor nunc, ac porta mi. Pha\-sellus et ligula ullamcorper, congue ligula non, porta purus. Etiam cursus eros ante, sit amet porta enim adipiscing sed. Vestibulum hendrerit erat a tellus dignissim, sit amet lao\-reet est suscipit. 
 
\end{document}

gothic

Step 4: Overview of all examples

Arial

\usepackage[scaled]{uarial}
\renewcommand*\familydefault{\sfdefault} %% Only if the base font of the document is to be sans serif
\usepackage[T1]{fontenc}

Classico

\renewcommand*\sfdefault{uop}
\renewcommand*\familydefault{\sfdefault} %% Only if the base font of the document is to be sans serif
\usepackage[T1]{fontenc}

DayRoman

\renewcommand*\rmdefault{dayrom}
\usepackage[T1]{fontenc}

Garamond

\usepackage[urw-garamond]{mathdesign}
\usepackage[T1]{fontenc}

Garamond Expert

\usepackage[T1]{fontenc}
\usepackage[urw-garamond]{mathdesign}
\usepackage{garamondx}

Letter Gothic

\usepackage[scaled]{ulgothic}
\renewcommand*\familydefault{\ttdefault}
\usepackage[T1]{fontenc}

Luxi Mono

\usepackage{luximono}
\renewcommand*\familydefault{\ttdefault}
\usepackage[T1]{fontenc}

webomints

See http://www.ctan.org/tex-archive/fonts/webomints

Uwe

Uwe Ziegenhagen likes LaTeX and Python, sometimes even combined. Do you like my content and would like to thank me for it? Consider making a small donation to my local fablab, the Dingfabrik Köln. Details on how to donate can be found here Spenden für die Dingfabrik.

More Posts - Website

Generating math exercises for kids with LuaLaTeX

Arno T. has sent me a nice piece of LuaLaTeX code that does more or less the same thing as my Python code. I guess, I should have a closer look at LuaLaTeX.

\documentclass{scrartcl}
\usepackage{booktabs}
\usepackage{luacode}
\usepackage{longtable}
 
\begin{document}
\begin{longtable}{rcrcl}
\toprule
\luaexec{
function round(num, idp)
local mult = 10^(idp or 0)
return math.floor(num * mult + 0.5) / mult
end
random = math.random
tp = tex.print
%
min = 1
max = 10
math.randomseed(os.time())
for i = 1,20 do
a = random(min,max)
b = random(min,max)
op = random(1,4)
if (op==1) then
c = a+b
tp(a.."&+&"..b.."&=&"..c.."\\\\")
elseif (op==2) then
c = a-b
tp(a.."&-&"..b.."&=&"..c.."\\\\")
elseif (op==3) then
c = a*b
tp(a.."&*&"..b.."&=&"..c.."\\\\")
elseif (op==4) then
c = a/b
tp(a.."&/&"..b.."&=&"..round(c,3).."\\\\")
end
end
tex.print("\\bottomrule")
}
\end{longtable}
\end{document}

Uwe

Uwe Ziegenhagen likes LaTeX and Python, sometimes even combined. Do you like my content and would like to thank me for it? Consider making a small donation to my local fablab, the Dingfabrik Köln. Details on how to donate can be found here Spenden für die Dingfabrik.

More Posts - Website

Create Templates for Lumi Inkodye

Here’s a simple example how to prepare a TeX file to print on a T-shirt using the Lumi Inkodye. What’s Lumi? Just have a look at the following video: Lumi on Youtube

The LaTeX template is pretty simple. As I want Acrobat Reader to scale the graphics I’m fine with a very small pagesize, no need for A4 paper. The margins are neglectable as well.

\documentclass{article}
\usepackage{lmodern}
\usepackage[top=1pt,bottom=1pt,left=1pt,
right=1pt,paperwidth=1.5cm,paperheight=1cm]{geometry}
\pagestyle{empty}
\usepackage{xcolor}
\pagecolor{black}
\begin{document}
 
\begin{center}\bfseries
\textcolor{white}{\LaTeX \\ fetishist}
\end{center}
 
\end{document}

PDF

LaTeX fetishist print

I add photos once I’ve tried Lumi on a shirt…

Uwe

Uwe Ziegenhagen likes LaTeX and Python, sometimes even combined. Do you like my content and would like to thank me for it? Consider making a small donation to my local fablab, the Dingfabrik Köln. Details on how to donate can be found here Spenden für die Dingfabrik.

More Posts - Website

Vorlage für Jour Fixe Protokolle / Template for Jour Fixe protocols

Ausgehend von Vorlage für Gesprächsprotokolle hat mir Stefan Wollny, ein Leser des Blogs, eine schicke Vorlage für Jour Fixe Protokolle geschickt.

Hier die Vorlage_Jour-Fix-Protokoll PDF-Datei, hier der Quellcode:

%% basierend auf http://uweziegenhagen.de/?p=1109
%% gefunden am 15.03.2013
%% 
%%
\PassOptionsToPackage{table}{xcolor}	% Notwendig, damit die Zeilen-Colorierung funktioniert
\documentclass[]{scrartcl}
\usepackage{palatino,url}
\usepackage[T1]{fontenc}		% Vor {inputenc}! http://uweziegenhagen.de/?p=1644
\usepackage[latin1]{inputenc}		% in Uwes Vorgabe noch anders herum
\usepackage[german,ngerman]{babel}	% Alte Hunde lernen keine neuen Tricks
\usepackage[a4paper,top=30mm,left=25mm,right=20mm,bottom=23mm,headsep=12mm,footskip=12mm]{geometry}
\usepackage{textcomp,eurosym}
\usepackage{graphicx}
\usepackage{longtable}
\usepackage{booktabs,paralist}
\usepackage{url}
\usepackage{pgfgantt}
\usepackage{xcolor,soul}
%% Hervorhebungen	\hl{text}
%% Farbe Hervorhebungen \sethlcolor{yellow}  oder {red} oder {green}
%% Unterstreichungen	\ul{text}
%% Farbe Unterstreichungen \setulcolor{yellow}  oder {red} oder {green}
%% Durchstreichungen	\st{text}
%% Farbe Durchstreichungen \setstcolor{yellow}  oder {red} oder {green}
%% Kapitälchen		\caps{text}
%% Letterspacing	\so{text}
\definecolor{LinkColor}{rgb}{0,0,0.5}
%
\definecolor{cell}{RGB}{220,230,240}
\definecolor{line}{RGB}{80,130,190}
\renewcommand{\arraystretch}{1.25}
%
\usepackage[]{changebar}
\newcommand{\cb}[1]{\begin{changebar}#1\end{changebar}}
%
\usepackage[flushmargin]{footmisc}
\renewcommand{\thempfootnote}{\alph{mpfootnote}}
\usepackage{scrpage2,lastpage}
\clearscrheadfoot
%
% nur bei gesetzem twoside
%\lehead{lehead} \cehead{cehead}
%\rehead{rehead} \lefoot{lefoot}
%\cefoot{cefoot} \refoot{refoot}
%
%\lohead{lohead} \cohead{cohead}
%\rohead{rohead} \lofoot{lofoot}
%\cofoot{cofoot}
%
\lohead{Flying Circus \\ Finanzen}
\rohead{\includegraphics[scale=0.15]{puf200X172}}
\lofoot{\today}
\rofoot{Seite \thepage~ von \pageref{LastPage}}
\pagestyle{scrheadings}
%
\usepackage[%
	pdftitle   ={Gespraechsprotokoll},%
	pdfauthor  ={Duck, Donald},%
	pdfcreator ={pdflatex with hyperref},%
	pdfsubject ={Projekt X},%
	pdfkeywords={Gold, Geldspeicher, Inventur}]{hyperref}
\hypersetup{%
	colorlinks =true,%
	linkcolor  =LinkColor,%
	citecolor  =LinkColor,%
	filecolor  =Linkcolor,%
	menucolor  =LinkColor,%
	urlcolor   =LinkColor,%
	breaklinks =true}
%
%
%
\begin{document}
%
\begin{flushleft}
 {\LARGE \textbf{Jour-Fix Protokoll}}
\end{flushleft}
%
\begin{tabular}{rp{5.4cm}lp{5.4cm}} \toprule
 Datum & \textbf{13.03.2013} Rev. 2 & & \\
 Protokollant & Duck, Donald & & \\
 Anwesend & Duck, Dagobert (Chair)	& Abwesend & Gans, Gustav (Luckiness) \\
  & Duck, Daisy (COO) 		&	   & Goofy (Fatality) \\
  & Duck, Tick (Clever-1)			&	& Pluto (Security) \\ 
  & Duck, Trick (Clever-2)		&	& \\ 
  & Duck, Track (Clever-3)		&	& \\ \bottomrule
\end{tabular}
%
%\arrayrulecolor{line}
%\rowcolors{2}{cell}{white}
\begin{small}
\setlength\LTleft{0pt}
\setlength\LTright{0pt}
\begin{flushleft}
\begin{longtable}{p{0.2cm}p{0.3cm}p{9.9cm}p{2.4cm}l} \toprule
lfd. Nr.	& Art\footnotemark[1] %\footnote{I: Information | A: Aufgabe | B: Beschluß | N: Nachtrag}	
	& Thema
	& Verantwortlich/ Referent
	& Termin	\\ \midrule \endfirsthead
\hline
lfd. Nr.	& Art
	& Thema
	& Verantwortlich/ Referent
	& Termin	\\ \midrule \endhead
%
 
\rowcolor{blue!10}
\textbf{1.}
	&	% Keine Art in der Betreffzeile	
	& \textbf{Reinigung Geldspeicher}			
	& \textbf{Duck, Donald}	
	& \\
	& I	
	& Die Reinigung erwies sich als schwieriger, als zunächst gedacht. Durch wiederholte Besuche der Gebrüder \caps{Panzerknacker} wurde die zwischenzeitliche Ordnung derart durcheinander gebracht, daß zunächst das Eintreffen der Entenhausener Polizei abgewartet werden mußte, um selbige wieder herzustellen.
	& Duck, Donald	\\ \cline{2-5}
	& A	
	& Bericht im nächsten JF	
	& Duck, Donald	
	& 2.04.2013 \\ \cline{2-5}
	& A	
	& Bericht im übernächsten JF	
	& Duck, Donald	
	& 22.04.2013 \\ \cline{2-5}
	& N	
	& Im Nachgang zur Besprechnung wurde bekannt, daß die Hexe \begin{changebar}\caps{Gaukeley, Gundel}\end{changebar} aus der Haft auf dem Brocken entlassen werden mußte. Sie hatte den Gefängisdirektor in eine Maus verwandelt, was das Interesse der Gefängniskatze wecke. Erst nachdem er versprach, Frau \caps{Gaukeley} zu entlassen, wurde er wieder zurückverwandelt.
	& Duck, Donald	
	&  \vspace*{0.2cm} \\
%
\rowcolor{blue!10}
\textbf{2.}
	&	% Keine Art in der Betreffzeile	
	& \textbf{Goldmachmaschine}
	& \textbf{Dr. Düsentrieb, Daniel}
	& \\
	& I
	& \caps{Dr. Düsentrieb} wird erst wieder in der KW 15 in Entenhausen sein.
	& Duck, Donald
	& \vspace*{0.2cm} \\
%
 
\rowcolor{blue!10}
\textbf{3.}
	&	% Keine Art in der Betreffzeile	
	& \textbf{Lotterie}			
	& \textbf{Gans, Gustav}	
	& \\
	& 
I	
	& Herr Gans läß sich entschuldigen: Nach dem letzten ungeplanten Lotteriegewinn hat er einen kurzfristig anberaumten Termin mit seinem Steuerberater, Herrn Hartz, damit die Finanzierung von \textit{La Dolce Vita} nicht durch eine unangekündigte  Buchprüfung der Wirtschaftsprüfungsgesellschaft \caps{Troika \& Co.} oder durch eine \textit{Bäng-Bäng}-Affäre gestört wird.
	& Duck, Donald	
	& \\ \cline{2-5}
	& A	
	& Bericht zum Sachstand der Ausbeutung im nächsten JF	
	& Gans, Gustav	
	& 2.04.2013 \vspace*{0.2cm} \\
%
 
\rowcolor{blue!10}
\textbf{4.}
	&	% Keine Art in der Betreffzeile	
	& \textbf{Steueroptimierung}
	& \textbf{Duck, Daisy}
	& \\
	& I
	& Bei der zypriotischen Regierung wurde angefragt, was 'Steuern' sind. Solange die Antwort auf sich warten läßt, wurde zusammen mit der Spielbank 'Silberjunge Schwab' ein innovatives, die Sinne vernebelndes Finanzprodukt aufgelegt, daß die Beteiligten aufgrund ihrer internationalen Verflechtungen unzweifelhaft als systemrelevant qualifiziert, da die Anleger in jedem Fall alles verlieren werden.
	& Duck, Daisy	
	& \\ \cline{2-5}
	& A	
	& Bericht zum Sachstand der \euro -Gefälligkeiten
	& Gans, Gustav	
	& 2.04.2013 \vspace*{0.2cm} \\
%
\newpage
\rowcolor{blue!10}
\textbf{5.}
	&	% Keine Art in der Betreffzeile	
	& \textbf{Auskunftsersuche IBF}			
	& \textbf{Duck, Trick}	
	& \\
	&  \vspace*{0.2cm}
I	
	& Das Fachkonzept wurde mit der Anwaltskanzlei \caps{Nostra Casa \& Cie.} ausfühlich besprochen. Alle offenen Punkte wurden ungeklärt in die Kanalisation gespült. Eine Gefahr für die Kanalisation bestand zu seinem Zeitpunkt; marginale Kollateralschäden bei Menschen, Kindern und Frauen (!) sind eingepreist. Die Risiken konnten auf die UE geswappt werden.
	& Duck, Trick	
	&	\\ \cline{2-5}
	& A	
	& Bericht im nächsten JF	
	& Duck, Track	
	& 2.04.2013 \vspace*{0.2cm} \\
%
\rowcolor{blue!10}
\textbf{6.}
	&	% Keine Art in der Betreffzeile	
	& \textbf{Liquidität}
	& \textbf{Duck, Dagobert}
	& \\
	& I
	& Herr Duck informierte über die aktuelle Goldbad-Temperatur. Das Thermometer wies in letzter Zeit eine auffällige Korrelation zum Aktienkurs der 'Germanian Bunk Ltd.`` auf, die auch der Entenhausener Handelszeitung nicht entgangen war. \caps{Don Corleone} wurde informiert.
	& Duck, Dagobert
	& \vspace*{0.2cm} \\
%
\rowcolor{blue!10}
\textbf{7.}
	&	% Keine Art in der Betreffzeile	
	& \textbf{Fort Knox - Goldschatz}			
	& \textbf{Duck, Dagobert}	
	& \\
	&  \vspace*{0.2cm}
I	
	& Die Analyse der Sicherheitsvorkehrungen ist noch nicht abgeschlossen. \caps{Kater Karlo} verweigert leider noch immer die Kooperation, so daß ein persönlicher Besuch vor Ort wohl unumgänglich sein wird.
	&	\\ \cline{2-5}
	& A	
	& Bericht im nächsten JF	
	& Duck, Donald	
	& 2.04.2013 \vspace*{0.2cm} \\
%
%\newpage
\rowcolor{blue!10}
\textbf{8.}
	&	% Keine Art in der Betreffzeile	
	& \textbf{Hr. M. aus N.}
	& \textbf{Destructivus, Tullius}
	& \\
	& I
	& Hr. D. läßt ausrichten, daß es ihn nie gegeben habe und daß er jeden anderweitigen Hinweis unerbittlich bis zum groß-imperialen Zwischenhändler verfolgen wird, sollte jemand etwas anderes behaupten. Da der 'ehrenwerte Richter' \textit{leider} drei Kinder hat, erübrigt sich ein Erscheinen vor dem hohen Gerüst und ein neuer Termin.
	& Duck, Donald
	& \vspace*{0.2cm} \\
%
\rowcolor{blue!10}
\textbf{9.}
	&	% Keine Art in der Betreffzeile	
	& \textbf{Las Vegas}			
	& \textbf{Duck, Dagobert}	
	& \\
	&  \vspace*{0.2cm}
I	
	& Der Betriebsauflug nach L.V. war ein voller Erfolg: Anders als beim letzt-jährigen Ausflug nach Hawaii störte diesmal nicht die Werbung für das Softeis 'Magnam'.  Als \textit{dernier-crie} erwies sich vielmehr 'Hokus-Pokus-13', was einigen Geschäftspartnern gleichwohl sauer aufstieß \ldots
	& Duck, track
	&	\\ \cline{2-5}
	& A	
	& Bullizei-Bericht im nächsten JF	
	& Duck, Donald	
	& 2.04.2013 \vspace*{0.2cm} \\
%
\rowcolor{blue!10}
\textbf{10.}
	&	% Keine Art in der Betreffzeile	
	& \textbf{'Noch ein Bit?' - Liquidität der Falschen}
	& \textbf{Dr. Peulaner}
	& \\
	& I
	& \caps{Dr. Peulaner} wird erst wieder in der KW 15 nüchtern sein.
	& Duck, Donald
	& \vspace*{0.2cm} \\
%
\rowcolor{blue!10}
\textbf{11.}
	&	% Keine Art in der Betreffzeile	
	& \textbf{Termine}
	&
	& \\
	& B
	& Nächster JF
	& alle
	& 2.04.2013 \\
	& B
	& Nächster Workshop ``Tresore öffnen - 101''
	& PK1/Pk2 & 4.04.2013 \\
	& I
	& Nächste Sitzung des Lenkungsausschusses
	&
	& 5.04.2013 \\ \bottomrule 
\end{longtable}
\footnotetext[1]{I: Information | A: Aufgabe | B: Beschluß | N: Nachtrag}
\end{flushleft}
\end{small}
%
\end{document}

Uwe

Uwe Ziegenhagen likes LaTeX and Python, sometimes even combined. Do you like my content and would like to thank me for it? Consider making a small donation to my local fablab, the Dingfabrik Köln. Details on how to donate can be found here Spenden für die Dingfabrik.

More Posts - Website

Slides for my ‚Sphinx‘ presentation in Giessen

Here are the slides for my presentation on ‚Sphinx‘, the Python-based publishing tool.

UweZiegenhagen-Sphinx (PDF)

HTML Export example

Uwe

Uwe Ziegenhagen likes LaTeX and Python, sometimes even combined. Do you like my content and would like to thank me for it? Consider making a small donation to my local fablab, the Dingfabrik Köln. Details on how to donate can be found here Spenden für die Dingfabrik.

More Posts - Website

BibLaTeX & biber workflow example

Here a simple example to illustrate the workflow with biblatex and biber (on TeX Live 2012). It also prints a second bibliography just for the books (one in this case)

literaturvz.bib contains:

@Article{lit1,
author = {Nabuurs, S.B. and Spronk, C.A.E.M.},
title = {Biomolecular Structure Determination by NMR Spectroscopy Allows for Major Errors},
year ={2006},
volume = {2},
journal = {PLoS Comput. Biology}}

@Article{lit2,
author = {Exner, T. E. and Mezey, P. G.},
title = {The Field-Adapted ADMA Approach: Introducing Point Charges},
year ={2004},
volume ={108},
journal = {J. Phys. Chem. A}}

@Article{lit3,
author = {Exner, T. E. and Mezey, P. G.},
title = {Ab Initio Quality Properties for Macromolecules Using the ADMA Approach},
year ={2003},
volume ={24},
journal = {J. Comp. Chem.}}

@Article{lit4,
author = {Barua, B. and Lin, J.C. and Williams, V.D.},
title = {The Trp-cage: optimizing the stability of a globular miniprotein},
year ={2008},
volume = {21},
journal = {Protein Engineering, Design \& Selection}}

@Article{weinhold,
author = {F. Weinhold and C.R. Landis},
title = {Natural Bond Orbitals and Extensions of Localized Bonding Concept},
year ={2001},
journal = {Chemistry in Europe: Research and Practice in Europe},
volume = {2},
number = {2},
pages = {91-104}}

@Manual{weinhold1,
author = {F. Weinhold},
title ={NBO 5.0 Program Manual; Natural Bond Orbital Analysis Programs}}

@Book{test1,
type = book,
author = {some author},
year = {2012},
title ={Some arbitrary book title},
publisher = {Some publisher}
}

@Misc{strassner,
author = {Th. Stra{\ss}ner},
year = {2007},
howpublished = {http://www.chm.tu-dresden.de/oc3/documents/oc3/populationsanalyse.pdf}}

@Booklet{gaussian03,
author = {{\AE}. Frisch and M.J. Frisch and G.W. Trucks},
title = {\textit{Gaussian 03}, User`s Reference},
year = {2003}}

@Manual{gaussian,
author = {M.J. Frisch and G.W. Trucks and H.B. Schlegel and G.E. Scuseria and M.A. Robb and J.R. Cheeseman and J.A. Montgomery Jr. and T. Vreven and K.N. Kudin and J.C. Burant and J.M. Millam and S.S. Iyengar and J. Tomasi and V. Barone and B. Mennucci and M. Cossi and G. Scalmani and N. Rega and G.A. Petersson and H. Nakatsuji and M. Hada and M. Ehara and K. Toyota and R. Fukuda and J. Hasegawa and M. Ishida and T. Nakajima and Y. Honda and O. Kitao and H. Nakai and M. Klene and X. Li and J.E. Knox and H.P. Hratchian and J.B. Cross and C. Adamo and J. Jaramillo and R. Gomperts and R.E. Stratmann and O. Yazyev and A.J. Austin and R. Cammi and C. Pomelli and J.W. Ochterski and P.Y. Ayala and K. Morokuma and G.A. Voth and P. Salvador and J.J. Dannenberg and V.G. Zakrzewski and S. Dapprich and A.D. Daniels and M.C. Strain and O. Farkas and D.K. Malick and A.D. Rabuck and K. Raghavachari and J.B. Foresman and J.V. Ortiz and Q. Cui and A.G. Baboul and S. Clifford and J. Cioslowski and B.B. Stefanov and G. Liu and A. Liashenko and P. Piskorz and I. Komaromi and R.L. Martin and D.J. Fox and T. Keith and M.A. Al-Laham and C.Y. Peng and A. Nanayakkara and M. Challacombe and P.M.W. Gill and B. Johnson and W. Chen and M.W. Wong and C. Gonzalez and J.A. Pople},
title ={Gaussian 03, Revison C.02},
year = {Gaussian, Inc., Wallingford CT, USA, 2004}}

The TeX document (filename is biblatex-test-biber.tex) contains:

\documentclass[11pt]{scrartcl}
\usepackage[T1]{fontenc}
\usepackage[latin1]{inputenc}
\usepackage[german]{babel}

%\usepackage[style=authortitle-dw,backend=bibtex8]{biblatex}%authortitle-icomp
\usepackage[style=authortitle-icomp,backend=biber]{biblatex}%
\usepackage[babel,german=quotes]{csquotes}%guillemets

\addbibresource{literaturvz.bib}

\begin{document}

\cite{weinhold}

\clearpage

\parencite{weinhold}

\clearpage

\footcite[12]{weinhold}

\clearpage

\smartcite[12, smart]{weinhold}

\clearpage

\citeauthor{weinhold}

\clearpage

\citetitle{weinhold}

\clearpage

\citeyear{weinhold}

\nocite{*}

\printbibliography 

\printbibliography[title={Book references},type=book]

\end{document}

To create the final PDF run:

  1. pdflatex biblatex-test-biber
  2. biber biblatex-test-biber
  3. pdflatex biblatex-test-biber

Uwe

Uwe Ziegenhagen likes LaTeX and Python, sometimes even combined. Do you like my content and would like to thank me for it? Consider making a small donation to my local fablab, the Dingfabrik Köln. Details on how to donate can be found here Spenden für die Dingfabrik.

More Posts - Website

A simple homework template for LaTeX

Here’s a simple homework template I compiled today for my friend. I guess, it’s useful for rather short homeworks without any need to prepare a table of contents or long bibliography.

\documentclass[10pt,english]{article}
\usepackage[a4paper,left=2cm,top=2cm,right=2cm,bottom=2.5cm]{geometry}
\usepackage[utf8]{inputenc} % input coding stuff
\usepackage[T1]{fontenc} % font coding stuff
\usepackage{babel} % hyphenation
\usepackage{csquotes} % to \enquote{}
\usepackage{xcolor} % color stuff
 
\definecolor{chamois}{RGB}{255,255,240}
%\pagecolor{chamois} % for nice background color
 
\usepackage{palatino} % Font
\usepackage{blindtext} % some useless text
 
\usepackage{setspace} % 1,5-line spacing
 
\setlength{\parindent}{0pt} % just skips, no indent
\setlength{\parskip}{6pt}
 
\usepackage{titling} % defines \theauthor, \thetitle, etc.
 
\usepackage{scrpage2} % living column titles
\pagestyle{scrheadings}
 
\ohead{}
\ihead{}
 
\ofoot{\pagemark}
\ifoot{}
 
\cfoot{}
\chead{}
 
\author{Jane Doe, student ID 1234\,5678}
\title{Homework}
 
\begin{document}
{\theauthor} \\[-0.5em]
 
{\Large \bfseries \thetitle}
 
\today
 
\onehalfspacing
 
\subsubsection*{This is the first question.}
 
\blindtext[3]
 
\subsubsection*{This is the second question.}
 
\blindtext[4]
 
 
\subsubsection*{This is the third question.}
 
\blindtext[3]
 
\end{document}

03.02

Uwe

Uwe Ziegenhagen likes LaTeX and Python, sometimes even combined. Do you like my content and would like to thank me for it? Consider making a small donation to my local fablab, the Dingfabrik Köln. Details on how to donate can be found here Spenden für die Dingfabrik.

More Posts - Website

Calendars with Excel and pgfgantt, Part II

Since the last example of my pgfgantt-calendar generated a PDF with 1,60m width I decided to switch to a quarterly calendar. It took me quite a while to figure out the necessary Excel formulas (one may even find easier ways) but it works.

The green part contains some basic variables, e.g. when a quarter starts and ends. In the red part you just enter your dates. The violet part generates the entries for pgfgantt, the red box holds the copy&paste-ready entries for the TeX code. The code is able to handle events exceeding a single quarter.

23.01

Excel Code

final PDF

\documentclass{article}
\usepackage[landscape,a3paper,left=1cm,right=1cm,top=1cm,bottom=1cm]{geometry}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{pgfgantt}
\usetikzlibrary{calendar}
 
\protected\def\aaa#1{%
\pgfcalendarifdate{2012-12-31+#1}{weekend}% Test if it's a weekend
{\textcolor{red}{\pgfcalendarifdateday}}% Typeset with red color
{\pgfcalendarifdateday}% Or just the number
}
 
\protected\def\bbb#1{%
\pgfcalendarifdate{2013-03-31+#1}{weekend}% Test if it's a weekend
{\textcolor{red}{\pgfcalendarifdateday}}% Typeset with red color
{\pgfcalendarifdateday}% Or just the number
}
 
\protected\def\ccc#1{%
\pgfcalendarifdate{2013-06-30+#1}{weekend}% Test if it's a weekend
{\textcolor{red}{\pgfcalendarifdateday}}% Typeset with red color
{\pgfcalendarifdateday}% Or just the number
}
 
\protected\def\ddd#1{%
\pgfcalendarifdate{2013-09-30+#1}{weekend}% Test if it's a weekend
{\textcolor{red}{\pgfcalendarifdateday}}% Typeset with red color
{\pgfcalendarifdateday}% Or just the number
}
 
 
\begin{document}
\begin{flushright}
%\begin{tikzpicture}[scale=0.5, every node/.style={scale=0.25}]
\begin{ganttchart}[hgrid, vgrid, x unit=0.4cm]{90}
\gantttitle{1. Quartal}{90} \\
\gantttitlelist[
title list options={var=\y, evaluate=\y as \x using {"\aaa{\y}"}}
]{1,...,90}{1} \\
\ganttbar[bar/.style={fill=red}]{Neujahr}{1}{1}\\
\ganttbar[bar/.style={fill=yellow}]{Feiertag}{42}{42}\\
\ganttbar[bar/.style={fill=red}]{Feiertag}{88}{88}\\
\ganttbar[bar/.style={fill=green}]{Frühling}{79}{90}\\
\end{ganttchart}\vspace*{1cm}
 
\begin{ganttchart}[hgrid, vgrid, x unit=0.4cm]{91}
\gantttitle{2. Quartal}{91} \\
\gantttitlelist[
title list options={var=\y, evaluate=\y as \x using {"\bbb{\y}"}}
]{1,...,91}{1} \\
\ganttbar[bar/.style={fill=yellow}]{Feiertag}{1}{1}\\
\ganttbar[bar/.style={fill=red}]{Tag der Arbeit}{31}{31}\\
\ganttbar[bar/.style={fill=yellow}]{Herrentag}{39}{39}\\
\ganttbar[bar/.style={fill=green}]{Frühling}{1}{81}\\
\ganttbar[bar/.style={fill=yellow}]{Sommer}{82}{91}\\
\end{ganttchart}\vspace*{1cm}
 
\clearpage
 
\begin{ganttchart}[hgrid, vgrid, x unit=0.4cm]{92}
\gantttitle{3. Quartal}{92} \\
\gantttitlelist[
title list options={var=\y, evaluate=\y as \x using {"\aaa{\y}"}}
]{1,...,92}{1} \\
\ganttbar[bar/.style={fill=yellow}]{Sommer}{1}{83}\\
\ganttbar[bar/.style={fill=brown}]{Herbst}{84}{92}\\
\end{ganttchart}\vspace*{1cm}
 
\begin{ganttchart}[hgrid, vgrid, x unit=0.4cm]{92}
\gantttitle{4. Quartal}{92} \\
\gantttitlelist[
title list options={var=\y, evaluate=\y as \x using {"\aaa{\y}"}}
]{1,...,92}{1} \\
\ganttbar[bar/.style={fill=brown}]{Herbst}{1}{81}\\
\end{ganttchart}
 
\end{flushright}
\end{document}

Uwe

Uwe Ziegenhagen likes LaTeX and Python, sometimes even combined. Do you like my content and would like to thank me for it? Consider making a small donation to my local fablab, the Dingfabrik Köln. Details on how to donate can be found here Spenden für die Dingfabrik.

More Posts - Website