# textnormal in math mode not working

I am trying to use normal text in math mode but it is not working. Below is the error I get. I have included asmath

$\textnormal{F_{prior}(LSTM)}$

Missing $inserted. <inserted text>$
l.297 $\textnormal{F_{prior}(LSTM)}$


Instead of $\textnormal{F_{prior}(LSTM)}$ you should use $\mathrm{F_{prior}(LSTM)}$, because subscripts need math mode.

With amsmath

$\text{F}_\text{prior}(\text{LSTM})$


if you want the text font.

• Please don't encourage users to do this, it is wrong on all levels, even the _\text is bad for users. Dec 26 '17 at 7:54
• Because users may think this is a general feature, that they do not need braces, so it confuses them that sometimes they need braces other times they don't. Especially when it is coming from a high level user (many points), new users will take their examples as law. Dec 26 '17 at 10:24
• Also, noone have ever guaranteed that that fact that you can use _\text does not mean that it will keep working for ever. So using braces is safer in general. Dec 26 '17 at 10:28
• The use of text is wrong, it should never be used this way. This wrong use of text is on my top 3 of errors made by most users. Users should use one single construction, not one where they need to change things if the context it is used in turns out to be italic, for example. If you wrap your example in \enmph{...}  all the text will be italic. Clearly not your intent. Users should use mathrm for stuff that are math (here at least the F) and for example textnormal for things that are clearly textual (not math), here prior is a candidate. Dec 26 '17 at 11:46
• That is an example of the effect. Think used inside a theorem environment. Text is for textual comments in math, none of these are comments and thus specific markup should be used. Even if the op is asking for text font, using textnormal on each component instead of text is more stable in all situations. Dec 26 '17 at 12:10