I'm not sure where to put this question, but is it possible to create a graphical element with six dots in pyramid shape with Latex?

I cannot find this symbol from Unicode character blocks, so I guess next try is to make it with Latex or similar method. And if this is not working then just accepting png image...

Below symbol T3=6 is the one I'm trying to make.

Pyramidical shape of dots


You can do it with tikz. See the comments in the \pyrdot command definition.

enter image description here


    % you can tune the size of the pyramid using the scale option
        \pgfmathsetmacro{\n}{#1}                            % define \n, the number of rows 
        \edef\m{0}                                          % define \m, the total number of circles
        \foreach \i in {1, ..., \n} {                       % vertical loop
            \foreach \k in {1, ..., \i} {                   % horizontal loop
                \fill ($(\k,-\i)+(-.5*\i,0)$) circle (4mm); % draw the circle (size = 4mm, shifted to the left)
                \pgfmathparse{int(\m+1)}                    % increment \m
        % put the text below the pyramid
        \node[anchor=north] at (current bounding box.south) {$T_{\n}=\m$};


\section{pyramidical dots}



  • It would be helpful to explain and give a reference to tikz, plus give a small explanation of the pgfmathsetmacro, what it is doing. I tried this at overleaf.com and it was working perfectly.
    – MarkokraM
    Feb 17 '16 at 16:31
  • @MarkokraM Please see the edits.
    – sergej
    Feb 18 '16 at 10:06

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.