3

How to create slashed greek letter $\iota$? Which is often used as $\iota / 2\pi$? I want it used in text and math (equations) environment. I found close solution with using package cancel. However, the angle of the slash has very steep slope and a little bit long.

\documentclass{article}
\usepackage{amssymb,amsmath}
\begin{document}
\usepackage{cancel}
$\cancel\iota$ 
\end{document}

output

2

4 Answers 4

4

The following uses a slash similar to the one in \hslash; quite lowered so the symbol is not mistaken for a “t”.

\documentclass{article}
\usepackage{amsmath}

\usepackage{graphicx}% for \iotaslashB

\usepackage{amssymb} % for comparison with \hslash

\makeatletter
\newcommand{\iotaslash}{{\mathpalette\iotaslash@\relax}}

\newcommand{\iotaslash@}[2]{
  \raisebox{-0.6\height}[0pt][0pt]{%
    \rotatebox[origin=Bl]{15}{$\m@th#1{\mkern-1mu\mathchar'26}$}%
  }%
  \mkern-9.5mu\nonscript\mkern-1mu
  \iota
  \mkern1mu
}
\makeatother

\begin{document}

% the \vrule shows the left margin
\vrule width 0.1pt$\iotaslash$ $\hslash$ $\frac{\iotaslash}{4}$

\vrule width 0.1pt$\hslash$

% compare the bounding boxes
\fboxsep=0pt \fboxrule=0.1pt
\fbox{$\iotaslash$}

\fbox{$\iota$}

\end{document}

It works in scriptstyle (probably not so well in scriptscriptstyle).

enter image description here

2

One idea would be to rotate the slash appropriately: rotate 170; perhaps has an optimal slope. If you prefer a smaller slope decrease the numerical parameter.

\documentclass[a4paper,12pt]{article}
\usepackage{graphicx}
\newcommand{\rslash}{\mathbin{\rotatebox[origin=c]{170}{$/$}}}
\begin{document}
${\iota\mkern-7.5mu\rslash}$
\end{document} 

enter image description here

2

If you want try this code inspired from this answer. It uses tikz instead of cancel.

\documentclass{article}
\usepackage{tikz}
\usetikzlibrary{calc}
\newif\ifCancelX
\tikzset{X/.code={\CancelXtrue}}
\newcommand{\Cancel}[2][]{\relax
    \ifmmode%
    \tikz[baseline=(X.base),inner sep=0pt] {\node (X) {$#2$};
        \tikzset{#1}
        \draw[#1,overlay,shorten >=-1pt,shorten <=-1pt] ($ (X.south west)-(1pt,-1pt) $) --($ (X.north east)+(0pt,-1pt) $);
        \ifCancelX  
        \draw[#1,overlay,shorten >=-1pt,shorten <=-1pt] ($ (X.north west)-(0pt,0pt) $) --($ (X.south east)+(0pt,0pt) $);
        \fi}
    \else
    \tikz[baseline=(X.base),inner sep=0pt] {\node (X) {#2};
        \tikzset{#1}
        \draw[#1,overlay,shorten >=-1pt,shorten <=-1pt] ($ (X.south west)-(1pt,-1pt) $) --($ (X.north east)+(0pt,-1pt) $);
        \ifCancelX
        \draw[#1,overlay,shorten >=-1pt,shorten <=-1pt] ($ (X.north west)-(1pt,-1pt) $) --($ (X.south east)+(0pt,-1pt) $);
        \fi}%
    \fi}

\begin{document}
    $$x =\Cancel{\iota} - \Cancel[red]{I} - \Cancel[blue]{\iota}/ 2\pi$$
    
\end{document}

enter image description here

If you work more on this code, you can customize as you like the diagonal line of canceling and also the X of cancelling. I have changed the cancelling line but pay no attention to retain the X cancel in a symmetrical form, so if you need it you have to change it more.

1

The slope of the slash in the cancel package depends on the width of the letter you want to cancel.

If you'd like it to be less step, you could make your l to appear a bit wider by include some space around it:

\documentclass{article}
\usepackage{amssymb,amsmath}
\usepackage{cancel}
\begin{document}
$\cancel{\,\iota\,}$ 
\end{document}

enter image description here

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .