I am fairly new to LaTeX, and have run into a problem with commands apparently only available in text mode, where I would like to use them in math mode as well (e.g. integrated in equations).
One of the commands/symbols in question is the upside down exclamation sign used to represent the subfactorial function.
In running text, I can use the command
\textexclamdown, but this does not work in math mode (as far as I can tell).
Is there a way to seamlessly integrate text mode commands in the middle of rather hairy equations?