How to get a good "divisible by" symbol?

I've never seen that symbol. But here's how you can define it

\DeclareRobustCommand{\divby}{%
  \mathrel{\vbox{\baselineskip.65ex\lineskiplimit0pt\hbox{.}\hbox{.}\hbox{.}}}%
}

It's just an almost straightforward modification of \vdots.

enter image description here

In order that the symbol changes size when used in subscripts/superscripts, just enclosing the main part in \text will do.

\documentclass{article}
\usepackage{amsmath}

\DeclareRobustCommand{\divby}{%
  \mathrel{\text{\vbox{\baselineskip.65ex\lineskiplimit0pt\hbox{.}\hbox{.}\hbox{.}}}}%
}

\begin{document}

\[
a\divby b \qquad \sum_{k\divby n}a_k
\]

\end{document}

enter image description here


Here's another way to define a \divby symbol (it additionally requires graphicx though):

\newcommand*{\divby}{\mathrel{\rotatebox{90}{$\hskip-1pt.{}.{}.$}}}%

enter image description here


I have another solution. :) You could also use TikZ. (This may be quite straightforward if you load the package in your preamble anyway.)

\documentclass{article}

\usepackage{tikz}

\newcommand{\divby}{\ \tikz \foreach \y in {0ex, 0.65ex, 1.3ex} \fill (0,\y) circle (0.5pt);\ }

\begin{document}
$15\divby 3$
\end{document}

enter image description here