7

Consider four kinds of "arrow" symbols: 0. A horizontal line 1. A leftarrow 2. A rightarrow 3. A doublearrow

I'd like to add circles to each end of these arrows, allowing for all possible combinations of "filled" and "unfilled," for a total of sixteen combinations in total. As an example, one may consider the "spoons" offered by the MnSymbol package for reference, as in \leftspoon and \leftfilledspoon.

Any ideas as to how to achieve this?

EDIT: So to clarify, I want circles on BOTH ends of the arrows. As in O-->O.

1
  • Where is the arrow? Above the filled circle (more or less invisible), outwards or in the inside, ...? Dec 4, 2012 at 17:26

3 Answers 3

5

You can use \hbox to create your own arrows by appending other symbols, like this:

\def\CircleftarrowCirc{\hbox{$\circ$}\kern-1.5pt\hbox{$\leftarrow$}\kern 1.5pt\hbox{$\circ$}}

enter image description here

2
  • Thanks. There needs to be a negative on the second kern, but in broad terms this is the answer I was looking for. So the fixed code reads: \def\CircleftarrowCirc{\hbox{$\circ$}\kern-1.5pt\hbox{$\leftarrow$}\kern-1.5pt\hbox{$\circ$}} Dec 4, 2012 at 17:55
  • @user18921: Good that you spotted the missing negative. I had it in the original code to create the image. It somehow got lost in the copy&paste.
    – Mafra
    Dec 4, 2012 at 18:07
9

I think the intended arrowtips are the following:

Arrows

which were produced with the following code:

\documentclass{standalone}
\usepackage{tikz}
\begin{document}

\def\generateFourVariants#1{% Parameter, arrow style
\xdef\y{0}
\foreach \left in {white, black} {
  \foreach \right in {white,black} {
    \draw[fill=\left]  (0,\y) circle (2pt);    
    \draw[fill=\right] (1,\y) circle (2pt);
    \draw[shorten <=2pt, shorten >=2pt, arrows=#1] (0,\y) -- (1, \y);
    \pgfmathparse{\y+1}
    \global\let\y\pgfmathresult
  }
 }
}

\begin{tikzpicture}[>=latex]
  \begin{scope}[xshift=0 cm]
  \generateFourVariants{}
  \end{scope}
  \begin{scope}[xshift=2 cm]
  \generateFourVariants{->}
  \end{scope}
  \begin{scope}[xshift=4 cm]
  \generateFourVariants{<-}
  \end{scope}
  \begin{scope}[xshift=6 cm]
  \generateFourVariants{<->}
  \end{scope}

\end{tikzpicture}
\end{document}

But I'm not sure if this answers the OP question...

1
  • Those are indeed the symbols! Dec 4, 2012 at 17:50
6

Package txfonts contains all these symbols, however I am counting nine variants:

\documentclass{article}
\usepackage{txfonts}

\begin{document}
\begin{enumerate}
\item $-$
\item $\multimapinv$, $\multimapdotinv$
\item $\multimap$, $\multimapdot$
\item $\multimapboth$,
      $\multimapdotbothA$, $\multimapdotbothB$
      $\multimapdotboth$
\end{enumerate}
\end{document}

Result

3
  • If you look at 4, that's kind of what I'm looking for. Except I'd like the horizontal line connecting the circles to possibly end in an arrowhead. Dec 4, 2012 at 17:19
  • @user18921 It's not clear to me. Perhaps you can made some ASCII art or a hand drawing? Dec 4, 2012 at 17:24
  • Sure! O---O, O-->O, O<--O, O<->O. That's four of them. Filling in the O's in all combinations gives the remaining twelve. Dec 4, 2012 at 17:35

You must log in to answer this question.

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