I would like to write an equation within a theorem that involves an integrand and the upright symbol $ \textrm{d} $
which I have abbreviated in my preamble with
\newcommand{\dmath}{\textrm{d}}
(and the preamble also contains)
\usepackage{array}
\usepackage{amsthm}
\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage{amssymb}
... etc
\newtheorem{theorem}{Theorem}[section]
I have the following theorem:
\begin{theorem}[Fubini's theorem]
\label{app:thrm:fubini}
Suppose $ X $ and $ Y $ are measurable spaces. If $ f(x,y) $ is integrable ($ f(x,y) $ is measurable and $ \int_{X,Y} \left| f(x,y)\right| \dmath (x,y) < \infty$) then
\begin{equation*}
\int_{X} \left(\int_{Y} f(x,y) \dmath y \right) \dmath x
=
\int_{Y} \left(\int_{X} f(x,y) \dmath x \right) \dmath y
=
\int_{X,Y} f(x,y) \dmath (x,y).
\end{equation*}
\end{theorem}
and have the following output
but would like the \dmath
to produce $\textrm{d}$ to produce an upright 'd' character whenever it is called, and would like the following output:
Any suggestions on a simple way to achieve the desired result?
I have looked at the following Qs but they don't quite address the issue:
- Non italic text in theorems, definitions, examples
Equivalent of \mathup for upright text in math mode? (*see link below)
https://tex.stackexchange.com/questions/139699/equivalent-of-mathup-for-upright-text-in-math-mode
\newcommand{\dmath}{\mathop{}\!\mathrm{d}}