[Tex/LaTex] How to change global font size and global math size separately

fontsfontsizemath-mode

How can I change the font size of regular text and the font size of equations separately, but globally? I have a lot of equations in my document, and I want to reduce the font size of all regular text, while maintaining or even enlarging the font size of all equations. Changing all equations one by one (using grouping or something like that) is infeasible, and \DeclareMathSizes does not work for me.

If anyone has a global solution, that would be much apprectiated! As of now, I set the font size of all text (regular and math mode) by using \footnotesize at the beginning of the whole document, but this makes my equations too small to be legible.

\documentclass{article}
\usepackage[utf8]{inputenc}
\DeclareMathSizes{14pt}{12pt}{12pt}{12pt} 
\begin{document} 
\Huge Testing the math font size: $99.9\%$ 
\end{document}

Best Answer

enter image description here

\documentclass{article}
\usepackage[utf8]{inputenc}
\DeclareMathSizes{24.88pt}{12pt}{12pt}{12pt} 
\begin{document} 
\Huge Testing the math font size: $99.9\%$ 
\end{document}

You had specified the math font sizes to use if the text font size was 14pt but your example text was Huge, and size10.clo specifies

\newcommand\Huge{\@setfontsize\Huge\@xxvpt{30}}

so \Huge is \@xxvpt so more or less 25pt, but \DeclareMathSizes needs the exact size so you could use \@xxvpt or 24.88pt as I use above, the latex format defines these shortcuts for font sizes:

 \def\@vpt{5}
 \def\@vipt{6}
 \def\@viipt{7}
 \def\@viiipt{8}
 \def\@ixpt{9}
 \def\@xpt{10}
 \def\@xipt{10.95}
 \def\@xiipt{12}
 \def\@xivpt{14.4}
 \def\@xviipt{17.28}
 \def\@xxpt{20.74}
 \def\@xxvpt{24.88}
Related Question