Is there a Computer Science library for TikZ?

I am looking for a library for drawing standard data structures (array, linked list, stack, queue, pointers, trees, etc) in a consistent way.

I would also be happy to hear how hard would it be to create such a library for an intermediate LaTeX user (understands some macros, can't write macros independently) in terms of work-days.

  • I think that such a library does not exist but I'm not sure. Do you have a link to show us what you desire. Something like that : introcs.cs.princeton.edu/java/43stack ? Feb 22, 2012 at 8:53
  • Yes, something like that. I have created some illustrations in TikZ without the use of such a package, and I would like to either write my own package or use an existing one to achieve better consistency and make life easier. The document in question is at ilijapavlic.com/spa/Skripta.pdf
    – ipavlic
    Feb 22, 2012 at 9:01
  • CTAN lists several packages that may be useful for computer scientists here, but unfortunately none provides constructions for standard data structure types.
    – Daniel C.
    Mar 26, 2012 at 16:54
  • @ipavlic: See also the question [Inconsistent TikZ multipart node anchors][1]. [1]: tex.stackexchange.com/questions/44257/… Jul 25, 2012 at 17:50

1 Answer 1


At the moment, there is no a dedicated Computer Science tikz library. But it is not hard to realize why there is no need for one, as you can achieve almost anything you want with four basic tikz libraries:

  • \usetikzlibrary{arrows}

  • \usetikzlibrary{shapes}

  • \usetikzlibrary{trees}

  • \usetikzlibrary{mindmap}

In this website you can find a comprehensive list of examples for many Computer Science applications, including the ones you mention. The page includes the .tex file for each example. If you see the code of these examples, there is no use of any specialized package (with this exception) but only a clever combination of the above.

You must log in to answer this question.

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