Ask Your Question

Revision history [back]

sage: level = 6
sage: elements = [b for n in range(level) for b in Partitions(n)]
sage: ord = lambda x,y: y.contains(x)
sage: Y = Poset((elements,ord), facade=True)
sage: H = Y.hasse_diagram()

In my optional package, I wrote a module to deal with tikzpictures:

sage: from slabbe import TikzPicture
sage: TikzPicture.from_poset(Y).pdf()
'/home/labbe/.sage/temp/priminfo/2669/tikz_DTZlSu.pdf'
sage: TikzPicture.from_graph(H).pdf()
'/home/labbe/.sage/temp/priminfo/2669/tikz_79FaK9.pdf'

I intend to polish it a little bit more during the next year, maybe make it more general, before proposing its inclusion into Sage.

sage: level = 6 sage: elements = [b for n in range(level) for b in Partitions(n)] sage: ord = lambda x,y: y.contains(x) sage: Y = Poset((elements,ord), facade=True) sage: H = Y.hasse_diagram()

Y.hasse_diagram()

In my optional package see also #20343, I wrote a module to deal with tikzpictures:

sage: from slabbe import TikzPicture
sage: TikzPicture.from_poset(Y).pdf()
'/home/labbe/.sage/temp/priminfo/2669/tikz_DTZlSu.pdf'
sage: TikzPicture.from_graph(H).pdf()
'/home/labbe/.sage/temp/priminfo/2669/tikz_79FaK9.pdf'

I intend to polish it a little bit more during the next year, maybe make it more general, before proposing its inclusion into Sage.

sage: level = 6 sage: elements = [b for n in range(level) for b in Partitions(n)] sage: ord = lambda x,y: y.contains(x) sage: Y = Poset((elements,ord), facade=True) sage: H = Y.hasse_diagram()

In my optional package see also #20343, I wrote a module to deal with tikzpictures:

sage: from slabbe import TikzPicture
sage: TikzPicture.from_poset(Y).pdf()
'/home/labbe/.sage/temp/priminfo/2669/tikz_DTZlSu.pdf'
sage: TikzPicture.from_graph(H).pdf()
'/home/labbe/.sage/temp/priminfo/2669/tikz_79FaK9.pdf'

I intend to polish it a little bit more during the next year, maybe make it more general, before proposing its inclusion into Sage.

sage: level = 6 sage: elements = [b for n in range(level) for b in Partitions(n)] sage: ord = lambda x,y: y.contains(x) sage: Y = Poset((elements,ord), facade=True) sage: H = Y.hasse_diagram()

In my optional package see also #20343, I wrote a module to deal with tikzpictures:

sage: from slabbe import TikzPicture
sage: TikzPicture.from_poset(Y).pdf()
'/home/labbe/.sage/temp/priminfo/2669/tikz_DTZlSu.pdf'
sage: TikzPicture.from_graph(H).pdf()
'/home/labbe/.sage/temp/priminfo/2669/tikz_79FaK9.pdf'

I intend to polish it a little bit more during the next year, maybe make it more general, before proposing its inclusion into Sage.

sage: level = 6 sage: elements = [b for n in range(level) for b in Partitions(n)] sage: ord = lambda x,y: y.contains(x) sage: Y = Poset((elements,ord), facade=True) sage: H = Y.hasse_diagram()

In my optional package see also #20343, I wrote a module to deal with tikzpictures:

sage: from slabbe import TikzPicture
sage: TikzPicture.from_poset(Y).pdf()
'/home/labbe/.sage/temp/priminfo/2669/tikz_DTZlSu.pdf'
sage: TikzPicture.from_graph(H).pdf()
'/home/labbe/.sage/temp/priminfo/2669/tikz_79FaK9.pdf'

I intend to polish it a little bit more during the next year, maybe make it more general, before proposing its inclusion into Sage.

In my optional package see also #20343, I wrote a module to deal with tikzpictures:

sage: from slabbe import TikzPicture
sage: path_to_file = TikzPicture.from_poset(Y).pdf()
'/home/labbe/.sage/temp/priminfo/2669/tikz_DTZlSu.pdf'
sage: path_to_file = TikzPicture.from_graph(H).pdf()
'/home/labbe/.sage/temp/priminfo/2669/tikz_79FaK9.pdf'

which open automatically the pdf in a viewer like view does. I intend to polish it a little bit more during the next year, maybe make it more general, before proposing its inclusion into Sage.

In my optional package see also #20343, I wrote a module to deal with tikzpictures:

sage: from slabbe import TikzPicture
sage: path_to_file = TikzPicture.from_poset(Y).pdf()
TikzPicture.from_poset(Y).pdf()     # requires dot2tex + graphviz
sage: path_to_file = TikzPicture.from_graph(H).pdf()
TikzPicture.from_graph(H).pdf()     # requires dot2tex + graphviz

which open automatically the pdf in a viewer like view does. I intend to polish it a little bit more during the next year, maybe make it more general, before proposing its inclusion into Sage.

In my optional package see also #20343, I wrote a module to deal with tikzpictures:

sage: from slabbe import TikzPicture
sage: path_to_file = TikzPicture.from_poset(Y).pdf()     # requires dot2tex + graphviz
sage: path_to_file = TikzPicture.from_graph(H).pdf()     # requires dot2tex + graphviz

which open automatically the pdf in a viewer like view does. You may also create a TikzPicture object from any tikzpicture string without using dot2tex. For example:

sage: g = graphs.PetersenGraph()
sage: s = latex(g)
sage: t = TikzPicture(s, usepackage=['tkz-graph'])
sage: t.pdf()

I intend to polish it a little bit more during the next year, maybe make it more general, before proposing its inclusion into Sage.