# [texhax] changing the font of % in math mode in LaTeX

Thu Jul 7 16:58:20 CEST 2011

On Thu, Jul 07, 2011 at 10:12:13PM +1000, Vafa Khalighi wrote:

> Sorry that should be \mathbin and not \mathord.
>
> On Thu, Jul 7, 2011 at 10:11 PM, Vafa Khalighi <vafa018 at gmail.com> wrote:
>
> > Is \DeclareMathSymbol{\%}{\mathord}{operators}{%} the right way to do it?

The first argument is not a number, but a command sequence or active char.
In the last argument you get a problem with the precent as comment char.

\documentclass{article}
\DeclareMathSymbol{\modulo}{\mathbin}{operators}{\%}
\begin{document}
$$a \equiv b \modulo m$$
\end{document}

Yours sincerely
Heiko Oberdiek
`