[Tex/LaTex] Dot with only operator overline

math-modesymbols

I have read this question Special character "dot over dash" for solved my problem. But my question is little different and it is not duplicate.

How to have using command \overline a \dot (or more greater than \dot in the middle and is it almost near the vector mark \overline?
I bring back what I would like with a picture:

enter image description here

I made a very impromptu attempt.

enter image description here

\documentclass[a4paper,12pt]{article}
\usepackage{mathtools}
\begin{document}
\[\dot{\hspace{-.072cm}\overline J}=\frac{\partial \overline J}{\partial \tau}\]
\end{document}

Best Answer

Honestly I'm not sure it's worth the effort (I use \overline as rarely as possible). My phantasy wasn't rich enough to come up with a name...

\documentclass{article}

\def\foo{\mathpalette\fooaux}
\def\fooaux#1#2{%
  \mkern2mu
  \setbox0=\hbox{\mathsurround=0pt$#1\overline{\mkern-2mu #2 \mkern2mu}$}%
  \setbox1=\hbox to \wd0{\hss$#1\cdot$\hss}%
  \vbox{\offinterlineskip\copy1\vskip-.4\ht1\box0}%
  \mkern-2mu
}

\begin{document}

$\dot{\overline{J}} J \overline{J} J \foo{J}J$

$\scriptstyle \dot{\overline{J}} J \overline{J} J\ foo{J}J$

$\scriptscriptstyle \dot{\overline{J}} J \overline{J} J \foo{J}J$

\end{document}

enter image description here