2

I was just wondering if there was a quick fix for this problem. Essentially I have a subsection of my thesis written up with the variable $\xi$ appearing everywhere. To be consistent with the rest of the thesis I should really change this, $\eta$ would be a better option. Is there a way for me to 'tell' LaTeX that within subsection X.X.X read $\xi$ as $\eta$? It would save me a lot of time and hassle not having to change every occurrence of $\xi$!

Thanks.

  • sed 's%\\xi%\\eta%g'.. – nbubis Mar 5 '15 at 10:17
  • @nbubis - Wouldn't that change all \xi to \eta - not just in the subsection of interest? – Dason Mar 5 '15 at 16:23
9

You could put

\let\oldxi\xi\let\xi\eta

at the start of the section and

\let\xi\oldxi

at the end.

Although I wouldn't do that, I'd edit the source. Any editor would change all \xi to \eta in a section in less time than it took you to post the question....

  • The subsection is perhaps 30 pages long and includes extensive asymptotic expansions. It was MUCH quicker to post the question. Thanks for the response. – Juggler Mar 5 '15 at 10:11
  • 4
    @Juggler the math might be complicated but sed -i -e 's/\\xi\b/\\eta/g' section5.tex would fix it wouldn't it? I say I'd do that as the above \let... isn't entirely safe if for example you have $\xi$ in a subsubsection heading, it will typeset as eta in the heading but be written as \xi and typeset as xi to the table of contents, similar considerations if you have math in \index. Fixing such moving text is possible but quite a bit harder and more fragile, compared to simply editing the file. – David Carlisle Mar 5 '15 at 11:51

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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