We decided to use the javascript markdown engine [showdown](https://github.com/showdownjs/showdown) for the blawg, and [$\KaTeX$](https://khan.github.io/KaTeX/) for rendering latex. If you think that's a good way to go: Here is how to do it with wordpress.


Ich habe ((This post is in German and I am not sure if this is even internationally relevant.)) nach etwa einer Stunde die Suche nach einer LaTeX Vorlage für Übungsscheine erfolglos abgebrochen und eine eigene entworfen. Um dem einen oder anderen wissenschaftlichen Mitarbeiter das Leben zu erleichtern ist hier das Ergebnis meiner Mühen. Das ist jetzt natürlich auf die TU Berlin zugeschnitten und verwendet deswegen auch das offizielle TU Berlin Logo, aber es sollte keine große Schwierigkeit darstellen, es an die eigenen Bedürfnisse anzupassen. Die Verwendung sollte recht selbsterklärend sein. Es druckt pro DIN-A4 Seite zwei Übungsscheine. Wenn die Seite exakt in der Mitte geteilt wird, sollten die Seitenränder passen und in etwa 7mm betragen. In meinen Tests ist das Ergebnis jedenfalls passabel und muss abgesehen vom Trennschnit auf A5 nicht weiter zugeschnitten werden.


Ich habe endlich herausgefunden, wie man auch die letzten merkwürdigen Autovervollständigungen von TexStudio eliminert. Das Problem ensteht vor allem mit deutschen Tastaturen, da man häufig Ctrl+Alt noch gedrückt hat, wenn man die Leertaste betätigt, etwa nachdem man eine schließende, geschweifte Klammer (Ctrl+Alt+0 liefert }) eingegeben hat. Dies hat in der TexStudio Standardkonfiguration zur Folge, dass ein \begin{ im Text eingefügt wird. Wie schaltet man das aus? So: * TexStudio konfigurieren * Tastenkürzel * Menüs * Idefix * Vervollständige * Den \begin{ Vervollständigungs-Hotkey löschen Es könnte noch andere Ctrl+Alt-Makros dieser Art geben, die man löschen sollte. Ich werde diesen Post updaten, wenn mir weitere unterkommen.


I was cleaning up my LaTeX header and re-coded some macros to suit my needs better. I have always had a macro called \of which takes one parameter. It used to be the very simple macro
\newcommand{\of}[1]{\left(#1\right)}
However, I sometimes want to specify the size of the brackets explicitly, so I wanted to add an optional argument to this macro such that \of[big]{\sum} will expand to \bigl(\sum\bigr). Sometimes I even want it not to do any resizing of the brackets at all. The correct way to do this is is \csname and \endcsname which allows you to delay expansion of a macro. Inside a macro definition, the command
\newcommand{\ar}[1]{\csname#1arrow\endcsname}
will be such that \ar{right} is first made into \rightarrow and then expanded. We will use that to make \bigl and \bigr out of the argument big, for instance. Do you want to know more?


I have found and quickly begun to love a wonderful piece of software called TeXStudio. It's an open source LaTeX editor with preview pane and the preview is for the actual PDF document, not yet another buggy DVI viewer that fails to display your TiKzPictures correctly. It's available on all platforms. You have to seriously work through the (advanced) options and set it up to your liking ((This will most likely include shutting off all of the autocomplete features because they might otherwise drive you insane.)) , but I must say that this is probably the best LaTeX editor I have ever seen. Most prominently, it allowed me to switch all my projects to UTF-8 for the first time, because you can set file encoding in a comfortable way. It also does a good job at detecting UTF-8 and if everything fails, you can use the special comment !TeX encoding = UTF-8. Citing french papers has become slightly less of a torment.


Mein Eindruck ist, dass viele vernünftige Leute das Problem haben, unter Windows texen zu wollen und bei schrecklichen Programmen wie LaTeX Editor oder TeXnicCenter hängen bleiben. Prinzipiell funktionieren die ja auch. Vielleicht nicht perfekt und manchmal sind sie hier oder da etwas unpraktisch, oder stürzen ab (beim Editiern von Text) - aber sie tun ihre Arbeit und, hey, es gibt ja auch nichts besseres. Do you want to know more?


Trust me, I am not one to enjoy deeply nested case distinctions in a mathematical proof. In fact, I'd rather there were no case distinctions necessary at all. However, to quote the famous mathematician Nikolai Nowaczyk: > Some theorems have beautiful proof - and some theorems are worth fighting for. Anyway. If you have to do it, you should do it in beautiful $\KaTeX$. Do you want to know more?


After discovering the toggle command available in MathJax, I immediately went to asked the capable people of tex.stackexchange whether this could be done inside a PDF file. And indeed: It can be done!
\documentclass{article}
\usepackage{animate}

\begin{document}
\begin{animateinline}[step]{1}
  \strut$x=1$
\newframe
  \strut$x=2$
\newframe
  \strut$x=3$
\end{animateinline}
\end{document}
Now, what do I want with this package? I want to do abstract nonsense. A diagram-based proof should, in my opinion, be a slideshow. You start with the diagram that is your assumption and by simply interacting with the diagram (clicking it), in each step, a new arrow is constructed from some universal property. I wanted to write a neat animated PDF with an abstract nonsense proof of the famous Snake Lemma, and there is a great book by Francis Borceux containing a proof, but unfortunately, I was unable to overcome a difficulty with the proof, so that will have to wait until someone answers my question.


I was asked today if one could make LaTeX skip all occurances of the value 13, in all counters, as some buildings do. Well, of course you can:
\let\stepc\stepcounter\renewcommand{\stepcounter}[1]{%
\ifthenelse{\equal{\value{#1}}{12}}{\stepc{#1}}{}\stepc{#1}}
Here, we first save the \stepcounter macro in \stepc, then we renew its definition by stepping the counter twice if its current value equals 12, therefore effectively omitting the 13th occurance. Also, you should watch the thirteenth floor, it's a nice movie if you're into scifi.


I have wondered how to undefine existing commands in $\LaTeX$ for so long. Finally, I googled it up. It's easy. Simply
\makeatletter
\let\command\@undefined
\makeatother
and the \command has been undefined. This does not cause an error when \command was undefined before. After that, you can merrily
\newcommand{\command}{Hell Yeah.}
and be on your way.


I just wanted to include an SVG file into a LaTeX Beamer presentation and I found the following articles very useful: * LaTeX and Inkscape * includesvg Apparently, Inkscape has a built in feature that allows you to write LaTeX-Code in Inkscape, export the generated SVG image as PDF and then even reimport this into LaTeX documents. Awesome!


Als großer Befürworter von Palatino-Schriftarten ((insbesondere auch mathpazo für mathematische Texte)) möchte ich natürlich auch meine Briefe so verfassen. Wem das nicht passt, der kann ... trotzdem weiterlesen! Wesentlich wichtiger war mir für diesen Brief nämlich, dass die Adresse des Empfängers bei korrekter Faltung in einem Fensterumschlags sichtbar ist. Das sieht dann etwa so aus. Wollen Sie den Code sehen?


I handed in my diplom thesis today. I'm fairly proud of it, and I am also quite fond of the layout. So, if anyone finds it quite appealing, I am gladly willing to share the LaTeX. Note that although it has (to have) a German introduction, it is written in English.