It is not clear what your question is so I offer two alternatives
\documentclass{article}
\usepackage{amsmath}
\begin{document}
Either
\[
7\frac{1}{6}=\frac{42+1}{6}=\frac{43}{6}
\]
or
\begin{center}
$ 7\frac{1}{6}=\frac{42+1}{6}=\frac{43}{6}$
\end{center}
\end{document}
I can't see any cases where you would want to set this as multiple math fragments in separate $...$ also avoid using \dfrac in most uses of inline math.
Given the lack of answers other than the comments, here is a summary of the critiques which have come from the comments. By increasing the visibility of these comments, I'm hoping that I may get a solution to the portability problem noted so far, and provoke further critiquing of my macro generally.
Technical/æsthetic obstacle:
Brent.Longborough, with further elaboration by TH., noted that this macro is not necessarily very robust to a change in font, which may have different dimensions for e.g. its ex-size relative to the size of the actual letters. It would seem that a different choice of parameters in the \raisebox-es, and possibly the \scalefont-s as well, may be necessary for each different font used.
Technical improvement:
TH. suggested (if I understand correctly) that I should modify the macro using \m@th (or equivalent): a little research indicates that this is probably to improve the horizontal spacing of the result. Thus, a minor improvement would be
Best Answer
It is not clear what your question is so I offer two alternatives
I can't see any cases where you would want to set this as multiple math fragments in separate
$...$
also avoid using\dfrac
in most uses of inline math.