# toric quiver representation

toric quivers are represented as a type of HashTable with the following keys:

• IncidenceMatrix: weighted incidence matrix giving the vertex-edge connectivity structure of $Q$
• Q0: list of vertices
• Q1: list of edges
• flow: list of integers giving the flow on each edge
• weights: induced weights on vertices given by the image of the flow

One can generate the quiver Q associated to the bipartite graph K_{2,3} with a random flow w as follows:

 i1 : Q0 = {{0,2},{0,3},{0,4},{1,2},{1,3},{1,4}} o1 = {{0, 2}, {0, 3}, {0, 4}, {1, 2}, {1, 3}, {1, 4}} o1 : List i2 : Q = toricQuiver(Q0, Flow=>"Random") o2 = ToricQuiver{flow => {24, 65, 71, 72, 19, 19} } IncidenceMatrix => | -1 -1 -1 0 0 0 | | 0 0 0 -1 -1 -1 | | 1 0 0 1 0 0 | | 0 1 0 0 1 0 | | 0 0 1 0 0 1 | Q0 => {0, 1, 2, 3, 4} Q1 => {{0, 2}, {0, 3}, {0, 4}, {1, 2}, {1, 3}, {1, 4}} weights => {-160, -110, 96, 84, 90} o2 : ToricQuiver

Alternatively, one can construct a toric quiver using any of the following constructions:

create a toric quiver from matrix

 i3 : Q = toricQuiver matrix({{-1,-1,-1,-1},{1,1,0,0},{0,0,1,1}}) o3 = ToricQuiver{flow => {1, 1, 1, 1} } IncidenceMatrix => | -1 -1 -1 -1 | | 1 1 0 0 | | 0 0 1 1 | Q0 => {0, 1, 2} Q1 => {{0, 1}, {0, 1}, {0, 2}, {0, 2}} weights => {-4, 2, 2} o3 : ToricQuiver

create a toric quiver from matrix with specified flow

 i4 : Q = toricQuiver(matrix({{-1,-1,-1,-1},{1,1,0,0},{0,0,1,1}}), {3, 1, 0, 5}) o4 = ToricQuiver{flow => {3, 1, 0, 5} } IncidenceMatrix => | -1 -1 -1 -1 | | 1 1 0 0 | | 0 0 1 1 | Q0 => {0, 1, 2} Q1 => {{0, 1}, {0, 1}, {0, 2}, {0, 2}} weights => {-9, 4, 5} o4 : ToricQuiver

create a toric quiver from a list of edges

 i5 : Q = toricQuiver {{0,1},{0,1},{0,2},{0,2}} o5 = ToricQuiver{flow => {1, 1, 1, 1} } IncidenceMatrix => | -1 -1 -1 -1 | | 1 1 0 0 | | 0 0 1 1 | Q0 => {0, 1, 2} Q1 => {{0, 1}, {0, 1}, {0, 2}, {0, 2}} weights => {-4, 2, 2} o5 : ToricQuiver

create a toric quiver from a list of edges and a flow

 i6 : Q = toricQuiver ({{0,1},{0,1},{0,2},{0,2}}, {1,2,3,4}) o6 = ToricQuiver{flow => {1, 2, 3, 4} } IncidenceMatrix => | -1 -1 -1 -1 | | 1 1 0 0 | | 0 0 1 1 | Q0 => {0, 1, 2} Q1 => {{0, 1}, {0, 1}, {0, 2}, {0, 2}} weights => {-10, 3, 7} o6 : ToricQuiver

create a toric quiver from a matrix with keyword flow

 i7 : Q = toricQuiver(matrix({{-1,-1,-1,-1},{1,1,0,0},{0,0,1,1}}), Flow=>"Canonical") o7 = ToricQuiver{flow => {1, 1, 1, 1} } IncidenceMatrix => | -1 -1 -1 -1 | | 1 1 0 0 | | 0 0 1 1 | Q0 => {0, 1, 2} Q1 => {{0, 1}, {0, 1}, {0, 2}, {0, 2}} weights => {-4, 2, 2} o7 : ToricQuiver

create a toric quiver from a matrix with random flow

 i8 : Q = toricQuiver(matrix({{-1,-1,-1,-1},{0,0,1,1},{1,1,0,0}}), Flow=>"Random") o8 = ToricQuiver{flow => {91, 72, 93, 79} } IncidenceMatrix => | -1 -1 -1 -1 | | 0 0 1 1 | | 1 1 0 0 | Q0 => {0, 1, 2} Q1 => {{0, 2}, {0, 2}, {0, 1}, {0, 1}} weights => {-335, 172, 163} o8 : ToricQuiver

create a toric quiver copied from another one

 i9 : R = toricQuiver(Q) o9 = ToricQuiver{flow => {91, 72, 93, 79} } IncidenceMatrix => | -1 -1 -1 -1 | | 0 0 1 1 | | 1 1 0 0 | Q0 => {0, 1, 2} Q1 => {{0, 2}, {0, 2}, {0, 1}, {0, 1}} weights => {-335, 172, 163} o9 : ToricQuiver

create a toric quiver copied from another, but with alternative flow

 i10 : R = toricQuiver(Q, {1,2,3,4}) o10 = ToricQuiver{flow => {1, 2, 3, 4} } IncidenceMatrix => | -1 -1 -1 -1 | | 0 0 1 1 | | 1 1 0 0 | Q0 => {0, 1, 2} Q1 => {{0, 2}, {0, 2}, {0, 1}, {0, 1}} weights => {-10, 7, 3} o10 : ToricQuiver