# \SetTracking in the math environment

I have been trying to use the \SetTracking option in microtype to shrink a paragraph that has some text and math. However, I notice that only the text - and not the math fonts - are being adjusted. The MWE below samples one such scenario:

    % START PREAMBLE
\documentclass[12pt]{report}
\usepackage[margin=1.25in]{geometry}

%Required math packages
\usepackage{amsmath}
\usepackage{bm}
\newcommand\vect[1]{\bm{#1}}%bm{#1}

%Document and typesetting
\usepackage{setspace}
\setlength{\parindent}{0in}

%Microtyping
\usepackage{microtype}

% END PREAMBLE

\begin{document}

This is without any tracking:

${{\vect{\varphi }}_{{qj}}} = ({\Psi _{qj1,{m_{qj1}} - 1,}} {\Psi _{qj2,{m_{qj2}} - 1,}},\dots, {\Psi _{qjS,{m_{qjS}} - 1}}), {{\vect{\varphi }}_{q}} = ({{\vect{\varphi }}_{{q1}}}, {{\vect{\varphi }}_{{q2}}},\dots, {{\vect{\varphi }}_{{qJ}}}),$
and
${\vect{\varphi}} = ({{\vect{\varphi}}_{1}}, {{\vect{\varphi}}_{2}},\dots, {{\vect{\varphi}}_{Q}})$
and
${{\vect{\vartheta}}_{qj}}{\rm{ }} = {\rm{ (}}{\Psi _{qj1,{m_{qj1}},{\rm{ }}}}{\rm{ }}{\Psi _{qj2,{m_{qj2}},{\rm{ }}}},\dots,{\rm{ }}{\Psi _{qjS,{m_{qjS}}}}){\rm{, }} {\vect{\vartheta }_{q}} = {\rm{(}}{\vect{\vartheta }_{{q1}}}, {\vect{\vartheta }_{{q2}}}{\rm{ , }}\dots{\rm{, }}{\vect{\vartheta }_{{qJ}}})$
and
$\vect{\vartheta } = {\rm{ (}}{\vect{\vartheta }_{1}}, {\vect{\vartheta }_{2}},\dots, {\vect{\vartheta }_{Q}}).$

\vspace{7mm}

This is with tracking:

\SetTracking[spacing={-50*,0*,50*}]{encoding={OT1,T1,TS1,OML,OMS,OMX,U}}{-30}
\textls{${{\vect{\varphi }}_{{qj}}} = ({\Psi _{qj1,{m_{qj1}} - 1,}} {\Psi _{qj2,{m_{qj2}} - 1,}},\dots, {\Psi _{qjS,{m_{qjS}} - 1}}), {{\vect{\varphi }}_{q}} = ({{\vect{\varphi }}_{{q1}}}, {{\vect{\varphi }}_{{q2}}},\dots, {{\vect{\varphi }}_{{qJ}}}),$
and
${\vect{\varphi}} = ({{\vect{\varphi}}_{1}}, {{\vect{\varphi}}_{2}},\dots, {{\vect{\varphi}}_{Q}})$
and
${{\vect{\vartheta}}_{qj}}{\rm{ }} = {\rm{ (}}{\Psi _{qj1,{m_{qj1}},{\rm{ }}}}{\rm{ }}{\Psi _{qj2,{m_{qj2}},{\rm{ }}}},\dots,{\rm{ }}{\Psi _{qjS,{m_{qjS}}}}){\rm{, }} {\vect{\vartheta }_{q}} = {\rm{(}}{\vect{\vartheta }_{{q1}}}, {\vect{\vartheta }_{{q2}}}{\rm{ , }}\dots{\rm{, }}{\vect{\vartheta }_{{qJ}}})$
and
$\vect{\vartheta } = {\rm{ (}}{\vect{\vartheta }_{1}}, {\vect{\vartheta }_{2}},\dots, {\vect{\vartheta }_{Q}}).$
}

\end{document}


We can clearly discern that only the and within the paragraph is being changed - the math fonts remains the same. How can I get around this issue?

-
I don't think it's possible to apply tracking to math formulas. –  egreg Nov 14 '12 at 10:49

This is a similar bug in microtype as the one you stumbled upon in pdfTeX font expansion error - \SetExpansion in microtype package. Fix it by adding the following lines to the preamble:

\makeatletter
\DeclareRobustCommand\lsstyle{%
\not@math@alphabet\lsstyle\textls