In my MWE below, I wanted the create a shortcut for some operators. How can I get the \DeclareMathOperator command to show up like the conventional way of using the actual command $\mathbf{z}(k)$ ?
Also, is there an even shorter way to get this command, like say for example just type \z instead of $\z$ ?
Here is my code:
\documentclass[11pt]{book}
\usepackage{amsmath,amsfonts,amssymb,amsthm, bm}
\DeclareMathOperator{\z}{{\mathbf{z}}(k)}
\begin{document}
How do I get this Math operator $\z$ to show like this $\mathbf{z}(k)$?
\end{document}
\newcommand{\z}{{\mathbf{z}}(k)}but$\mathbf{z}(k)$has strange spacing, perhaps better would be\DeclareMathOperator\z{z}then$\z(k)$so\zgets the same space rules as\log– David Carlisle Oct 13 '15 at 20:38\DeclareMathOperatorin this case. – egreg Oct 13 '15 at 22:44