TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

http://tex.stackexchange.com/a/88762/17049 provides a beautiful solution for getting spirals like this:

enter image description here

I've been trying to use this with some mixed text/math content (for a book cover), but I find that even with a tiny excerpt, pdflatex just keeps running and running without terminating. [Using a full core for at least 10 minutes.] The only change I made was to replace

Lorem ipsum ...

in the code in the linked answer with If $K \leq G$ and there are inclusions $gKg^-1\leq K$ for every $g\in G$, ... .

Is there any way of getting spirals with mixed text/maths content, either by modifying the linked answer or otherwise?






    text path start scale/.code={%
    text path end scale/.code={%
    reverse path,
    text along path,
    text path start scale=1.5,
    text path end scale=0,
    text={If $K \leq G$ and there are inclusions $gKg^-1\leq K$  for every $g\in G$, ... .}}
\draw [decorate] 
    \foreach \i [evaluate={\r=(\i/2000)^2;}] in {0,5,...,2880}{ -- (\i:\r)}; 
\useasboundingbox (-2.75,-2.75) rectangle (2.75,2.75); 
share|improve this question
up vote 5 down vote accepted

Your code works if you do as Herbert did in his pstricks example -- Enclose the math in curly braces:

If {$K \leq G$} and there are inclusions {$gKg^-1\leq K$}  for every {$g\in G$}, ...

The problem is that long bits of math are treated as a unit, so you will have to break them up:

{$g$}{$K$}{$g^{-1}$} {$\leq$} {$K$}

I fixed a problem I'd not noticed with the {-1}, which also has to be in its own curly braces.

share|improve this answer
Welcome to TeX.sx! – hpesoj626 Jan 16 '13 at 13:19

It needs latex->dvips->ps2pdf. xelatex doesn't work in this case. It should be easy to adopt it to a TikZ solution, if really needed.


\newdimen\MyDim \MyDim=30pt
  \global\advance\MyDim by -0.175pt}


    {50}{0}[/A 5e-3 def ]{A*(cos(t)+t^2*sin(t)) | A*(sin(t)-t^2*cos(t))}}{\perChar{%


enter image description here

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.