6

enter image description here

Hi do you know how I can produce this symbol in latex? Only the bar through the letter i need I know the rest. And i need something that works on math mode for sure. I tried using \sout with ulem package combined with \ddots but didn't work.

\documentclass[12pt]{article} 
\usepackage[margin=1in]{geometry} 
\usepackage{amsmath,amsthm,amssymb,empheq,caption}
\usepackage{graphicx}
\usepackage{siunitx}
\usepackage{mathtools}
\usepackage{float}
\usepackage{ulem}

\begin{document}

   \begin{equation}
     \frac{dJ}{dt}=-\frac{2}{5}\frac{G}{c^5}\epsilon_{ijk}
       \Big\langle{\sout{\ddot{I}_{jm}}\sout{\dddot{I}_{km}}}\Big\rangle
   \end{equation}

\end{document}

Output of the code

enter image description here

  • Welcome to TeX.SX!! It is better to post a full minimal working example that starts with a \documentclass command, has a minimal preamble and then \begin{document}...\end{document}. Unless the problem is a compilation error, the code should compile and be as small as possible to demonstrate your problem. This makes it much easier for people to help you --- and much more likely that they will! – Andrew Mar 4 '16 at 20:46
  • You can highlight code in your post using back-ticks. For code-blocks indent them by four spaces or use the {} on the gui. – Andrew Mar 4 '16 at 20:46
  • tex.stackexchange.com/questions/20609/strikeout-in-math-mode this shows a similar question. Does the \hcancel offer a solution for you? – Douwe66 Mar 4 '16 at 20:49
  • I think it's better now :). I don't know if I am using \sout correct. only the bar in the middle I want – Tcm Mar 4 '16 at 21:10
  • Gravitational radiation equations? – user31729 Mar 4 '16 at 21:15
7

Here's a possible solution working in all sizes.

\documentclass{article}
\usepackage{amsmath}
\usepackage{etoolbox}

% fix amsmath's \dddot
\patchcmd{\dddot}{#1}{\kern0pt #1}{}{}

\makeatletter
\DeclareRobustCommand{\barredI}{%
  \mathord{\vphantom{I}\mathpalette\@barredI\relax}%
}

\newcommand{\@barredI}[2]{%
  \ooalign{%
    \hidewidth\@barredIbar#1\hidewidth\cr
    $\m@th#1I$\cr
  }%
}

\newcommand{\@barredIbar}[1]{%
  \check@mathfonts
  \ifx#1\displaystyle
    \fontsize{\f@size}{\z@}%
    \def\@barredIbarkern{0.3}%
  \else
    \ifx#1\textstyle
      \fontsize{\f@size}{\z@}
      \def\@barredIbarkern{0.3}%
    \else
      \ifx#1\scriptstyle
        \fontsize{\sf@size}{\z@}
        \def\@barredIbarkern{0.4}%
      \else
        \fontsize{\ssf@size}{\z@}
        \def\@barredIbarkern{0.47}%
      \fi
    \fi
  \fi
  \usefont{OT1}{cmr}{m}{n}%
  \kern-\@barredIbarkern em 
  \raisebox{-.5ex}{\symbol{'26}}%
}
\makeatother

\begin{document}

$\barredI_{\barredI_{\barredI}}$ $I\barredI$

\bigskip

$\dddot{I}_{\!jk}\dddot{\barredI}_{\!jk}$

\end{document}

enter image description here

3

You can adapt this answer to a similar question:

\documentclass{article}
\usepackage{amsmath}
\usepackage{calc}
\newsavebox\CBox
\newcommand\hcancel[2][0.5pt]{%
  \ifmmode\sbox\CBox{$#2$}\else\sbox\CBox{#2}\fi%
  \makebox[0pt][l]{\usebox\CBox}%  
  \rule[0.5\ht\CBox-#1/2]{\wd\CBox}{#1}}
\begin{document}

$\dddot{\hcancel{I}}_{jk} \dddot{\hcancel{I}}_{jk}$

\end{document}

enter image description here

  • Ok It worked and the result is really fine. Thank you very much all of you – Tcm Mar 4 '16 at 21:30
  • Very concise and easy to understand answer. Thumbs up! – Shinobii Jun 14 at 19:54
1

I found this question which seems to me similar. With it I suggest:

\documentclass[12pt]{article} 
\usepackage{amsmath} % here for \dot, \ddot, ... and \text command
\usepackage{soul} % here for \st command

\begin{document}

\begin{equation}
    \ddot{\mbox{\st{$I$}}}_{jm} % instead of \mbox you can use \text
\end{equation}

\end{document}

Be aware that you need to put a \mbox{} or \text{} (from the amsmath package) around the letter with the horizontal bar through. Inside the box I used $I$ again in order to keep the math font.

enter image description here

Compared to the other answers my solution has some disadvantages:

  • The dots are not correctly horizontally centered above of the character.
  • The bar/line in not correctly vertically centered (too low).

But there is an advantage too:

  • You don't need a lot of code and custom commands.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.