[Tex/LaTex] How to get upright greek letters with the mathastext package

greekmathastext

I am using mathastext and bm packages.

I want a bold upright phi. \bm{\phi} gives me italicized one and if I change it to a capital \Phi, it works.

...
\usepackage[upgreek]{mathastext}
...

What additional options do I need? Please give an example.
Hint: The solution exist on pg. 19-20 of mathastext documentation. I couldn't understand it.

Best Answer

As pointed out by @DavidPurton in a comment, the documentation of mathastext indicates (but in a not so clear way) that upgreek option has effect only if one of the Greek related options described in ยง1.9 Greek letters is active.

For example:

\documentclass{article}
\usepackage[upgreek, LGRgreek]{mathastext}
\usepackage{bm}

\begin{document}
\[\phi, \Phi\]
\[\bm{\phi}, \bm{\Phi}\]
\end{document}

Output: enter image description here

However, perhaps your font set-up has some specifics.

Other approaches

E.g. you could use \usepackage[upright]{fourier}...load text packages...\usepackage{mathastext} to benefit from the Fourier set-up for Greek letters. Then \bm{\phi} gives a bold upright Greek letter. mathastext does not interfere at all in this.

\documentclass{article}
\usepackage[upright]{fourier}
% add here text packages according to what is needed
\usepackage{mathastext}% does not modify anything to Greek in math
\usepackage{bm}

\begin{document}
\[\phi, \Phi\]
\[\bm{\phi}, \bm{\Phi}\]
\end{document}

Produces: enter image description here

Or use eulergreek option:

\documentclass{article}
\usepackage[eulergreek]{mathastext}
\usepackage{bm}

\begin{document}
\[\phi, \Phi\]
\[\bm{\phi}, \bm{\Phi}\]
\end{document}

Produces: enter image description here