# Special sign \pounds changed to dollar sign in alignment surrounding

I am writing a beamer and use

\begin{align*}
\pounds^i_M   etc.
\end{align*}


on a slide. The pounds sign then changes to a dollar sign. How do I write to get the pounds sign?

\documentclass{beamer}
\usepackage{amssymb}
\usepackage{apalike}
\usepackage{multicol}
\usepackage[all]{xy}
\usepackage[ngerman]{babel}
%\usepackage[applemac]{inputenc}
\usepackage{graphicx}
\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage{amssymb}
\usepackage{endnotes}
\def\L{\mathcal{L}}
\setlength{\unitlength} {1mm}

\begin{document}

\frame { \maketitle}

\frame{ \frametitle{Prescriptions of \pounds \ I: Classical logical maxims} \begin{align*}
\pounds^i_M & \qquad A\rightarrow (B\rightarrow A)
\end{align*}
}
\end{document}

-
Could you add a minimal working example? From \documentclass… to \end{document}. By the way, what's the meaning of that? I would never think (in my head) about “pounds_M^i”. –  Manuel Feb 9 at 14:53
\documentclass{beamer} \usepackage{amssymb} \usepackage{apalike} \usepackage{multicol} \usepackage[all]{xy} \usepackage[ngerman]{babel} %\usepackage[applemac]{inputenc} \usepackage{graphicx} \usepackage{amsmath} \usepackage{amsfonts} \usepackage{amssymb} \usepackage{endnotes} \def\L{\mathcal{L}} \setlength{\unitlength} {1mm} \usetheme{Madrid} \begin{document} \frame { \maketitle} \frame{ \frametitle{Prescriptions of \pounds \ I: Classical logical maxims} \begin{align*} \pounds^i_M & \qquad A\rightarrow (B\rightarrow A) \end{align*} } \end{document} –  Frode Bjørdal Feb 9 at 15:13
As for the meaning of the notation, that is somewhat complicated. The beamer is for a lecture I will hold in mathematical logic, more specifically on an alternative set theory. –  Frode Bjørdal Feb 9 at 15:20
Then I would use \let\whatever\pounds where \whatever is a more appropriate name for the symbol. And then use \whatever_i^M. In that case reading/writing your code would be better (I think). –  Manuel Feb 9 at 15:29
It is a very bad idea to redefine \L. Don't use \def if you're not sure; use a name such as \cL or similar. –  egreg Feb 9 at 17:13

I have also this problem when using the fonts Beamer loads by default (Computer Modern sans serif). If I use their Latin Modern equivalent, it works fine:

\documentclass{beamer}
\usepackage[T1]{fontenc}
\usepackage{lmodern}
\begin{document}
\begin{frame}
\begin{align*} \pounds^i_M  \end{align*}
\end{frame}
\end{document}


-
The problem is that we don't know what font does he use and which encoding (for instance). –  Manuel Feb 9 at 14:58
You're right, but anyway it doesn't seem to be related to the encoding, rather to the font itself. The cm-super fonts, (loaded with the single line \usepackage[T1]{fontenc}) present the same behavior as their Computer Modern OT1-encoded counterparts: they both produce the \$ symbol. Whereas the Latin Modern fonts, also with T1-encoding, produce the right pound symbol… –  fpast Feb 9 at 15:16
Thanks fpast, your suggestion worked. –  Frode Bjørdal Feb 9 at 15:17
Exercise 9.7 of the TeXbook confirms that it is not a bug but a feature of Computer Modern font: the italicized version of the dollar symbol is indeed the sterling symbol. And so, I guess that the reverse is also true for these fonts. Funny idea. –  fpast Feb 9 at 16:15
@fpast -- when tex was created, space was scarce, and there wasn't room for both the dollar and the pound sign in all alphabetic fonts, so to make both available, the pound sign was put into the italic in the same location as the dollar sign in the upright font. –  barbara beeton Feb 9 at 16:44

Using a different font and text mode:

\documentclass{beamer}
\usepackage{amsmath}
\renewcommand*{\mathsterling}{%
\text{%
\fontencoding{T1}%
\fontfamily{lmss}%
\fontshape{it}%
\selectfont
\pounds
}%
}
\begin{document}
\begin{frame}
\begin{align*}
\end{align*}
\end{frame}
\end{document}


-

Unfortunately, the font used for \mathit doesn't have a pound symbol in it. As Barbara Beeton explains in her comment, the OT1 encoded font use only 128 slots, so there's no space for a pound sign, which, in math mode is emulated using math italic.

The simplest solution is to switch to T1 encoding, but also setting \mathsterling to use the right slot (this is done automatically by lmodern):

\documentclass{beamer}
\usepackage[T1]{fontenc}

\renewcommand{\mathsterling}{\mathit{\mathchar "70BF}}% correct slot

\begin{document}

\begin{frame}
\maketitle
\end{frame}

\begin{frame}

\frametitle{Prescriptions of \pounds \ I: Classical logical maxims}

$\pounds^i_M & \qquad A\rightarrow (B\rightarrow A)$

\end{frame}

\end{document}


Avoid the syntax \frame{...} which is cumbersome and risky, because the closing brace is difficult to spot. It's preferable using

\begin{frame}
...
\end{frame}


that also allows using

\begin{frame}[<options>]


that's not allowed by the other syntax.

It's also not a good idea to redefine \L. Never use \def if you're not sure about the command to redefine. Prefer a command name such as \cL, for instance, that's as easy to input and, perhaps, also more semantically sound.

-