Math & ScienceMath in TOC

Information and discussion about LaTeX's math and science related features (e.g. formulas, graphs).
Post Reply
UJS
Posts: 6
Joined: Wed Nov 19, 2008 12:54 am

Math in TOC

Post by UJS »

Hi everyone,

I'm using the memoir class with the hyperref package (among others) and compiling with PDFLaTeX. I'm getting the following warnings when I have math (in this case the Greek epsilon symbol) in a section title that needs to go in the Table of Contents:

Code: Select all

Package hyperref Warning: Token not allowed in a PDF string (Unicode):
(hyperref)                removing `math shift' on input line 13.
Package hyperref Warning: Token not allowed in a PDF string (Unicode):
(hyperref)                removing `\epsilon' on input line 13.
It does seem to display in the ToC correctly, and the hyperlink works as well.. does anyone know what this is about?

Thanks in advance,

UJS

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

Learn LaTeX easily with newest books:

The LaTeX Beginner's Guide: 2nd edition and perfect for students writing a thesis

The LaTeX Cookbook: 2nd edition full of practical examples for mathematics, physics, chemistry, and more

LaTeX Graphics with TikZ: the first book about TikZ for perfect drawings in your LaTeX thesis

UJS
Posts: 6
Joined: Wed Nov 19, 2008 12:54 am

Math in TOC

Post by UJS »

Here's a working example:

Code: Select all

\documentclass{memoir}
\usepackage[unicode]{hyperref}


\begin{document}

\frontmatter
\tableofcontents
\mainmatter	
\chapter{Introduction $\epsilon$}
text

\end{document}
Omitting the unicode option changes the warning, but doesn't get rid of it (this was a default setting, not sure if I need it).
User avatar
localghost
Site Moderator
Posts: 9202
Joined: Fri Feb 02, 2007 12:06 pm

Math in TOC

Post by localghost »

Search the hyperref manual for the \texorpdfstring command to replace math expressions in headings.


Best regards and welcome to the board
Thorsten¹
UJS
Posts: 6
Joined: Wed Nov 19, 2008 12:54 am

Re: Math in TOC

Post by UJS »

Excellent, it works now! I did look at the manual before, but I just didn't know what to search for..

Thank you!
Post Reply