next | previous | forward | backward | up | top | index | toc | Macaulay2 website
VectorGraphics :: showGraph

showGraph -- Improved drawing of graphs

Description

Returns a GraphicsObject that describes the input graph. Requires the package Graphs. Automatically used by the html output.

i1 : needsPackage "Graphs";
i2 : R=QQ[x,y]; b=flatten entries basis(0,3,R)

             2   3   2           2      2   3
o3 = {1, x, x , x , x y, x*y, x*y , y, y , y }

o3 : List
i4 : digraph select(b**b,a->a#1 % a#0 == 0 and first degree a#1 == first degree a#0 +1)

o4 = Digraph{1 => {x, y}       }
                    2
             x => {x , x*y}
                      2      2
             x*y => {x y, x*y }
                         2
             y => {x*y, y }
                2
             x*y  => {}
              2      3   2
             x  => {x , x y}
              2
             x y => {}
              2        2   3
             y  => {x*y , y }
              3
             x  => {}
              3
             y  => {}

o4 : Digraph

For the programmer

The object showGraph is a function closure.