Joachim Breitner

My first CTAN package: Typesetting Continued Equalities

Published 2013-05-25 in sections English, Digital World.

I recently had a TeX itch to scratch: I am working on a paper that has several multi-line continued equalities¹ where, depending on the size of the expressions and the explanations of each step, I chose among a few layouts. But implementing the layout together with the actual code was inefficient, as switching the layout involved changing every line.

So I came up with the package conteq which allows you to typeset continued equations in a simple declarative manner, e.g.

\begin{conteq}
  e^{\pi\cdot i} \\
= -1               & Euler's formula \\
< 0                & this is an inequality \\ 
< \sqrt 3 \\
= \int e^{-x^2} dx & this is due to Gauss.
\end{conteq}

and allows you to select the layout via an parameter to the environment, or globally, or either. Also, the styling of the explanations (italics? wrapped in {...}?) can be configured simply by redefining a macro. For more details and an overview of the various styles, check out the package documentation.

If this sounds useful to you, fetch the conteq package from CTAN. But beware: It uses quite current features of the expl3 package, so you need at least the version from 2012/07/02 (TeXLive 2013 is good). You can file bug reports at the GitHub mirror of my git repository.

I’d like to thank Bruno Le Floch and Joseph Wright, who made me aware of expl3 on various TeX Exchange questions.

¹ I haven’t heard of this term before, but supposedly it is the right translation for the German word „Gleichungskette“.

Comments

Very cool, thanks! I often want something like this and have been using a hacked-together abomination. This looks like it should work for me very nicely.
#1 Brent Yorgey (Homepage) am 2013-05-25
Funny, Research In Progress pushed this right behind in my feed reader: http://researchinprogress.tumblr.com/post/51393471487/from-complex-looking-math-it-straightforwardly
#2 qznc (Homepage) am 2013-05-27

Have something to say? You can post a comment by sending an e-Mail to me at <mail@joachim-breitner.de>, and I will include it here.