Swirly Mein Kopf

Saturday, May 25. 2013

My first CTAN package: Typesetting Continued Equalities

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“.

Trackbacks


No Trackbacks

Comments

Display comments as (Linear | Threaded)

*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) on 2013-05-25 21:34 (Reply)
*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) on 2013-05-27 08:42 (Reply)

Add Comment



To prevent automated Bots from commentspamming, please enter the string you see in the image below in the appropriate input box. Your comment will only be submitted if the strings match. Please ensure that your browser supports and accepts cookies, or your comment cannot be verified correctly.
CAPTCHA

Gravatar, Favatar, Identica author images supported.
What is the first name of the owner of this blog? / Wie heißt der Betreiber diess Blogs mit Vornamen?
 
 
Nach oben