Quiver Yangian from Crystal Melting

We find a new infinite class of infinite-dimensional algebras acting on BPS states for non-compact toric Calabi-Yau threefolds. In Type IIA superstring compactification on a toric Calabi-Yau threefold, the D-branes wrapping holomorphic cycles represent the BPS states, and the fixed points of the moduli spaces of BPS states are described by statistical configurations of crystal melting. Our algebras are"bootstrapped"from the molten crystal configurations, hence they act on the BPS states. We discuss the truncation of the algebra and its relation with D4-branes. We illustrate our results in many examples, with and without compact $4$-cycles.


Introduction
The counting of Bogomol'nyi-Prasad-Sommerfield (BPS) states [1,2] has been one of the most central questions in quantum field theories, black holes and string theory. Toric Calabi-Yau manifolds provide an ideal setup for addressing this problem -the geometry of a toric Calabi-Yau manifold in itself is described by the combinatorial data of the toric diagram, and the BPS state counting problem can be recast as the statistical counting problem of crystal melting [3,4].
Despite the success of the BPS state counting program for toric Calabi-Yau manifolds, there remained one unsatisfactory aspect of the program. While the BPS counting problem generates an infinite set of numbers (BPS degeneracies), there are clearly some structures in them, and it has long been expected that there is an underlying algebra, the algebra of BPS states acting on BPS states [19]. One hopes such an algebra will provide a better organizing principle for the BPS state counting problem. There was, however, little discussion of this algebra, at least for general toric Calabi-Yau manifolds.
There have been recently impressive developments in this direction. For the case of the C 3 -geometry, it was found that we can define an action of Y ( gl 1 ) (the affine Yangian of gl 1 , which is equivalent with the universal enveloping algebra of W 1+∞ -algebra [20][21][22][23][24][25]) on the set of plane partitions [23,24,26] (see also [27]), and hence on the BPS states contributing to the BPS degeneracy. The BPS partition function (which is the MacMahon function) is identified with the character of the affine Yangian of gl 1 . In other words, the problem of explicitly constructing the algebra for the C 3 has now been solved.
The natural question is then if similar algebras exist for other toric Calabi-Yau geometries. Namely, can we explicitly construct an infinite-dimensional algebra such that it acts on the BPS crystal configurations of [5]?
The goal of this paper is to provide an answer to this question. We explicitly define an infinite-dimensional algebra Y for an arbitrary toric Calabi-Yau manifold, and show that we can define a representation of the algebra in terms of the statistical model of BPS crystal melting. Our algebra and representation reduce to Y ( gl 1 ) and its plane-partition representation for the special case of C 3 .
Our algebra Y is defined from a pair (Q, W ) of a quiver diagram Q and a superpotential W , which are determined by the toric Calabi-Yau geometry. For this reason one can denote our algebra as Y (Q,W ) , and call it the BPS quiver Yangian, or simply the quiver Yangian.
In our discussion it is crucial to keep track of the orientations of the quiver, and also to have closed loops in the quiver diagram Q; the quiver is in general chiral. The existence of loops in the quiver is the necessary ingredient for the existence of a non-zero superpotential W , which in itself is an independent data. In this respect our discussion seems to be more general than similar discussions of infinite-dimensional algebra in the literature, e.g. the work of [21] where the quiver associated with the Yangian acts on the cohomologies of quiver varieties. It would be interesting to fully understand the relation with [21] and other works, e.g. [28], as we will discuss further in section 10. Let us also mention that during the preparation of this manuscript we have been notified of the ongoing work [29], who studies cohomological Hall algebras for some toric Calabi-Yau manifolds.
The rest of this paper is organized as follows. We begin with a review of the BPS crystal melting (section 2) and affine Yangian of gl 1 (section 3). We introduce the BPS quiver Yangian in section 4. In order to motivate this definition, in section 5 we first go back to the plane partitions discussed in section 3 and bootstrap the affine Yangian of gl 1 . Then in section 6 we repeat a similar analysis for a general quiver corresponding to a toric Calabi-Yau manifold, to obtain our BPS quiver Yangian. We discuss the truncation of the algebra and the relation with D4-branes in section 7. We present many examples both for toric Calabi-Yau manifolds without compact 4cycles (section 8) and with compact 4-cycles (section 9). These examples will provide useful illustrations of many of the general results of the previous sections. The final section 10 is devoted to a summary and discussions.

Quiver Diagram and Superpotential
Let us first quickly summarize the BPS crystal melting for a toric Calabi-Yau manifold. For a more complete discussion, see [5,18].
Let us consider type IIA string theory compactified on a non-compact toric Calabi-Yau three-fold X. Combinatorially, the choice of X is encoded in the socalled toric diagram ∆, a lattice convex polytope in Z 2 , see Figure 1 for an example. The BPS states of the theory are described by D-branes (D0/D2/D4-branes) wrapping holomorphic cycles (0/2/4-cycles) inside the Calabi-Yau manifold X. The effective theory on the D-branes is a supersymmetric quiver quantum mechanics, and the moduli space of BPS states can be identified with the vacuum moduli space of the quiver quantum mechanics.
The quiver quantum mechanics generically has four supercharges, and can be thought of as the dimensional reduction of a four-dimensional N = 1 supersymmetric quiver gauge theory. The theory is specified by a pair (Q, W ), where Q is a quiver diagram and W is a holomorphic superpotential.
A quiver diagram Q = {Q 0 , Q 1 } is given by a set of vertices Q 0 and a set of arrows Q 1 between vertices. In the following we use the notation namely we use a, b, . . . to denote the vertices, and I, J, . . . to denote the edges. We denote the number of vertices and arrows by |Q 0 | and |Q 1 |, respectively. The source and the target of the arrow I ∈ Q 1 will be denoted by s(I) ∈ Q 0 and t(I) ∈ Q 0 , respectively. In quiver quantum mechanics Q 0 and Q 1 specify the gauge groups and the bifundamental matter fields: we have a vector multiplet V a for a vertex a ∈ Q 0 and a bifundamental matter chiral multiplet Φ I for an arrow I ∈ Q 1 .
The superpotential W specifies the interactions between the matter. Given W , we can write down the so-called F-term relations ∂W/∂Φ I = 0 for each bifundamental matter Φ I corresponding to the arrow I. In the mathematics literature W is known as a potential [30] and defines the so-called "path algebra for quiver with relations" A (Q,W ) . This is defined to be the Jacobian algebra CQ/(∂W ), where CQ is the path algebra generated by the set of (in general open) paths on the quiver diagram, with multiplication defined by concatenations of the paths. The infinite-dimensional algebra A (Q,W ) underlies the definition of the crystal melting model, and is closely related to our infinite-dimensional algebra Y (Q,W ) .
In general it is a highly non-trivial problem to identify the pair (Q, W ) for a Calabi-Yau manifold X. Fortunately, for a non-compact toric Calabi-Yau three-fold there is a systematic algorithm to obtain such a pair, starting with the toric diagram ∆ [31][32][33][34]. We will not need details of this procedure in this paper, except to note that the algorithm generates the pair (Q, W ) in the form of the periodic quiver, a quiver diagram realized on the torus (see Figure 2 for an example).
Given a periodic quiver, we can first forget the fact that the quiver is realized on a two-dimensional torus, to obtain a quiver diagram Q as an abstract graph. The periodic quiver, however, contains more information -for each polygonal region of the torus the arrows of the quiver diagram point in the same direction (either clockwise or counterclockwise), and the product of the bifundamental fields along the polygonal region represents a gauge-invariant superpotential term. The superpotential W is recovered as a sum of such monomial contributions W = f :face of the periodic quiver ±Tr e∈f Φ e , (2.2) where the product over e ∈ f is taken along the orientations of the arrows and the sign ± is determined by the orientations (counter-clockwise or clockwise) of the arrows. For the example of Figure 2, the periodic quiver gives the superpotential where we have denoted the bifundamental chiral multiplet associated to an arrow from vertex a to b by Φ ab (in this example there are at most one arrow for any vertices a, b).
In the periodic quiver description, monomial terms of the superpotential W are associated with the faces of the periodic quiver, which we denote by Q 2 . In this notation, the quiver Q = (Q 0 , Q 1 ) and the superpotential W combines nicely into the dataQ = (Q 0 , Q 1 , Q 2 ) of the periodic quiver.
The dual of the periodic quiver is often represented as a bipartite graph, i.e. a graph where vertices are colored with two colors (black and white) and vertices always connect vertices of different colors. The orientation of the quiver diagram canonically determines the colors of the vertices of the bipartite graph, so that quiver arrows are oriented clockwise (counterclockwise) around black (white) vertices of the bipartite graph, see Figure 3 for an example. Such a bipartite graph in high energy theory is  Figure 1. The green region is the fundamental region of the two-dimensional torus. The periodic quiver compactly encodes the quiver diagram Q as an abstract graph, as well as the superpotential W .
often called a brane tiling [35][36][37] (see e.g. [38,39] for reviews), and has been heavily utilized in the study of supersymmetric quiver gauge theories. We will later show in section 7 that the concept of the the perfect matching of the bipartite graph will help us relate the truncation of the algebra to the charges of the D4-branes.  Figure 1 (shown on the left), which is a dual graph to the periodic quiver of Figure 2 (as shown on the right). The color of a vertex of the bipartite graph is determined from the orientations of the quiver arrows surrounding it (black for counterclockwise, and white for clockwise).
The periodic-quiver representation of the superpotential makes it easy to read off the F-term relations (see Figure 4): two paths on the periodic quiver starting with a vertex and ending at another are F-term equivalent. This will be useful when we discuss global symmetries of the quiver quantum mechanics.

Crystal as a Lift of Periodic Quiver
Let us next construct the BPS crystal. For this purpose, consider a new quiver diagram Q obtained by uplifting the periodic quiver diagram to the universal cover of the two-dimensional torus (namely the two-dimensional plane). Each vertex a on the resulting quiver is still labelled (colored) by a ∈ Q 0 . Note that we will as before Figure 4. This figure represents a part of the periodic quiver diagram. In this example, the superpotential W contains two monomial terms W = Tr(Φ ba Φ ac Φ cb − Φ ba Φ ad Φ de Φ eb ). The F-term relation ∂W/∂Φ ba = Φ ac Φ cb − Φ ad Φ de Φ eb = 0 for the field Φ ba is represented by the fact that the two different paths a → c → b and a → d → e → b starting from a ending at b represents two F-term equivalent fields (i.e. same element in the chiral ring).
use symbols a, b, . . . for the vertices of the original quiver diagram Q (and hence of the periodic quiver diagram), while we use symbols a, b, . . . for vertices of the quiver Q on the universal cover.
Let us choose a particular vertex a 0 ∈ Q 0 as the "initial color", which we choose to be the origin o ∈ Q on the universal cover. 2 Let consider a set of paths starting with the origin o modulo the F-term relation. Any such path, modulo the F-term relations (as described in Figure 4), defines an atom in the crystal. This atom is placed at the location a of the two-dimensional plane, where a is the endpoint of the path. This defines the two-dimensional projection of the BPS crystal.
To fully describe the three-dimensional structure of the crystal, note that any path starting at the origin o and ending at a can be expressed in the form p o,a ω n modulo the F-term relations, where p o,a is one of the shortest paths connecting the two points o and a, and ω represents a loop in the quiver diagram along any of the faces of the periodic diagram (see Figure 5). The corresponding atom is then placed at depth n in the crystal (see Figure 6).
As an example, we show in Figure 7 the example of the BPS crystal for the Suspended Pinched Point geometry discussed in Figure 2.
It follows from the definition that for an atom and an arrow a ∈ Q 1 , there is a canonically-defined atom a · in the crystal -a · is defined by concatenation of a path representing and an arrow a, and this definition is consistent with identification modulo F-term relations. In other words, the BPS crystal naturally gives a representation of the path algebra of the quiver.  . The three-dimensional structure of the crystal configuration. An atom in the crystal is represented by a path from the origin o ∈ Q to a ∈ Q. If the path is represented as p o,a ω n modulo F-term relations, the corresponding atom is placed at depth n at the location a.  Figure 1 as the origin o of the crystal, whose location is shown by a blue dot in the center.

Crystal Melting
For a given BPS crystal, we can consider a configuration of the molten crystal.
A finite set K of atoms from the BPS crystal is a configuration of the molten crystal if it satisfies the following melting rule: melting rule: ∈ K whenever there exists an edge a ∈ Q 1 such that a · ∈ K . (2.4) This is equivalent to the condition that a · / ∈ K whenever / ∈ K, namely the condition that the complement of K is an ideal of the path algebra A (Q,W ) .
Since any path by definition starts at the origin o, it follows that the origin o is always contained in K, unless K is empty.
The molten configuration K has a finite number of atoms. Denote the number of atoms with color a as |K(a)|. The statistical partition function of BPS crystal melting is then defined to be a formal power series 3 (2.5) Figure 8. An example of a configuration of the molten crystal (left) and the complement (right). This contributes a term q 4 1 q 3 2 q 2 3 to the BPS partition function.
The statement is that this coincides with the BPS configuration of the crystal. The partition function has an infinite product form for the resolved conifold and more generally for toric Calabi-Yau geometries without compact 4-cycles, as explained by M-theory [40][41][42]. This suggests an identification of the BPS partition function as a character of some infinite-dimensional algebra. We will see that this is indeed the case.
3 Review: Plane Partition and Affine Yangian of gl 1 As explained in introduction, the current work is inspired by the relation between the affine Yangian of gl 1 and the set of plane partitions. We will now review the affine Yangian of gl 1 , its relation to the W 1+∞ algebra, and its action on the set of plane partitions.

Affine Yangian of gl 1
The affine Yangian of gl 1 , which we denote by Y ( gl 1 ), is an infinite-dimensional associative algebra generated by the following three families of modes: and whose algebraic relations are These relations are further supplemented by the initial conditions and the so-called Serre relations Note that the algebra has two parameters σ 2 and σ 3 and has two central elements ψ 0 and ψ 1 .
The algebraic relations (3.2) can be more elegantly repackaged in terms of the following three fields where here and throughout this paper ∆ is defined as and the ϕ 3 function is a cubic rational function defined as Here the triplet parameters (h 1 , h 2 , h 3 ) satisfy 9) and are related to the two parameters σ 2 and σ 3 introduced previously by Unless stated explicitly otherwise, the ∼ sign in this paper denotes equality up to regular terms of z n≥0 w m≥0 . One can easily reproduce the relations in terms of modes (3.2) by expanding (3.8) and using the relations (3.10).
Although the (e(z), ψ(z), f (z)) are not fields in a two-dimensional CFT, the relations (3.8) bear some resemblance to OPE (Operator Product Expansion) relations in a two-dimensional CFT in that (1) they are written in terms of fields (e(z), ψ(z), f (z)) and when expanded in terms of (3.5) reproduce the algebraic relations in terms of modes; and (2) the relations in (3.8) are defined up to regular terms. Therefore throughout this paper, we will abuse the terminology and call this type of relation "OPE relations", to distinguish them from the corresponding mode relation such as (3.2).
For the purpose of this paper, the relations in terms of fields are much more useful than those written in terms of the modes, 4 for the following two reasons: 1. The OPE relations (3.6) make manifest the S 3 symmetry (permuting the triple {h 1 , h 2 , h 3 }) that is inherent to the algebra but is somewhat hidden in (3.2).
2. The action of the algebra on the representations in terms of plane partition is much more transparent in terms of the OPE relations (3.6) than the mode relations (3.2), see later.
Finally, it is convenient to use the following figure to summarize the OPE relations (3.6): As is already stated in introduction, it is known that the affine Yangian of gl 1 is equivalent to the universal enveloping algebra of the W 1+∞ -algebra, see [20][21][22][23][24][25].

Plane Partition
A partition λ of an integer n can be characterized by a set of integers λ i : A plane partition Λ is a three-dimensional generalization of the integer partition plane partition of n : (3.14) and can be given by the stacking of three-dimensional boxes (denoted as in this paper), which are 3D generalization of 2D Young diagrams. The coordinates of these 's are chosen to be The generating function of plane partition counting is the MacMahon function [44] M (q) ≡ Λ∈ plane partition (3.16) where |Λ| denotes the number of boxes in the plane partition Λ. This partition function is also the partition function of the topological A-model on C 3 [3].

Action of Affine Yangian of gl 1 on Plane Partitions
The affine Yangian of gl 1 acts on the set of plane partitions (this representation is known as the MacMahon module in the literature). To describe this action, it is necessary to first endow plane partitions with additional structures, to accommodate the two parameters in the algebra, i.e.
Recall that each plane partition configuration consists of a collection of 3D-boxes, with coordinates given by (3.15). To each box , we can associate a coordinate function which naturally incorporates the parameters (h 1 , h 2 , h 3 ). The action of affine Yangian of gl 1 on a plane partition configuration Λ is given by [23,24,26] Recall the ψ(u) contains all the Cartan operators of the algebra, see the first line of (3.2). Each plane partition |Λ is an eigenstate of ψ(u), hence of all the Cartan modes ψ j with j ∈ Z ≥0 . The eigenvalue is where is the vacuum contribution. Given a |Λ , e(z) adds a in possible locations, while f (z) removes a in all possible locations. In summary: :

BPS Quiver Yangian for General Quivers
In this section let us define the BPS quiver Yangian Y (Q,W ) from a pair (Q, W ). 5 Since the pair (Q, W ) is obtained from a toric Calabi-Yau geometry X (as we discussed in section 2), the algebra Y (Q,W ) in itself can be associated with the geometry X.
In general there exist multiple quiver gauge theories (Q, W ) which are dual to each other and correspond to the same geometry X. In these situations the quiver gauge theories are believed to be related by a sequence of Seiberg dualities (quiver mutations) [45], and we conjecture that the resulting algebras Y (Q,W ) are all isomorphic. We will see concrete examples of this phenomenon in section 8.3, where the relevant isomorphism is already known in the mathematical literature. It would be interesting to explore this point further.
In this section we provide a top-down definition of the algebra. Let us quickly add, however, that we will in later sections provide bottom-up justifications of the algebra. Indeed, as we will see in section 6, the condition that this algebra acts on the configurations of molten crystal fixes the algebra under some reasonable ansatz. In this sense our algebra and its representation on the BPS crystal are intimately connected.

Parameters
To define the BPS quiver Yangian Y (Q,W ) , we first consider a set of charge assignments h I for each arrow I ∈ Q 1 . We impose the condition that this charge assignment is compatible with the superpotential W . In other words, the charges h I can be regarded as charges under a global symmetry of the quiver quantum mechanics. The superpotential W will enter into the definition of the algebra Y (Q,W ) through this charge-assignment constraint only.
In the periodic quiver diagram a monomial term in the superpotential is represented by a closed loop. This means that the constraint on the parameters h I can be written as 6 loop constraint: where L is an arbitrary loop in the periodic quiver. We will hereafter call this condition the loop constraint, and the parameters satisfying these conditions as coordinate parameters. In section 6.4 we will see that this constraint is instrumental in ensuring the consistency of the crystal-melting representation of the algebra. We can count the number of coordinate parameters to be N h = # (edges of the quiver) − (# (monomial terms in the superpotential) − 1) .
Here we have subtracted one from the superpotential constraints, since any bifundamental field appears exactly twice in the superpotential (this follows since any edge belongs to two neighboring faces in the periodic quiver) and thus one of the constraints is redundant. Since each monomial term in the superpotential corresponds to a polygonal region of the periodic quiver, one can also write this as N h = # (edges of the periodic quiver) − (# (faces of the periodic quiver) − 1) .
Since the periodic quiver is written on the two-dimensional torus and has Euler character zero, one can rewrite this as N h = # (vertices of the periodic quiver) + 1 = # (gauge groups of the quiver) + 1 .
For a toric Calabi-Yau manifold this number (i.e. # = N h − 1) is known to be the same as the area of the toric diagram ∆, where the normalization of the area is chosen such that the minimal lattice triangle spanned by lattice points (0, 0), (1, 0), (0, 1) has area 1. One can then use Pick's theorem to rewrite this as where E (and I) are the numbers of external (internal) lattice points of the convex polygon (toric diagram) ∆. We will use {h I }, with I = 1, · · · , |Q 1 |, to denote the set of charges associated to the edges of the quiver; and we use {h A }, with A = 1, · · · , N h , to denote these N h independent parameters that characterize the algebra.

Generators and Relations
The algebra is generated by a triplet of fields e (a) (u), ψ (a) (u), f (a) (u) for each quiver vertex a ∈ Q 0 : a : Generically, they have the mode expansion: and contain infinitely-many generators e (a) n . As we will show later in section 8, for Calabi-Yau three-folds without compact 4-cycles, ψ n<−1 = 0. We will see later that the action of the algebra on the crystal representation also ensures (8.4).
We express the Z 2 -grading (i.e. the Bose/Fermi statistics) of the generators e where |a| = 0 (|a| = 1) for bosonic (fermionic) generators. We always choose the generators ψ (a) n to be even.

Relations in Terms of Fields
The generators satisfy the OPE relations where throughout this paper " " and "∼" mean equality up to regular terms w k≥0 and z j≥0 w k≥0 , respectively, and The bracket [e (a) (z), f (b) (w)} represents the commutator in the superalgebra sense. Namely, this is an anti-commutator {e (a) (z), f (b) (w)} when both a and b are odd, and is a commutator [e (a) (z), f (b) (w)] otherwise. The function ϕ a⇒b (z), which we call the "bond factor" since roughly speaking it describes the "bonding" between atoms of color a and atoms of color b, is defined to be where {a → b} denotes the set of edges from vertex a to vertex b. When there is no arrow between vertex a and vertex b in the quiver (denoted as a ←→ b), the bond factor is trivial: The corresponding pair of (e (a) (z), ψ (a) (z), f (a) (z)) commute or anti-commute (depending on the sign ). The bond factor satisfies the reflection property which is needed for the consistency of the OPE relations. The relations (4.9) (except for the e, f relations) are summarized in the following graph: 7 We emphasize that the bond factor ϕ a⇒b (u) (4.11) should be treated as a "formal" rational function. Namely, all the factors in its numerator and denominator, one pair (i.e. one in the numerator and one in the denominator) from each arrow in the quiver, need to be kept even when the charges h I take some special values such that some factors of the numerator and the denominator cancel each other. The reason is that the algebra can also be expressed in terms of modes (e

Relations in Terms of Modes
With the mode expansions of the fields in (4.7), it is straightforward to expand the OPE relations (4.9) and write down the corresponding relations in terms of modes.
The first and the last equations in (4.7) do not involve the bond factor (4.11) and are easy to translate into the mode relations All the remaining ones involve the bond factor (4.11), whose numerator and 7 Note that to reduce clutter, in the graph (4.14) we have omitted the additional statistics factors in (4.9), i.e. (−1) |a| for the e (a) (z)e (a) (w) and f (a) (z)f (a) (w) relations, (−1) |b| for the e (b) (z)e (b) (w) and denominator can be rewritten as where |a → b| denotes the number of arrows from a to b in the quiver diagram, and σ a→b k denotes the k th elementary symmetric sum of the set {h I } with I ∈ {a → b}. Now take the ψ (a) e (b) OPE for example. Using the expansion (4.16), the ψ (a) e (b) OPE relation can be written in terms of quiver data {h I }: (4.17) Plugging in the mode expansions of ψ (a) (z) and e (b) (w) from (4.7), expanding the (z − w) k in (4.17), and extracting the terms of of order z −n−1 w −m−1 with n ∈ Z and m ∈ Z ≥0 , we have the mode relation: for n ∈ Z and m ∈ Z ≥0 , where we have defined the shorthand Here we can see that it is important to keep all factors in ϕ b⇒a (z − w), even when the charges h I take special values such that some factors in the numerator and denominator cancel each other. Ultimately what is important is the expansions (4.16) of the numerator and the denominator separately, which in particular control the mode shifting in the mode relation (4.18).
Repeating the exercise for the remaining equations in (4.9), we have their corresponding relations in terms of the modes: where for ψ

Grading and Filtration
As a vector space, the algebra Y (Q,W ) has a triangular decomposition where Y + (Q,W ) (Y − (Q,W ) ) are generated by the e The algebra has some more structures in addition to the Z 2 -grading just introduced. First, for each vertex a ∈ Q 0 we can define an associated Z-grading deg a ("grading by color a", mode grading) by Second, the algebraic relations (4.9) with (4.11) have a rescaling symmetry for the parameters h I , the spectral parameter u, and the generators: 8

(4.24)
In terms of the mode generators, (4.24) is due to the mode expansion (4.7). The rescaling symmetry (4.25) defines the grading together with deg level (h I ) = 1. We can also regard this as a filtration (level filtration, spin filtration) on the algebra when we assign zero degree to h I , while keeping the assignments on mode generators (4.26).

Gauge-symmetry Shift
As we discussed above, the parameters {h I } can be regarded as global-symmetry assignments of the algebra. We have therefore imposed the loop constraints (4.1). One notices, however, that some of these symmetries are actually gauge symmetries. Indeed, if we mix the global symmetry with a gauge symmetry associated at a particular vertex a, then the parameters h I are shifted as  and ε parametrizes the mixing between global symmetries and the a-th gauge symmetry. This shift is consistent with the loop constraint (4.1). This is of course expected since the superpotential is gauge-invariant. What happens to the algebra under this shift? The parameters h I enter into the algebra only through the function (4.11), which transforms as .
(4.29) 8 The scaling behaviors of ψ (a) (u) is determined by the consideration that in some examples (i.e. for Calabi-Yau three-folds without compact 4-cycles), we are allowed to fix ψ  In other words, this amounts to constant shifts of the spectral parameter u in various locations. Since the mode expansion (4.7) is in powers of z −1 , one concludes that the shift (4.27) mixes the n-th generators only with m ≤ n-th generators. Since automorphism merely reshuffles the generators by linear combinations, one can regard the shift (4.27) as a gauge symmetry.
Instead of modding out by the gauge shift (4.27), we can impose gauge-fixing conditions. One possible choice, which we adopt in this paper, is to impose the vertex constraint vertex constraint: for each vertex a. Note that the number of independent constraints is given by the number of vertices minus one, since the quiver quantum mechanics has only bifundamental/adjoint matters and hence the overall U (1) gauge symmetry decouples. How many parameters are there if we impose both the loop and the vertex constraints? Since the number of parameters with the loop constraints is given as |Q 0 | + 1 (4.4), and since we have |Q 0 | − 1 vertex constraints, there are two remaining parameters. We can identify these two parameters as the coordinate parameters of the toric Calabi-Yau three-fold -a toric Calabi-Yau three-fold has three U (1) isometries, one of which can be identified with the R-symmetry of the supersymmetric quiver quantum mechanics, leaving behind two U (1) symmetries. 9 Readers familiar with four-dimensional N = 1 quiver quantum gauge theories will recognize the two U (1) symmetries as the so-called mesonic (non-R) global symmetries. In this context one also has the so-called U (1) baryonic global symmetries. The latter symmetries, however, are not present in our context. The difference arises since in four-dimensional quiver gauge theories one often considers SU (N ) gauge groups at the nodes of the quiver, while here one considers U (N ) gauge groups.

Spectral Shift
One can shift the spectral parameter z by an overall constant. This again linearly mixes the generators, and generates an automorphism of the algebra. More explicitly, in terms of the mode expansions introduced in (4.7), one obtains under the shift 9 The two parameters can be regarded as an element of the first cohomology of the exact sequence which can be viewed as a cohomology cochain complex for the periodic quiver, see e.g. section 2.3 of [46]. z → z − ε a new set of modes e l , ψ l , f l : The last equation involves an infinite sum and should be regarded as a formal sum. This equation is trivialized to ψ −1 = ψ −1 for the toric Calabi-Yau three-fold geometries without compact 4-cycles, where we have ψ n<−1 = 0.

Serre Relations
For the examples in section 8, the BPS algebra Y (Q,W ) is related to the affine Yangian of gl n and more generally gl m|n . More precisely, while the quiver Yangians Y (Q,W ) are themselves different from affine Yangians, we can add a set of new relations, which are traditionally called the Serre relations, to define a reduced quiver Yangian algebra and it is this algebra Y (Q,W ) which coincides with Y ( gl n ) or Y ( gl m|n ). We will discuss explicit examples of the Serre relations in section 8. We will find in section 6 that the algebra Y (Q,W ) acts on the configurations of molten crystal. On the other hand, the reduced algebra Y (Q,W ) also acts on the same configurations of the molten crystal. Namely, the extra Serre relation are also satisfied for the representations φ : Y (Q,W ) → End(V ) discussed in this paper: For a general toric Calabi-Yau manifold there seems to be no known counterpart of the affine Yangian Y ( gl m|n ), and hence one needs to find the appropriate Serre relations such that (4.34) holds. More precisely, one wishes to find a maximum set of relations such that Y (Q,W ) is still non-trivial and (4.34) holds. We leave detailed exploration of this for future work, except to note that one possible approach is to take advantage of the invariant bilinear pairing (Shapovalov form, see e.g. [24] for the case of Y ( gl 1 )): one can define the Serre relations to be the generators for the radical for the invariant pairing, so that the Shapovalov form is non-degenerate in the reduced quiver Yangian Y (Q,W ) .

Bootstrapping Affine Yangian of gl 1 from Plane Partitions
In section 6 we will discuss the representation of the BPS quiver Yangian Y (Q,W ) and motivate the definition of the algebra. As a preparation of the discussion, let us first discuss the case of the C 3 and the associated algebra, the affine Yangian of gl 1 .
Historically, the affine Yangian of gl 1 was constructed first and then plane partitions were found to be one of its representations. The review in section 3 followed this logic. However, suppose we do not know about the affine Yangian of gl 1 , but rather want to construct an algebra that acts transitively on the set of plane partitions. Within a certain ansatz, we would find that this algebra is precisely the affine Yangian of gl 1 .
In this section, we will reconstruct the affine Yangian of gl 1 purely from its action on the set of plane partitions. Although the algebra itself is known, the goal of this section is to develop a procedure that can be generalized in the next section to construct algebras that act on the colored crystals, which describe the BPS states of type IIA string on arbitrary toric Calabi-Yau three-folds.
The plane partition configuration as the familiar 3D box stacking can be regarded as a particular example of the crystal melting model introduced in section 2. The quiver diagram for C 3 is and the periodic quiver for the C 3 -theory is a triangular graph on the two-dimensional torus. Its uplift Q to the universal cover is the triangular lattice, which is the dual graph of the hexagonal tiling describing the plane partitions (in other words, the hexagonal tiling is the brane tiling graph).

Ansatz
The algebra consists of three families of operators where z is the "spectral parameter" and σ 3 is a parameter to be defined later. 10 10 Note that the general mode expansion (4.7) specializes for this case with ψ <−1 = 0, as in all quiver Yangians for Calabi-Yau three-folds with no compact 4-cycles. Moreover, we have rescaled the modes ψ n in (4.7) in order to match the convention for the mode expansions of the affine Yangian of gl 1 in the literature.
The action on the plane partitions is chosen such that 1. Each plane partition Λ is an eigenstate of the Cartan generators ψ(u), which means that Λ is an eigenstate of all the zero modes ψ n with n ∈ Z ≥0 .
2. Given a plane partition Λ, the action of e(u) on it adds a box at all possible positions (where a box can be legitimately added). An ansatz for the action of the algebra on plane partitions that satisfies the three conditions above is where Ψ Λ (z) is the eigenvalue of Λ. The ansatz (5.4) is the only assumption for our construction of the algebra.
Given this ansatz, the goal of the bootstrap is to 1. Determine the structure of poles h( ) in the e(z) and f (z) action part of the ansatz (5.4). The criterion is that by applying the creation operator e(z) iteratively on the vacuum |∅ , i.e. the plane partition configuration with no box present, one can generate all plane partitions. In the other way around, applying the annihilation operator f (z) repeatedly on any plane partition |Λ would eventually reduce it to the vacuum |∅ .
2. Determine the charge function Ψ Λ (z) for arbitrary plane partition Λ. The criterion is that the pole structures of the actions of e(z) and f (z) in (5.4) should be encoded in the function Ψ Λ (z). Namely, for a given plane partition Λ, all the poles of its charge function Ψ Λ (z) correspond to either a location where a can be added to Λ or the location of an existing in Λ.
3. Find all relations between the three families of operators (5.2) that are automatically satisfied when acting on an arbitrary Λ, given the ansatz (5.4) and the charge function Ψ Λ (z) determined in step-2.
The relations found in step-3 then define the algebra.

Analysis
Let us now start with the step-1. A box in the plane partition is labelled by the coordinate To each , we can associate a coordinate function where h i with i = 1, 2, 3 are formal variables for now, whose function is just to translate the coordinate-triplet (x 1 ( ), x 2 ( ), x 3 ( )) to one number h( ), so that one can directly relate a to the poles of Ψ Λ (z). As we will see, the h i might not be mutually independent, and their relations will be determined by the criterion in step-2.
Now we move on to step-2, fixing the charge function Ψ Λ (z) for an arbitrary plane partition Λ. Given that a plane partition consists of a set of 's, each with its coordinate function h( ), the most natural ansatz for Ψ Λ (z) is 12 where ψ 0 (z) is the contribution from the vacuum, i.e. before any is added, and ψ (z) is the contribution of an individual . Therefore we only need to fix the functions ψ 0 (z) and ψ (z). The main constraint is that for any Λ, all poles of Λ should correspond to either a location where a can be added or a location where a can be removed.

Vacuum −→ Level-1
Let us start with the vacuum contribution ψ 0 (z). Starting with the vacuum state |Λ = |∅ , the action of e(z) should create the first at the corner, with coordinates and h( ) given by level-1 : 0 : Since this is the very first that can be added in the plane partition, we call it level-1 box: 1 (5.9) Here the box is labelled by 1 since we have only one vertex in this example. (We encounter more general situation in the next section.) The charge function for the vacuum Ψ Λ (z) = ψ 0 (z) should have one and only one pole 13 , at adding-pole of : Furthermore, ψ 0 (z)'s residue at z = 0 should be non-zero -otherwise by the ansatz (5.4) the action of e(z) on vacuum would annihilate the vacuum instead of creating the first . The simplest solution is where C = 0 will be fixed later. In summary, the actions of (e(z), ψ(z), f (z)) on the vacuum |∅ are: To fix ψ (z), first consider the initial state |Λ = | , where | denotes the configuration where only the first at the corner is present. The next to be added can be placed in three possible positions: level-2 : This means that the function Ψ Λ (z) for the initial state |Λ = | needs to contain these three poles h i with i = 1, 2, 3.
In addition, Ψ Λ (z) for the initial state |Λ = | should contain a pole at z * = 0, corresponding to the pole for f (z) to remove this to reduce it to vacuum: This pole is already accounted for by the pole in ψ 0 (z) in (5.11). Namely, the pole in ψ 0 (z) corresponds to both the creating-pole of e(z) when acting on |∅ and the removing pole of f (z) when acting on | . Indeed, this is a general feature for ψ Λ (z) of all Λ -namely, a creating-pole for e(z) acting on Λ and generating a particular is also the same pole for the (removing) action of f (z) when acting on the configuration |Λ + and removing this same . Therefore, the three poles that correspond to the three 's in (5.13) must all come from the function ψ (z) when is the level-1 box in (5.8): where N (z) is the numerator to be fixed momentarily. In summary, the charge which has three adding-poles at 18) in addition to the removing-pole given in (5.15). The actions of (e(z), ψ(z), f (z)) on the level-1 state | are: level-1 : 19) where again # denotes various numerical constants to be fixed later systematically.

Level-2 −→ Level-3
We have just seen that to fix the denominator of the charge function for the state at level-1, we need to consider the creation of the three level-2 's in (5.13). By the same logic, to fix the denominator of the charge function for the level-2 states, we need to consider the creation of the level-3 's.
There are 6 's at level-3, at position level-3 : To create them, the charge function of the level-2 states, i.e. the states that contain one level-1 and one or more level-2 's, must contain these poles. Let us first consider the first three 's in (5.20). Take the first one for example. To create the at the position (x 1 , x 2 , x 3 ) = (2, 0, 0), there must be at least two existing 's sitting at (x 1 , x 2 , x 3 ) = (0, 0, 0) and (x 1 , x 2 , x 3 ) = (1, 0, 0). Namely, the charge function of the (minimal) initial state 14 has to be Ψ Λ (z) = ψ 0 (z)ψ 0 (z)ψ 1 (z), which must contain a pole at z * = h( (2,0,0) ) = 2h 1 . Considering all the first three states in (5.20), we see that the charge function of a (minimal) initial state on which one of the first three states in (5.20) can be added is which must contain a pole at Recall that the poles from the first two factors ψ 0 (z) and ψ 0 (z) of (5.22) contain poles at 0 and h 1,2,3 , given by (5.15) and (5.18). Therefore the adding-pole z * = 2h i must come from the 3rd factor of (5.22). Similarly, for any of the last three 's to be added, we need the (minimal) initial state to have at least one level-1 sitting at (x 1 , x 2 , x 3 ) = (0, 0, 0) (given by (5.8) and two of the three level-2 's in (5.8), with charge function for i, j = 1, 2, 3 and i = j . (5.24) which must contain the adding-pole of It is then easy to see that the following choice satisfies these two constraints (5.23) and (5.25) ψ where ψ 0 (u) is given by (5.16). It is more instructive to rewrite it as Having obtained (5.27), we are now ready to fix the numerator in (5.16). Consider a plane partition |Λ that contains the level-1 and one of the three level-2 's in (5.13). The presence of the level-2 means that the level-1 can no longer to removed. This means that the removing-pole z * = h( ) = 0 must be canceled by a factor in the numerator of the charge function of the level-2 . Namely, N (z − h i ) must contain a factor of z for any i = 1, 2, 3. This constraint fixes the minimal N (z) to be We now have the most important function in the construction of the algebra acting on the set of plane partitions: By (5.27), we see that the each of the level-2 's contribute a factor of ϕ 3 function, with argument shifted by h( ).
Before we move on, we need to check whether the three parameters h 1,2,3 are mutually independent. Compare the minimal initial state (5.22) (in order to add one of the first three 's in (5.20)) and the minimal initial state (5.24) (in order to add one of the last three 's in (5.20)). For example, if one starts with the initial state (5.22), one can only add a at h( ) = 2h i , but not the at h( But this fact has to be implemented automatically by the pole structure of the charge function (5.22). Without loss of generality, consider i = 1, for which the charge function (5.22) is explicitly 15 .
(5.30) Note the three poles in the ψ 1 (z). The first one allows e(z) to add a level-3 The other two poles, however, correspond to two 's (with h( ) = h 1 + h j for j = 2, 3) that are not allowed to be added now (see Figure 9): This means that these two poles have to be canceled by factors in the numerator of ψ 0 (z), which gives the constraint (5.33) Figure 9. The configuration on the left (depicting (5.31)) is a legitimate plane partition. By contrast the configuration on the right (depicting one of (5.32)) violates the melting rule and is not a plane partition.

General Levels
One can now repeat the argument above and try to generate all possible plane partition configurations iteratively. It is straightforward to see that the result (5.27) applies to all 's in a plane partition. Namely, each in a plane partition Λ contributes a factor of ϕ 3 function, with argument shifted by h( ): The full charge function of the plane partition Λ is then Here we have taken advantage of this opportunity to determine the constant C inside ψ 0 to be σ 3 ψ 0 , so that the mode expansion of Ψ Λ (z) has the same form as in (5.2).
We now revisit the ansatz for the action of (e(z), ψ(z), f (z)) on arbitrary plane partitions. With the assignment of the charge function (5.36) for an arbitrary plane partition Λ, one can check that indeed all the poles of Ψ Λ (z) belong to either of the following two classes: • The pole is equal to the coordinate function of a that is on the "surface" of Λ. This pole is a removing-poles for the action of f (z).
• The pole is equal to the coordinate function of a that can be added to Λ, which means that the pole is related to one of the removing-pole by a shift of h i with i = 1, 2, 3 depending on the direction the is relative to Λ. This pole is an adding pole for the action of e(z).
Namely, the charge assignment (5.36) enables the ansatz (5.4) to define the action of (e(z), ψ(z), f (z)) on the set of plane partitions, where the adding and removing of 's are implemented automatically due to the pole structure of the charge function (5.36). In particular, one can apply the action of e(z) in (5.4) (without worrying about the coefficient given by the residue for now. 16 ) repeatedly starting from the vacuum |∅ and generate all possible plane partition configurations.
Let us summarize the relations for our algebra: OPE: Serre : We here have here included the Serre relations of the Y ( gl 1 ) known in the literature, which we can verify on the representation at hand.

Bootstrapping General BPS Algebras
In this section we generalize the discussion of the previous section for C 3 to the case of an arbitrary toric Calabi-Yau three-fold. It takes the following four steps: 1. Fix the ansatz for the action of the algebra (to be determined) on the set of colored crystals (in section 6.1).
The ansatz contains three layers of information: (1) the pole structure of the action, which guarantees that applying the creation operators of the algebra iteratively on the vacuum can create the entire set of colored crystals; (2) the moduli of coefficients of the action, which fixes the algebra (apart from the signs); and (3) the signs in front of these coefficients. Both (1) and (2) are determined by the "charge function" of the colored crystals; whereas (3) needs to be fixed after the algebra (including signs in it) is fixed.
2. Fix the charge function from the quiver data (in section 6.2 and 6.3), by demanding that part (1) of the ansatz, i.e. the pole structure of the action (for building up the crystal iteratively), is automatically realized by the poles of the charge function. The result of the charge function also determines the part (2) of the ansatz.
3. Fix the algebra from the quiver data and the ansatz of the action (part (1) and (2)) (in section 6.5). The former controls the statistics (i.e. bosonic or fermionic) of the operators, which manifest as various signs in the algebraic relations; whereas the latter controls the magnitudes in the algebraic relations.
4. Fix the part (3) of the action, i.e. signs in front of the coefficients of the action, from the statistics of the algebra (in section 6.6).

Ansatz for Representation
A molten configuration of the BPS crystal, which we have reviewed in section 2, is a generalization of the plane partition in two ways: 1. The atoms in the crystal can be of multiple colors labelled by a quiver vertex a ∈ Q 1 . We will use a to label an atom of color a, generalizing for a 3D-box in the plane partition Λ.
2. The geometric crystal structure is given by the quiver diagram, following the rule outlined in section 2. It is still periodic since it corresponds to a tiling of a torus, but it does not need to have the hexagonal symmetry of the (rhombus tilings) of the plane partitions.
We use the letter K (in text mode) to label a colored crystal configuration. The plane partition can be viewed as the simplest colored crystal, with only one color and the most symmetric configuration.
As reviewed earlier in section 2.2, for the construction of the colored crystal we need to choose an atom as the origin of the crystal. Without loss of generality, we will choose the atom at the origin to be of color a = 1. 17 It corresponds to the level-1 box 1 in (5.8).
In the C 3 case, where there is only one type of atom, the algebra has a triplet of fields, i.e. family of generators, (e(z), ψ(z), f (z)), see (5.3), acting on all the atoms in the crystal (or equivalently, all the 's in the plane partition). For a generic toric Calabi-Yau whose corresponding crystal has |Q 0 | colors, we need |Q 0 | triplets of fields labelled by a ∈ Q 0 , each acting on the atoms of the corresponding color as in (4.6); they have the mode expansion as in (4.7). Now we write down the ansatz for the action of the fields (4.6) on an arbitrary crystal configuration |K , as a natural generalization of the ansatz (5.4) for the action of the affine Yangian of gl 1 on the set of plane partitions: Here a ∈ Add(K) means that we consider an atom of color a which can be added to the crystal K (a similar comment applies to a ∈ Rem(K)).
Before we proceed, let us explain the reason behind the ansatz (6.2). First of all, as a natural generalization of the action (5.4) of the affine Yangian of gl 1 on the set of plane partitions, each colored crystal state |K is an eigenstate of the zero modes ψ (a) (z). The operator e (a) (z) adds an atom with color a to |K at all allowed places, whereas f (a) (z) removes an atom with color a from |K at all allowed places.
The important part of the ansatz is that the actions of e (a) (z) and f (a) (z) are determined by the ψ (a) (z) eigenfunction of the initial state |K , called "charge function" here. In particular, the position of the atom a to be added to |K by e (a) (z) or removed from |K by f (a) (z) is given by the poles of the charge function of |K .
The coefficients of the action, i.e. E (a) (K → K + a ) and F (a) (K → K − a ), are then given by the residue of the charge function at that particular pole. The square roots in the coefficients in (6.3) are due to the natural generalization of (5.4). The factors p (a) and q (a) are constants allowed by the ansatz, i.e. they do not affect the pole structure of the e (a) (z) and f (a) (z) actions. As we will see later, only their product p (a) q (a) matters; hence without loss of generality we can set q (a) = 1. Later in section 6.5.3 we will show that p a is given by and is related to the bosonic/fermionic nature of the operators e (a) (z) and f (a) (z) via: This explains the grading rule we stated earlier in (4.8). 18 We postpone the proof of (6.6) to section 6.5.3. For the affine Yangian of gl 1 , p (1) = −1, which explains the sign difference inside the square roots of the e(z)'s and f (z)'s actions in (5.4).
Finally, the ± signs in front of the square roots, i.e. (K → K + a ) and (K → K− a ) in (6.3), depend both on the initial crystal state K and on the atom a (to be added or removed). As explained earlier, they need to be chosen so as to reproduce the statistics of the algebra, which will be fixed by the quiver data.
Although a crystal K consists of atoms of possibly multiple colors, each triplet (e (a) , ψ (a) , f (a) ) has its own charge function Ψ (a) K (z) and only acts upon the atoms of its own color a. However, we emphasize that this does not mean that each charge function Ψ (a) K (z) only receive contribution from atoms of color a -it is just that the action of (e (a) , ψ (a) , f (a) ) is only controlled by the charge function Ψ With the ansatz (6.2), we are now ready to construct the algebra that realizes (6.2). Similar to the case of the affine Yangian of gl 1 , the procedure is the following.
1. Determine the structure of the poles h( a ) in the e (a) (z) and f (a) (z) action part of the ansatz (6.2). The criterion is that by applying all the creation operators e (a) (z), with a = 1, . . . , |Q 0 |, iteratively on the vacuum |∅ , i.e. the crystal with no atom present yet, one can generate all possible crystal configurations of this type. In a similar manner, applying all the annihilation operators f (a) (z), with a = 1, . . . , N , in turn on any crystal |K would eventually reduce it to the vacuum |∅ .
2. Determine the charge function Ψ  3. Find all relations between the three families of operators (4.7) that are automatically satisfied when acting on an arbitrary crystal K, given the ansatz (6.2) and the charge function Ψ The relations found in step-3 then define the algebra. Let us note that the strategy above already suggests the Z 2 -grading (Bose or Fermi statistics) of the generators. Suppose that none of the arrows I ∈ Q 1 satisfies s(I) = t(I) = a, namely none of the arrows starts and ends at the same vertex a. When we apply e (a) (z) multiplet times as e (a) (z 1 )e (a) (z 2 ) . . . |K , this then necessarily vanishes after a finite number of e (a) 's. This is because for any finite K we can add only a finite number of atoms of color a. In this case we expect e (a) (z) to have Fermi statistics. A similar argument suggests Fermi statistics for f (a) (z). The remaining generator ψ (a) (z) turns out to be even, since we will later find that ψ (a) (z) is obtained from the commutators between e (a) (z) and f (a) (z), see e.g. (4.9). This suggests the Z 2 -grading as in (4.8).

Fixing Coordinate Function
We first need a coordinate system generalizing (5.5). For a crystal of generic shape, it is no longer natural to assign each atom a 3D coordinate. Instead, an atom a can be (non-uniquely) characterized by a path in the periodic quiver Q staring from the origin o. Let us denote this path as Note that there are infinitely many such paths for each a , given the presence of loops in the periodic quiver.
For each color a, we would like to define a coordinate function that is adapted to the coordinate system (6.7), generalizing the coordinate function (5.6). The most natural way would be to associate a charge h I to each edge I in the quiver diagram, where I ∈ {a → b} for two vertices a and b (which are possibly identical). We then define the coordinate function for a to be the sum of all the charges along the path [o → a ]: Recall that in the case of plane partitions, the coordinate function for an atom is the way to translate the position of the to the pole of the charge function Ψ Λ (z). We need the same for the colored crystal. Therefore, although for a given a , the path [o → a ] is not unique, we need its coordinate function to be uniquely defined, in order to associate it to the poles of Ψ (a) K (z). This requires that the sum over charges on the edges around any loop has to vanish, as in (4.1). This condition is the generalization of (5.33) for plane partitions.

Fixing Charge Function
We are now ready to fix the charge function Ψ (a) K (z) for an arbitrary colored crystal K and any color a.

Ansatz
Generically, the charge function of Ψ where ψ (a) 0 (z) is the vacuum contribution, and we have grouped the atoms in K by their colors, with the color label b running over all vertices in the quiver diagram, including the color a itself. For each color b, each atom of color b contributes a factor of ϕ b⇒a function, with argument shifted by the coordinate function of that atom, given by (6.8) with the charges subject to the loop constraint (4.1).
Given the ansatz for the charge function (6.9), the goal is to determine the bond factor ϕ b⇒a (z) (so called because it describes the "bonding" between atoms of color a and those of color b). We use the ansatz for the algebra's action (6.2) on crystals |K , following the procedure outline in section 6.1. As in the case of C 3 , we first consider how to grow the first few layers (or levels) of the crystal by applying e (a) (z) (for all a) starting from the vacuum.
In particular, the poles for the charge function at level-n are fixed by considering adding atoms at level-(n + 1), since they control the (creation) action of the operator e (a) (z). Similarly, the numerators for the charge function at level-n are fixed by demanding that they should cancel relevant poles in the charge function at the level n − 1, since the presence of these level-n atoms prevents the level-(n − 1) atoms from being removed by the operators f (a) (z). The whole computation is facilitated by the fact that to the charge function Ψ (a) K (u), atoms of the same color (e.g. b) contribute the same factor, with only the argument shifted by the coordinate function of the atoms, see ansatz (6.9).
The vacuum contribution to the charge function Ψ (6.11) When acting on the vacuum, e (a) (z) creates an atom a at the origin if C (a) = 0.
In general, one can allow arbitrary {C (a) }. The representation, labeled by {C (a) }, would consist of tensored representations in which each irreducible representation, labeled by C (a) = 0 with a ∈ Q 0 , consists of crystal states whose leading atom (at the origin) has color a. However, the algebra obtained from such more general representations (i.e. tensored representations of crystals starting with different a ) via the bootstrap procedure would be the same as the one obtained using the crystal starting with a with a particular color a ∈ Q 0 . Therefore it is enough to consider the irreducible representation, where only one C (a) is nonzero.
Without loss of generality, we assume that the first atom in the crystal has color a = 1, namely C (a) = Cδ a,1 , (6.12) therefore the vacuum contribution to the charge function is with C = 0 a constant to be fixed later. Therefore, the charge function for the vacuum |K = |∅ , for any color a, is , (6.14) whose pole corresponds to the adding pole for e (a) (z) at level-1: The resulting state at the level-1 is denoted by In summary, the action of (e (a) (z), ψ (a) (z), f (a) (z)) on the vacuum is The level-1 atom is unique, and has coordinate function h( 1 ) = 0 (6.18) (see (6.15)) and its color a charge function, for any a ∈ Q 0 , is We need to fix ϕ 1⇒a (z). As in the case of C 3 , the poles of the charge function at level-1 is fixed by considering adding the level-2 atoms. In the quiver diagram, consider the arrows that emit from the vertex b = 1, the vertices these arrows end at correspond to the atoms to be added at the level-2. In order for the creation operators e (a) (z) for these colors to be able to create these atoms, the factors= ϕ 1⇒a (z) in the charge function (6.19) has to contain the pole 1 z−h I , where h I is the charge associated to the arrow 1 → a. (Note that there can be multiple arrows going from 1 to a, then for each arrow there is an independent h I .) If a vertex a is not connected by any arrow starting from 1, it doesn't contribute any pole factor. Namely, the factor ϕ 1⇒a (z) for all a contains: where a → b denotes the case when there is an arrow from a to b, whereas → indicates otherwise. Define the numerator and denominator of the factor ϕ b⇒a (z) The minimal solution for the denominator D 1⇒a (z) is The pole structure (6.20) is for the color-a charge function of the leading atom which has color b = 1. However, the argument in deriving (6.20) applies to all colors b, given that we could have chosen the leading atom in the crystal to be of any color.
for any two colors a and b. Note that this notation allows us to express the contribution from atoms of color b to the color-a charge function uniformly, irrespective of whether there is an arrow from b to a or not. Therefore, each color b contributes a factor ϕ b⇒a (z) to the color-a charge function. The charge functions of the level-1 atom are thus Ψ (a) . (6.24) We could have chosen another color b = 1 as the color for the leading atom of the crystal; in this case the charge function of the level-1 atom would be Ψ (a) To determine the numerator N 1⇒a (z), or more generally N b⇒a (z), we need to move to the next level. The level-1 charge function (6.19) has poles at removing-pole : The action of (e (a) , ψ (a) , f (a) (z)) on the level-1 state |K = | 1 is then

Level-2
Let us consider the state with one level-1 atom of color b = 1 and one level-2 atom of color c = 2, for which the arrow from 1 → 2 has to exist in the quiver diagram.
The charge function of this state is where the first bracket contains contributions from the vacuum and the level-1 atom and hence is identical to (6.25), and the second bracket is the contribution from the one level-2 atom 2 that we are considering, with Compare the charge function (6.29) to the level-1 charge function (6.24). Since the presence of the level-2 atom prevents the level-1 atom from being removed by the f (1) (z) operator, we need a numerator factor in the second bracket of (6.29) when a = 1, i.e. the numerator of ϕ 2⇒1 (z) has to contain the factor that cancels the z * = 0 removing pole in ψ (a=1) 0 (z). In addition, since this needs to happen for any atom of color c = 2 at the level-2, we have As with the denominator, this argument works for any two colors a and b, therefore we have To summarize, the contribution to the color-b charge function from atoms of color a is given by the bond factor (4.11). An atom of color b at a position with coordinate function h( b ) contributes to the color-a charge function by: Taking the contributions from all the atoms in the crystal -all colors including color a, we get the color-a charge function: where the vacuum contributes only to the charge function of color a = 1: . (6.37)

Melting Rule in General and Loop Constraint
We can now verify in general that the representation given by (6.2) and (6.3), with charge function Ψ (a) K (u) defined in (6.9) and bond factors ϕ b⇒a (u) defined by (4.11), is consistent with the melting rule of (2.4). In particular, we will show that the loop constraint (4.1), which is a generalization of the constraint (5.33) that comes from the box-stacking rules for the plane partitions, follows from the general melting rule (2.4). The crux of the argument is the same as in the low-level examples above.
Suppose that we have an atom a ∈ K inside a molten crystal configuration K. Suppose moreover there exists another atom b which is connected to the atom a by an arrow I : a → b and which moreover is not in the crystal configuration K. We can now try to create atom b by applying the generator e (b) (z) to the state |K .
One might expect that it is always possible to create atom b . However, the melting rule says that this is not possible if there exists another atom c which is not in the crystal K and is connected to the atom b by an arrow J : c → b : this should be reflected in the charge function.
In order to see this, let us first project the crystal down to the periodic quiver (recall that an atom a of the crystal is specified by a pair (a, n), where a is a vertex of the periodic quiver and the non-negative integer n specifies the depth along the crystal (see Figure 6)). In the periodic quiver one can find a vertex d such that (1) there exists an arrow K : b → d and (2) there exists a path d → a. In other words, the arrows I : a → b and K : b → d belong to the same polygonal region of the periodic quiver.
In this figure we have used the wiggly line between d and a to emphasize that this is in general not a single arrow, but a path consisting of several arrows. We have denoted the weight for this path to be h d→a .
Let us now uplift this picture to the three-dimensional crystal. Since b is not contained in the crystal K, the melting rule says that another atom d = K · b is also not in the crystal K. However, since there exists a path from d to a , the melting rule also suggests that there exists another atomd in the same position d of the periodic quiver such thatd belongs to the crystal configuration K. We can choose suchd with the maximal depth, so that we haved = (d, n − 1). We emphasize thatd = (d, n − 1) and d = (d, n) are in different depths inside the crystal.
Let us now consider the charge function Ψ On the other hand, since the difference between d andd are only loops around the periodic quiver, we have where L is the loop in the periodic quiver that characterizes the difference between d andd . For (6.41) to hold in general, we need to impose the loop constraint (4.1) for all loops in the period quiver. 19 A careful reader might have noticed that we have not used explicitly the condition that the atom c is not contained in the crystal. This condition is needed because, had c been in the crystal, it would have contributed to the pole of the charge function Ψ Finally, for later convenience, let's summarize the action of the algebra on any colored crystal state |K : 19 One small caveat to our argument occurs when the atom d is on the surface of the crystal (n = 1 in our previous notation), such that we cannot findd . For example, the atom a in itself can be an origin o of the crystal. However, one can check that this is not possible in the crystal with c / ∈ |K as in (6.38).
action : subject to : where q (a) = 1, p (a) ≡ ϕ a⇒a (0) = ±1 and is related to the statistics of the operators e (a) (z) and f (a) (z). The ± signs in the coefficients of the e (a) (z) and f (a) (z) actions depend on both the initial state K and the atom a , and will only be fixed after we determine the statistics of the algebra.
The numerical constant C in the vacuum contribution to the charge function should be considered as a parameter that defines the quiver Yangian algebra. As we will see later, it enters the eigenvalues of the zero modes ψ (a) 0 on crystal state |K , together with charges {h I } on the quiver. In particular, when the quiver satisfies certain conditions under which the quiver Yangian has central terms, C is directly related to the (leading) central term. Since this discussion depends crucially on the quiver, in particular, whether the corresponding Calabi-Yau three-fold has compact 4-cycles, we will discuss the two classes in section 8 (without compact 4-cycles) and section 9 (with compact 4-cycles), respectively.

From Action on Colored Crystals to Relations of Quiver Yangian
In section 4, we summarized the relations of the quiver Yangian (see (4.9)) before deriving them. The goal of the current section is to derive the algebra (4.9) from its action on the set of colored crystals. We will show that, starting from our ansatz for the action of the algebra on the set of colored crystals |K given in (6.43), one can derive the relations (4.9) by demanding that the set of colored crystals |K furnishes a representation of the quiver Yangian.

ψ − ψ Relations
First of all, since any crystal state |K is an eigenstate of all ψ (a) (z) (see the first equation in (6.43)), we have Since this is true for any |K , we have as shown in the first equation in (4.9).

ψ − e and ψ − f Relations
To derive the ψ − e relation in (4.9), apply first e (b) (w) and then ψ (a) (z) on an arbitrary crystal state |K , and use the actions of ψ (a) (z) and e (b) (w) in (6.2): Reversing the order of ψ (a) (z) and e (b) (w), we have Now compare the coefficients in (6.46) and (6.47): for each final state |K + b , the ratio between the coefficient in (6.46) and the one in (6.47) is which can be written as ϕ b⇒a (z − w) in (6.46) and (6.47) since in both equations w → h( b ) for each final state |K + b , and for the ψ − e relation we only care about the singular terms ∼ w −m−1 with m ∈ Z ≥0 . Since this is true for any |K , we have as shown in the second equation of (4.9). Similarly, to derive the ψ − f relations, we consider 50) and compute the ratio between the two coefficients as as shown in the fourth equation of (4.9).

e − f Relations and Statistics of e and f Operators
Next, let us consider the e − f relation. This would also fix the bosonic/fermionic nature of the operators e (a) (z) and f (a) (z), namely, we will prove the relation (6.6).
To derive the e − f relation, consider applying on an arbitrary initial state |K , where ab is a shorthand for −(−1) |a||b| , which characterizes the (mutual) statistics of the operators e (a) (z) and f (b) (w) and will be determined (in terms of the self bond factor ϕ a⇒a ) shortly. First, on an arbitrary initial state |K , we have 54) and (6.55) Generically there are three scenarios 1. a = b, and the atom a removed by f (a) (w) coincides with the atom a added by e (a) (z).
2. a = b, the atom a removed by f (a) (w) is independent from the atom a added by e (a) (z).
3. a = b, which implies that the atom b removed by f (b) (w) is different from the atom a added by e (a) (z).

Scenario (1)
Let us first consider the scenario (1) and (2), in which a = b. Namely we consider the operator where the factor −(−1) |a| is to be fixed in terms of the self bond factor ϕ a⇒a (u). For the scenario (1), where the atom a removed by f (a) (w) coincides with the atom a added by e (a) (z), we have Consider the first equation in (6.57). For each atom a to be removed, the coefficient is and if we further demand we have which implies that the coefficient for the second equation of (6.57) is If further the statistics factor −(−1) |a| is related to the ϕ a⇒a (0) by we have (6.65)

Scenario (2)
For the scenario (2), i.e. when the atom a removed by f (a) (w) is independent from the atom a added by e (a) (z), we have 66) and (6.67) The ratio of the two coefficients, for the same final state |K + a − a , is 68) where we have used the reflection property of the bond factor (4.13) to reduce the square root factor to 1.
If we demand that this ratio is related to the statistics factor of a by (6.70) Since (6.70) is true for arbitrary |K , we have the relation of the operators: (6.71)

Statistics of Generators from Crystal
Before we proceed to the scenario (3)  For the operators e (a) (z) and f (a) (z), we have just seen that in order to have (6.71), we need the condition (6.63), namely where we have used the fact that ϕ a⇒a (0) = ±1. Since ϕ a⇒a (0) = (−1) #(self-loops of a) , we conclude that the e (a) (z) and f (a) (z) operators are bosonic (i.e. |a| = 0) when there are odd number of self-loops for the vertex a in the quiver, and fermionic (i.e. |a = 1|) otherwise. Since quivers in which vertices have 2n, with n ∈ N, number of self-loops do not seem exist for toric Calabi-Yau three-folds, this proves the grading rule (4.8).
In particular, for a vertex a that has no self-loop in the quiver, the corresponding e (a) (z) and f (a) (z) operators are fermionic. This is consistent with the intuition that when there is no self-loop for a, e (a) (z)e (a) (w)|∅ = 0, even when we choose the atom at the origin to have color a, signaling the fermionic nature of the creation operator e (a) (z) (and therefore for its corresponding annihilation operator). This is also consistent with the conclusion drawn from the vacuum characters of known examples.
Finally, by the condition (6.59), the constants p (a) and q (a) are also related to the statistics of e (a) (z) and f (a) (z) operators: We are free to set q (a) = 1, and have (6.6).

Scenario (3)
Now let us resume with the scenario (3), where a = b, and consider the generic situation where the addition of a and the removal of b are independent. The computation is similar to scenario (2), where the atom a removed by f (a) (w) is independent from the atom a added by e (a) (z). Compare the two processes (6.54) and (6.55). The ratio between the coefficients at the two sides (for the same final state) is 74) where again we have used the reflection property of the bond factor (4.13) to reduce the square root factor to 1.
for an arbitrary state |K , which gives Together with the result for a = b in (6.71), we have given in the last equation of (4.9).
Finally, we emphasize that to reach (6.78), we have demanded the function to satisfy various constraints, i.e. (6.60), (6.69), and (6.75). We will solve these constraints, together with two more coming from the e − e and f − f relations, after we fix the algebra.
79) and (6.80) Consider the generic situation 20 where the creation of the atom a by e (a) (z) and the creation of the atom b by e (b) (w) do not depend on each other. In such cases, the ratio between the coefficients in (6.79) and (6.80) is .
(6.81) The square root factor gives 82) where in the first step we have used the reflection property of the bond factor (4.13), and in the second step we have used the fact in (6.79) and (6.80), z → h( a ) and w → h( b ) and we only care about terms ∼ z −n−1 w −m−1 with n, m ∈ Z ≥0 . For each K, a , and b , the factors should be chosen such that Namely, the sign should be − when both e (a) and e (b) are fermions, and + otherwise. In summary we have as shown in the third equation in (4.9). Finally, a parallel derivation gives as shown in the fifth equation of (4.9). The constraint on needed for the f − f relation is

Prescription for Choice of
In deriving the algebraic relations (4.9) from the ansatz of the action (6.2), we have demanded the five conditions on the signs, namely (6.60), (6.69), (6.75), (6.83), and (6.86). Now we need to show that there always exists an assignment for such that this set of five equations hold.
First of all, these five equation are not all independent. First, the condition (6.69) is merely a specialization of (6.75). Second, since all = ±1, (6.60) can be rewritten into the reciprocity condition using which we can show that of the three equations (6.75), (6.83), and (6.86), only one is independent. For example, we can use (6.87) to reverse the directions of various processes in (6.75) and (6.86), thus bringing both of them into the form of (6.83), with the new initial state being |K − b for (6.75) and |K − a − b for (6.86). Therefore we only need to impose (6.87) and (6.83), the latter of which we repeat here: Given the reciprocity condition (6.87), we can simply assign the value of the function for each adding process K → K + a iteratively, starting from the vacuum K = ∅. The value for the function for a removing process is taken to be identical to the one for the corresponding adding process, due to (6.87). In this iterative assigning process, one only needs to observe (6.88), which is a condition that is associated to the "faces" of the adding diagram. But since we are starting from the atom at the origin and adding atoms according to a (two-dimensional) periodic quiver, the condition (6.88) is very easy to satisfy. For example, we can choose the for the first few processes to be +, and for the new adding processes switch the sign whenever demanded by (6.88), and since this is an iterative process, the sign assignment demanded by (6.88) is always pushed to the outskirt of the adding diagram, such that we are always free to assign to whatever value that satisfy (6.88). Thus we conclude that one can always fix a prescription of the function in the ansatz (6.2) such that by this action, the set of colored crystals furnishes a representation of the quiver Yangian algebra, whose algebraic relations are bootstrapped from the (6.2) and the quiver data.

Truncations of Quiver Yangians and D4-branes 7.1 Truncations of Quiver Yangians
The representation we constructed in the previous section is generically a cyclic module of the algebra, since we can arrive at any molten crystal configuration starting with the empty box (i.e. the vacuum) and applying a finite number of creation operators e (a) (u). Conversely starting from any molten crystal configuration we can arrive at the vacuum by appropriately applying a finite number of annihilation operators f (a) (u). This ensures that the representation is irreducible.
As explained in section 4.1, the algebra associated to the quiver (Q, W ) has |Q 1 | coordinate parameters {h I }, corresponding to the |Q 1 | edges of the quiver diagram. After the loop constraint (4.1) is imposed, they reduce to |Q 0 | + 1 = E + 2I − 1 independent parameters {h A }. In this section we will show that the representation can become reducible when the coordinate parameters {h I } (or more precisely {h A }) take certain fine-tuned values, causing the residue of the charge function Res u=h( a ) Ψ (a) K (u) in (6.43) to vanish for some atom a . In this case, it is impossible to add this atom (and hence all subsequent ones) to the crystal, and consequently this stops the growth of the crystal for the part beyond this atom. The representation is then no longer irreducible.
Since we have motivated the definition of the algebra Y (Q,W ) by its action on the crystal, it is natural to translate the truncation of the growth of the crystal into a truncation of the algebra. Namely, when the coordinate parameters take certain fine-tuned values, the algebra develops an ideal, quotienting out which gives the truncation of the algebra. The representation that is reducible with respect to the original algebra becomes irreducible in the truncated algebra. Now we will show that the special values for {h I } that characterize the truncation of the algebra are defined by certain linear equations with integer coefficients N . We denote the corresponding truncated algebra by Y N (Q,W ) . 21 Moreover we find that the (linear combination of) integers N corresponds to the number of D4-branes.
Suppose the growth of the crystal stops at an atom a of color a. Let us express its coordinate function as where N I ∈ Z 0 and n A ∈ Z; in the last step we have used the loop constraint (4.1) to reduce the parameters {h I } to the independent ones {h A }. Note that since the edges have fixed positions on the quiver, on each path from o to a , only certain h I appear. As a result, the non-negative integers N I do not take arbitrary values in Z ≥0 , and N A do not take arbitrary values in Z.
When we add this atom to the initial state K, the numerical coefficient is where in the last step we have extracted out the vacuum part of the charge function (Recall that we label the color of the atom at the origin of the crystal to be a = 1, and the vacuum only contributes to the charge function of color a = 1. ) Only the atoms on the surface of K contribute to the residue in (7.2). In particular, to add the atom a , we need to consider all the paths from the origin o to the atom a : for the atom a to be added, all the atoms right before the atom a in these paths need to be already present. However, none of the contributions from these penultimate atoms on the surface of K contain all the information of {N I }, since it is the difference between their coordinate functions and the coordinate function h( a ) in (7.1) that enters the residue (7.2). Instead, when a = 1, the contribution from the vacuum part of the charge function ψ 0 (u) contains all {N I }: where ∼ means that we only take into account of the numerator in ψ 0 (u) here.
The condition for the algebra to truncate at the level {N I }, i.e. for the growth of the crystal to stop beyond the atom a with a = 1 and at the position defined in (7.1), is that One can use these non-negative integers {N I } to label the truncation of the algebra. As we have already described, only |Q 0 | + 1 out of the |Q 1 | non-negative integers {N I } are independent. This is realized by the fact that, due to the loop constraint (4.1), the truncation condition (7.5) is invariant under the shift where L is any loop in the periodic quiver. We can use these shifts to obtain |Q 0 | + 1 non-negative integers, whose linear combinations map to the |Q 0 | + 1 integers N A .

Multiple Truncations and Rational Algebras
An important motivation to consider truncations of the algebra is to obtain "rational" versions of the algebra, namely the affine Yangian analogue of rational W algebras, which has only finitely many irreducible representations. The truncation condition (7.5) is one condition on the charge parameters h I , imposed by the fact that the growth of the crystal stops at one particular atom, labeled by {N I }. It is possible for the truncation of the growth of the crystal to happen at multiple locations, each characterized by integers {N i,I }, where i labels the different obstructing atoms. The truncation condition (7.5) is then enhanced to where T is the number of "obstructions".
Consider the simplest affine Yangian: the affine Yangian of gl 1 . Let us demand that the growth of the crystal, in this case the plane partition where all atoms have the same color a = 1, stops at an atom with position (x 1 , x 2 , x 3 ) = (N 1 , N 2 , N 3 ). Correspondingly the parameter {h i } with i = 1, 2, 3 must satisfy The first atom effectively truncates the plane partition along the x 3 direction with the x 3 = N plane, which ensures that no box can be added with x 3 ≥ N . The second atom acts as a "pit" on the x 1 − x 2 plane, at position (x 1 , x 2 ) = (k, k + 1), which means that no box can be added with x 1 ≥ k and x 2 ≥ k + 1.
Recall that the representation of the affine Yangian of gl 1 is labeled by the three Young diagrams (λ 1 , λ 2 , λ 3 ) as the asymptotic along the (x 1 , x 2 , x 3 ) directions. When both of these obstructing atoms are present, the three Young diagrams (λ 1 , λ 2 , λ 3 ) cannot take arbitrary values anymore. First of all, the presence of the cutoff along x 3 = N means there is no non-trivial asymptotic along the x 3 direction, namely λ 3 = ∅. Moreover, it also means that the heights of both λ 1 and λ 2 cannot exceed N . Lastly, the presence of the "pit" at (x 1 , x 2 ) = (k, k + 1) means that the width of λ 1 cannot exceed k and that of λ 2 cannot exceed k + 1. Therefore, there are only finitely many representations, suggesting that the corresponding algebra is rational.
One can check this by direct computation of the {h i } parameter of the affine Yangian of gl 1 . Solving the double truncation condition (7.8) with the {N i } taking the two triplets in (7.9), we get together with ψ 0 = N , (7.11) up to the scaling freedom (h i , ψ 0 ) → (α h i , α −2 ψ 0 ). 23 This is precisely the values of {h i } and ψ 0 obtained by a direct translation between the affine Yangian of gl 1 and the W N,k algebra in [25], where N, k are both positive integers (or one of the S 3 image of the "triality symmetry" of the W N,k algebra [52]). Note that to obtain a rational algebra, only the first condition in (7.9) is necessary: one can relax the second condition by choosing with m ∈ N. The coupled equation (7.8) whose second one having coefficient in the form (7.12) can be brought back to the one with coefficients in the forms of (7.9) but with k non-integer: This corresponds to a rational W N,k algebra with k no longer an integer, but a rational number of the form k+N m − N with N, k, m ∈ N. (Moreover, one can check that the (N, k ) pair from (7.13) is not an triality image from an integer pair (M, k). 24 ) These are precisely the admissible (non-integer) levels for the rational W N,k algebra when p ≡ N + k and p ≡ k + N + m are coprime [53]. 25 We have just obtained them by an easily-visualizable truncation of the affine Yangian of gl 1 .
This can be generalized to all affine Yangian algebras of this paper. Namely, for each affine Yangian algebra, one can study its multiple truncations and use them to obtain the "rational" version of the algebra, whose number of irreducible representations becomes finite. The procedure is actually easier than the one for the corresponding W algebra. The rational W algebras usually belong to a family of generically irrational W algebras; when the parameters of the family take specific values, enough null vectors arise and the algebra becomes rational. Locating such rational points requires an analysis of the null vector structure and needs to be done case by case for each family. In contrast, the truncations of the affine Yangian algebras follow a universal mechanism which is easy to visualize and to classify. One can use the truncation of the affine Yangian algebras to find new rational W algebras. 23 To compare with the literature, here we are using the mode expansion (5.2) adopted in [24,25], instead of (8.3), which is universal for all quiver Yangians of Calabi-Yau three-folds without compact 4-cycles. Had we adopted the convention (8.  24 The two generators of the S 3 symmetry (so-called "triality symmetry") are (N, k) → (N, −2N − k − 1) and (N, k) → ( N N +k , 1−N N +k ) [52]. 25 The map of the parameters (N, k, m) to those of the non-unitary W N (p, p ) minimal model (with gcd(p, p ) = 1) in [53] is p = N + k, p = k + N + m.

Relation with D4-branes
We now claim that these non-negative integers correspond to the number of D4 branes wrapping the 4-cycles (divisors) in the Calabi-Yau 3-fold. These 4-cycles can be either compact or non-compact. In short, adding D4-branes corresponds to truncating the algebra.
In order to see this, we first need to see the effect of the D4-branes to the supersymmetric quiver quantum mechanics (see [54,55] for discussions in the context of brane tilings 26 ). Let us first recall that in the absence of the D4-brane we have an effective D0-brane quantum mechanics. This D0-brane probes the geometry of the toric Calabi-Yau manifold, and hence the vacuum moduli space of the quiver quantum mechanics (when the gauge group is Abelian) reproduces the geometry of the toric Calabi-Yau manifold.
When the D4-brane wraps a non-compact 4-cycle we have a non-dynamical gauge symmetry on it, whereas for a compact 4-cycle a dynamical gauge symmetry appears. In either case, from the viewpoint of the D0-brane quantum mechanics the D4-brane looks like a flavor brane.
The divisors in question are regions of the (p, q) 5-brane webs. This is also in one-to-one correspondence with a lattice point of the toric diagram. Since we have denoted the number of external (internal) lattice points by E (I), we have E non-compact (I compact) D4-brane divisors.
When we include D4-branes, we need to include strings connecting D0-brane to the D4-brane, which gives a pair of the quark chiral multiplet q and the anti-quark chiral multipletq. They couple to one of the bifundamental fields Φ I of the D0-brane quiver quantum mechanics, with superpotential W =q Φ I q . (7.14) Which bifundamental field do we get? To answer this, it is useful to take Tduality twice, so that both the D0-brane and the D4-brane are turned into D2-branes [55]. We then have a brane configuration consisting of D2-brane and an NS5-brane (see [39] for a detailed analysis), which gives a physical realization of the brane tilings and the periodic quiver.
Let us consider the situation where the flavor D4-brane (which is now a flavor D2brane) is associated with a non-compact region corresponding to the corner external vertex of the toric diagram. One then finds that the D2-brane in the D2/NS5 brane configuration is sandwiched between two asymptotic NS5-brane cylinders, which are related by string duality to two asymptotic lines of (p, q)-webs surrounding D4-brane 26 Since we are discussing quiver quantum mechanics and not four-dimensional quiver gauge theories, we need to dimensionally-reduce the setup. For example, a D3-brane probing the toric Calabi-Yau manifold is turned into a D0-brane probe in our context. region. The string at the intersection of the two NS5-branes gives rise to a bifundamental chiral multiplet, which can be identified with the bifundamental field Φ I in question.
When we include the D4-brane, the bifundamental chiral multiplet Φ I will in general have a VEV (Vacuum Expectation Value), and this gives masses to the quarks. This means that the probe D0-brane and the flavor D4-brane are separate. In order to identify the D4-brane divisor, one therefore needs to probe the locus where the VEV of the chiral multiplet vanishes: Φ I = 0. Since we have one complex equation, we could expect a divisor.
While Φ I = 0 is a legitimate equation, one needs to remember that we need to take into account the F-term relations arising from the derivatives of the superpotential. One systematic approach is to solve the F-term equations first, and then impose the condition Φ I = 0. This process is helped greatly by the fact that the F-term equations can be solved by a set of fieldsΦ p associated with perfect matchings p of the dimer model [36]. Here a perfect matching refers to a subset of the edges of the bipartite graph such that any vertex of the bipartite graph is contained in exactly one edge (see Figure 10). Since the periodic quiver is the dual of the bipartite graph, this means a perfect matching can be regarded as a subset of Q 1 , the set of arrows of the quiver. The relation between Φ I andΦ I can now be stated as This means that the divisor {Φ I = 0} can now be regarded as the the union of the submanifolds {Φ p = 0}. Now, for each perfect matching we can associate a lattice point of the toric diagram (in general this can either be on the boundary or inside of the toric diagram), see Figure 10 for an example. This is determined by the so-called height function introduced in the dimer model literature -one chooses one of the perfect matchings as a reference matching, and when this is superimposed with another perfect matching we have a set of closed paths on the torus. The total winding numbers of the resulting paths, labeled by two integers corresponding to winding in α and β cycles of the two-dimensional torus, determine the corresponding lattice point of the toric diagram. (One can show that the resulting toric diagram is independent of the choice of the reference perfect matching, up to a GL(2, Z)-transformation on the toric diagram.) In general multiple perfect matchings can be associated with the same lattice point. In this paper we consider the case of D4-branes associated with a corner lattice point of the toric diagram. In this case, it is known that there is a unique perfect matching p corresponding to the lattice point (cf. [31]), and one can show [55,Theorem 2] that the D4-brane divisor can be identified with the locus {Φ p = 0} associated with that perfect matching p. In this locus {Φ p = 0}, we set all the Figure 10. The perfect matchings for the Suspended Pinched Point geometry of Figure  1, whose bipartite graph was shown in Figure 3. There are six perfect matchings, each of which is associated with one of the five lattice points of the toric diagram (with multiplicity two for the lattice point (1, 0)); this association is determined by the height function, as explained in the main text.
bifundamental fields belonging to the perfect matching to zero. Such a truncation for the BPS crystal melting model was discussed previously in [56] (see also [57,58]).
For the present purpose of identifying the number of D4-branes, when we consider a D4-brane wrapping the divisor {Φ p = 0}, we impose the condition h I = 0 when I ∈ p . (7.16) This leaves a restricted set of parameters, which we regard as the parameter space needed for the truncation with D4-branes. Since we consider divisors associated with perfect matchings for the corner lattice points of the toric diagram, this will be specified by I corner , the number of such lattice points. This should be compared with the set of |Q 0 | + 1 = I + 2E − 1 integers N A associated with truncations of the algebra. Note, however, not all the possible sets of integers N A are realized in the quiver diagram, and hence the actual possible truncations are much more limited. We will discuss many examples in section 8 and section 9, and find that the truncations of the algebra are always labelled by a set of two integers, at least for all the examples studied in this paper. This is actually smaller than the number I corner of independent D4-brane charges associated with corner perfect matchings. Moreover, we in general have many more complex submanifolds described by non-corner perfect matchings. This suggests that there exist more general representations of the quiver Yangians than studied in this paper. We leave a detailed discussion of these subtleties for future work.

Examples: Calabi-Yau Manifolds without Compact 4-cycles
In the next two sections we apply the algorithm outlined in section 4 on various toric Calabi-Yau three-folds. For each example, we will construct explicitly its associated algebra, and define its truncations. For some examples, we will also discuss special points in the parameter space where our algebra reduces to known affine Yangian algebras.
This section deals with toric Calabi-Yau three-folds without compact 4-cycles and section 9 will study those with compact 4-cycles.

Mode Expansion
For Calabi-Yau three-folds without compact 4-cycles, the corresponding quiver has the property that the number of arrows from a to b is the same as the number of arrows from b to a: |a → b| = |b → a| .
As a result, the bond factor ϕ a⇒b (u), defined in (4.11), become homogeneous rational functions. Therefore the eigenvalue of the charge function Ψ (a) K (u), which is a product of all ϕ b⇒a (u − h( b )) together with the possible vacuum contribution (see definition (6.9)) for any crystal state K, is also a homogeneous rational function, which has the expansion Ψ (a) Since the expansion (8.2) is true for any K and a, the operator ψ (a) (u) has the same expansion. Namely, for Calabi-Yau three-folds without compact 4-cycles, the general mode expansion (4.7) specializes to Accordingly, in the algebraic relations in terms of modes (4.20), the ψ for all a.

Initial Conditions
As explained just now, for Calabi-Yau three-folds without compact 4-cycles, the mode relations (4.20) are all from terms of order z −n−1 w −m−1 , with n, m ∈ Z ≥0 , in the corresponding OPE relation (4.9). In particular, for the ψe and ψf relations, the mode relations are from terms of order z −n−1 w −m−1 , with n, m ∈ Z ≥0 . One can also supplement these ψe and ψf relations with "initial conditions" that come from terms of order z −1 w −m−1 with = 1, . . . , |a → b| and m ∈ Z ≥0 . Note that these additional initial conditions are allowed by the algebraic relations (4.9) with the mode expansions (8.3), and is consistent with the algebra's action (6.43) on colored crystals K. For Calabi-Yau three-folds without compact 4-cycles, these initial conditions contain the finite part of the affine Yangian. One can derive from these initial conditions the central elements of the algebra.
Let us again take the ψ (a) e (b) OPE for example. Plugging the mode expansions of ψ (a) (z) and e (b) (w) from (8.3) into (4.17) and extracting the terms of order z −1 w −m−1 with = 1, . . . , |a → b| and m ∈ Z 0 , and using (8.4), we have the mode relation: where we have assumed ψ (a) where we have used ψ (a) −1 = 1. Next, for |a → b| = |b → a| ≥ 2, consider = |a → b| − 1, which gives The initial conditions with ψ (a) ≥2 , if exist, can be derived similarly from the general formulae (8.5) and (8.6). Since details of these initial conditions depend on the quiver data {a → b}, we will discuss them further when we consider concrete examples.

Central Element of the Algebra
From the initial condition, one can construct various central terms (if exist) of the algebra. For a given vertex b, define where the sum in the last term runs over all charges both incoming and outgoing (without signs) from the vertex b. The combination If the following condition is satisfied: central condition : for ∀ a , (8.12) then the combination (8.10) is a central term of the algebra. (Note the difference between the vertex constraint (4.30) and the central condition (8.12)). For the Calabi-Yau three-folds without compact 4-cycles, this condition is always guaranteed by the loop constraint (4.1). The central term ψ 0 defined in (8.10) is thus the universal central term in the quiver Yangians for all the Calabi-Yau three-folds without compact 4-cycles. There could be other central terms, depending on specifics of each quiver diagram. We will define these additional central terms when we consider specific examples later. We can now expand this charge function to obtain its charges ψ (a) n using the expansion (4.7). In particular, we are interested in the leading charge ψ Summing (8.14) over all atoms a, and recalling the definition of the generic central term in (8.10) and that of Σ a in (8.9), we have Now we can impose the central condition Σ 1 = 0 (8.12), which has two consequences for (8.15). First, ψ 0 is central, due to (8.11). Second, It is also straightforward to check that one can obtain (8.16) if we start with an arbitrary state |K . The analogue of (8.15) for an arbitrary crystal state |K is where each atom a in the crystal |K contributes a term Σ a , where a is the color of the atom a . Due to the the central condition (8.12), all Σ a = 0, and we have (8.16) for any |K . The identification (8.16) is a natural generalization of the gl 1 case (3.20).

Quiver Yangians for (C 2 /Z n ) × C and Affine Yangian of gl n
We start with the toric Calabi-Yau manifold (C 2 /Z n ) × C. The quiver algebra has n + 1 parameters. If we impose the n − 1 vertex constraints (4.30), we can reduce the number of parameters to 2, which are the two coordinate parameters. We find that the reduced quiver Yangian in this sub-parameter space is the affine Yangian of gl n constructed in [59,60], which are rational limits of quantum toroidal algebra of gl n constructed in [61] (see also [62]). Let us study the cases of n = 1, n = 2, and n ≥ 3 in turn. Its associated quiver diagram is where we have labelled the three adjoints X 1,2,3 , together with their three charges h 1,2,3 . The super-potential is Since in the quiver the vertex 1 has a self-loop, it is bosonic: |1| = 0. The periodic quiver is Figure 11. Two ways to draw the periodic quiver for C 3 . The left one emphasizes its connection to the projection of the plane partitions and the triality symmetry of the three directions, whereas the right one is for later comparison with the periodic quiver for (C 2 /Z n ) × C and generalized conifolds.
The loop constraint (4.1) gives Therefore we have two coordinate parameters, corresponding to the two equivariant parameters ( 1 , 2 ). Note that the central condition (8.12) is guaranteed by the loop constraint (8.22).

Affine Yangian of gl 1
Note that in this case the vertex constraint (4.30) also gives (8.22). Therefore the minimal number of parameters we can have is two, corresponding to the U (1) 2 toric isometries. There is only one bond factor: Plugging this into the general formulae for the OPE relations (4.9) and the initial conditions (8.5) and (8.6), and supplementing them with Serre relations, we have the full list of algebra relations of the affine Yangian of gl 1 : OPE: It is straightforward to write down the relation in terms of modes, following (4.20).
In the ef relation in (8.24), note its difference from (5.38) in the factor of 1 σ 3 . This is due to the different convention in our mode expansion of ψ(u) in (8.3)which is the universal for all quiver Yangian of Calabi-Yau three-folds without 4-cycle -from the one (3.5) in the literature. (This difference also manifests itself in the two initial conditions involving ψ 2 .) In the derivation of the initial conditions (8.25), we have used |a → a| = 3, and setting = 3, 2, 1 in the general formulae (8.5) and (8.6) gives the initial conditions involving ψ 0,1,2 , respectively, and we have also used σ 1 ≡ h 1 + h 2 + h 3 = 0. We see that there are two central terms, ψ 0 and ψ 1 . Finally, note that we have rewritten the Serre relations, bringing them to a form more similar to the general gl n case.

Truncation
For the affine Yangian of gl 1 , the vacuum charge C is identical to the leading central term ψ 0 . Applying the general truncation condition (7.5) on the quiver (8.21), we have the truncation condition which is invariant under the shift due to the loop constraint (8.22). There are three non-compact divisors where the D4-branes wrap, which are related by the permutation (S 3 ) symmetry. These correspond to the three perfect matchings of the dimer model (see Figure 13), each of which corresponds to one of the triple {h 1 , h 2 , h 3 }, thus giving rise to the same condition (8.27). This means that the N i 's can indeed be regarded as the number of D4-branes in that region. We therefore obtain the algebra Y N 1 ,N 2 ,N 3

(Q,W )
. The latter was studied previously in [48,50,63,64]. Note that due to the loop constraint (8.22) one can simultaneously shift all the N i 's by the same amount, hence leaving two non-negative integers. Figure 12. The bipartite graph and its dual, the periodic quiver, for the C 3 geometry. Figure 13. The three perfect matchings for the C 3 geometry. Each of these perfect matchings correspond to one of the non-compact regions of the (p, q)-web, and to one of the parameters h 1 , h 2 , h 3 . Its associated quiver diagram is the A 2 -quiver

(C
with super-potential Both vertices are bosonic: since there is a self-loop for each of them in the quiver (8.30). The periodic quiver is shown in Figure 14, drawn in two slightly different ways. Comparing the left one to the left drawing in Figure 11, one can see the representation of the algebra for (C 2 /Z 2 )×C can be realized by coloring plane partitions accordingly -the color alternates between 1 and 2 as one moves along the x 1 or x 2 directions, but remains unchanged along the x 3 direction. The right drawing in Figure 11 is for later comparison with the conifold and (C 2 /Z n ) × C.
Again, applying the loop constraint (4.1) gives the constraints on the charges: Namely, there are only three independent parameters for the algebra for C 2 /Z 2 ×C. Again, the central condition (8.12) is guaranteed by the loop constraint (8.33).  Figure 14. Two ways to draw the periodic quiver (C 2 /Z 2 ) × C. The left one shows that the representation can be realized by coloring the plane partitions, whereas the right one is for later comparison with the periodic quiver for the conifold and (C 2 /Z n ) × C. For clarity we have shown several copies of the fundamental region of the two-dimensional torus; one choice of the fundamental region is shown as a shaded region.
One can immediately read off the bond factors from the periodic quiver shown in Figure 14 by the definition (4.11) where the indices are understood as mod 2. The resulting algebra is OPE: The initial conditions can be computed using the general formula (8.5). For a = b, only the equation with = 2 is non-empty, giving the initial condition on [ψ Initial: 0 is the central term.

Truncation
To study the truncation of the algebra, consider a path from the origin o (on which the atom has color a = 1) to another atom 1 with the same color, at which the growth of the crystal stops. The coordinate function of the second atom can be written as Here N γ counts the number of self-loops at the vertices 1 and 2 (recall γ 1 = γ 2 = γ), and N 1,2,3,4 counts the number of loops 1 → 2 → 1; since there are two choices of arrows for both 1 → 2 and 2 → 1, one obtains 2 2 = 4 different choices.
We still need to fully take into account the loop constraints (8.33). Eliminating β 1 and β 2 , one obtains the truncation condition to be We find that the truncation is described by a set of two integers, namely the two coefficients in front of γ and α 1 + α 2 , respectively. We can compare this with the expectation from the perfect matchings. The bipartite graph is shown in Figure 15, and leads to five perfect matchings as shown in Figure 16. They correspond to five different combinations of parameters Of these five, only the first three correspond to the corner lattice points of the toric diagram: and these span almost the same combinations as in (8.37) above, except that the D4-branes give even integer coefficients in front of γ. Figure 15. The bipartite graph for the (C 2 /Z 2 ) × C geometry. Figure 16. The perfect matchings for the (C 2 /Z 2 ) × C geometry. There are five perfect matchings, corresponding to the combination of parameters α 1 + α 2 , β 1 + β 2 , γ 1 + γ 2 , α 1 + β 2 , α 2 + β 1 .

Affine Yangian of gl 2
In addition to the loop constraint (8.33), we can also impose the vertex constraint (4.30), which in this case give The loop constraint (8.33) and the vertex constraint (8.41) together give and Namely, after imposing the vertex constraints on top of the loop constraint, we have two parameters (h 1 , h 2 ), same as in the case of the affine Yangian of gl 1 for C 3 .
Restricting the parameters to (8.42), the bond factors (8.34) become: with super potential We see that all vertices are bosonic: since there is a self-loop for each of them in the quiver. The periodic quiver for (8.47) is given in Figure 17, where we have shown only the part of the graph around the vertex 1; the full graph is obtained by periodically extending the graph. Comparing the left drawing in Figure 17 with the left one in Figure 11 (i.e. the periodic quiver that gives the affine Yangian of gl 1 ), we see the representation of the algebra for (C 2 /Z n ) × C can be obtained by coloring the plane partitions by the following rules: the box at the origin has color 1; the color increases by 1 as one moves by one step along the positive x 1 direction, decreases by 1 by each step along the positive x 2 direction, and remains the same along the x 3 direction.  Figure 17. Two ways to draw the periodic quiver (C 2 /Z n ) × C. The left one shows that the representation can be realized by coloring the plane partitions, whereas the right one is for later comparison with the periodic quiver for the generalized conifolds. Note that this shows only part of the periodic quiver diagram around the vertex 1.
One can immediately read off the bond factors from the periodic quiver in Figure 17 by the definition (4.11) where the indices are understood as mod n.
The bond factors (8.53) give the algebra OPE: where in the computation of the initial conditions, only equations with = 1 in the general formula (8.5) is non-empty, since all the bond factors are of order 1. As a result, we only have initial conditions on [ψ

Truncation
For the truncation, consider a path from the origin o to an atom 1 of color a = 1, at which the growth of the crystal stops. The coordinate function of this atom 1 is 56) where N γa denotes the number of edges with γ a in the path, N a the number of segment a → a + 1 → a, N α the number of the segment 1 → 2 → · · · → n → 1, N β the number of segment 1 → n → · · · → 2 → 1. Using the loop constraint (8.51) and (8.52), the coordinate function can be rewritten as Therefore the algebra truncates when the parameter {α a , γ} satisfy namely the truncation can be characterized by the two integer coefficients multiplying γ and ( n a=1 α a ). We can compare this result with expectations from perfect matchings. While the number of perfect matchings grows quickly as n increases, one can draw the bipartite graphs and perfect matchings (as in Figures 15 and 16 for n = 2), and one finds that perfect matchings generators linear combinations of the form nγ , α 1 β 1 + · · · + α n β n , (8.59) where in the second term we choose either α i or β i for each i = 1, . . . , n. Out of these combinations only three correspond to lattice points in the corner of the toric diagram (which in this case is a triangle): nγ , α 1 + · · · + α n , β 1 + · · · + β n = nγ − (α 1 + · · · + α n ) . (8.60) The span of the three again gives rise to integer span of nγ and n a=1 α a . This almost matches the result above, except that the coefficient for γ is a multiplet of n, as in the case of n = 2 before.

Affine Yangian of gl n
If in addition to the loop constraint (8.52), we impose the vertex constraint (4.30), which in this case give for a = 1, 2, · · · , n , which together with the loop constraint (8.52) give and With the restriction of the n + 1 parameters to the two parameters (h 1 , h 2 ), the bond factors in (8.53) become which gives the algebra OPE: Initial:

Quiver Yangian for Generalized Conifolds and Affine Yangian of gl m|n
Let us next discuss the toric Calabi-Yau geometries described by the algebraic equation where x, y, z, w are complex numbers and m, n are non-negative integers (excluding m = n = 0). We can assume m ≥ n without losing generality. The geometry (8.67) is sometimes called the generalized conifold, and is the most general toric Calabi-Yau geometry without compact 4-cycles (mathematically, such toric Calabi-Yau singularities are known to have small resolutions). The geometry contains all the geometries discussed above: the case of m = n = 1 is the conifold, and the case of n = 0 are the A m singularities (C 2 /Z m ) × C (which includes C 3 as the special case m = 1, n = 0). The toric diagram, up to a suitable SL(2, Z)transformation, can be chosen as in Figure 18.

Quivers and Superpotentials
When discussing BPS crystals it is important to note that there are several different quiver gauge theories corresponding to the same geometry (8.67); their quiver diagrams are different but they all have the same moduli space of vacua, and the module categories of their associated path algebras are derived-equivalent.
Geometrically, such ambiguities arise from the choice of the resolution of the singularity (8.67). This is described by a choice of the triangulation of the toric diagram, and any two such choices are related by a sequence of flop transitions. Combinatorially, this choice is encoded by a set of signs σ, which has m +1's and n −1's [11,15] (see Figure 19): For our later purposes we can regard the domain periodically as Z m+n , so that σ is a map from Z m+n to {+1, −1}.
Given these data, we can identify the quiver diagram as follows [11]: • We have m + n vertices a = 1, . . . , m + n.
• For each vertex a we have an arrow from a to a + 1, and another from a + 1 to a (the quiver is therefore non-chiral).
• We have an arrow starting and ending at the same vertex a when σ a = σ a+1 ; otherwise we do not have such an arrow. From the grading rule (4.8) one finds that in the former case the vertex a is an even vertex (|a| = 0), where in the latter case an odd vertex (|a| = 1).
• There are no arrows from vertex a to b when |a − b| ≥ 2, where a and b are considered mod m + n.
Here the indices a, b, . . . are regarded as an element of Z m+n . Let us describe the superpotential W . For each vertex a, we add superpotential terms W Tr(Φ a,a Φ a,a+1 Φ a+1,a ) − Tr(Φ a,a Φ a,a−1 Φ a−1,a ) (σ a = σ a+1 ) , where as before Φ a,b denotes the bifundamental chiral multiplet corresponding to the arrow from a vertex a to a vertex b. Figure 20. The quiver diagram around a vertex a. Depending on whether we have σ a = σ a+1 or σ a = −σ a+1 we require superpotential terms as in (8.69).

Periodic Quivers and Dimers
The quiver and the superpotential described above are sufficient for the discussion of the BPS quiver Yangian. Let us nevertheless describe the periodic quiver [11], which will be needed for the explicit construction of the BPS crystal melting, as well as for the discussion of the truncation of the algebra later in section 8.3.4. Instead of directly writing down the periodic quiver, it is useful to discuss its dual graph, which is a bipartite graph known as the brane tiling.
Let us again start with a choice of the signs σ. We consider m + n stacks of fundamental building blocks as shown in Figure 22, either hexagons or squares (with length of each edge 1). For a ∈ Z m+n one consider hexagons (squares) when σ a+1 = σ a (σ a+1 = −σ a ). One then chooses a fundamental region such that the parallelogram representing the fundamental region is shifted by m − n units. The examples of m = 3, n = 2 are shown in Figure 23. We can then choose a fundamental region as in Figure 23. Figure 22. The building blocks for the bipartite graphs for the generalized conifold geometry. For a ∈ Z m+n one stacks the hexagons as above (squares as below) when σ a+1 = σ a (σ a+1 = −σ a ). The dual graph of the bipartite graph gives the periodic quiver, which in turn gives the quiver and the superpotential. For the examples of Figure 23, they are shown as in Figure 24.

Algebra
We can now write down the algebra.
In order to write down the OPE relations one first needs to know the Bose/Fermi statistics of the generators. From the rules of the quiver diagrams above, the presence/absence of the arrows starting and ending on the same vertex a depends on the relative sign of σ a and σ a+1 -it then follows from the grading rule of (4.8) that the generators e (a) (z), f (a) (z), ψ (a) (z) are bosonic (even) when σ a = σ a+1 , and fermionic (odd) when σ a = −σ a+1 . The OPE relations are then determined by the function , (8.73) which gives for example Since we already considered the case of m + n ≤ 2 (C 3 (m = 1, n = 0), the conifold (m = n = 1) and C 2 /Z 2 × C (m = 2, n = 0)), let us concentrate on the general case m + n ≥ 3. In this case, for any pair of vertices a, b there is at most one arrow in the quiver from vertex a to vertex b (this is the case even for the cases with a = b): and all other ϕ a⇒b trivial. Now it is straightforward to write down the algebra OPE: together with the initial conditions Initial: from which one can check that the combination ψ 0 ≡ m+n a=1 ψ (a) 0 is a central term.

Truncation
The truncation condition for the algebra for the generalized conifold can be derived in a similar way to the one for the algebra of (C 2 /Z n ) × C, given in (8.58). Consider a path from the origin o to an atom 1 of color a = 1, at which the growth of the crystal stops. The coordinate function of this atom 1 is 78) where N γa denotes the number of edges with γ a in the path, N a the number of segment a → a + 1 → a, N α the number of the segment 1 → 2 → · · · → m + n → 1, N β the number of segment 1 → m + n → · · · → 2 → 1. This is identical to the coordinate function of the truncation atom 1 for (C 2 /Z n ) × C (see (8.56)).
The difference from the case of (C 2 /Z n ) × C enters through the loop constraints (8.72) (cf. (8.51) and (8.52) for (C 2 /Z n )×C). Imposing (8.72) reduces the coordinate function (8.78) to Therefore the algebra truncates when the parameters {α a , γ} satisfy with α a , β a and γ obeying α a + β a + σ a+1 γ = 0. Now we can give the charge assignment in the presence of both loop and vertex constraints. First, define γ ≡ h 3 . Then without loss of generality, we can define, for an arbitrary vertex a, Then applying the constraints (8.85) iteratively starting from vertex a, we have the general rule for the charge assignment with the vertex constraint (see Figure 25): • The arrow in the clockwise direction (vertex a to vertex a + 1) has a weight α a = σ a+1 h 1 or σ a+1 h 2 , where the choice of h 1 versus h 2 flips whenever we cross the odd quiver vertex a.
• Similarly, the arrow in the clockwise direction (vertex a + 1 to vertex a) has a weight β a = σ a+1 h 1 or σ a+1 h 2 , where again the choice of h 1 versus h 2 flips whenever we cross the odd quiver vertex a.
• When σ a = σ a+1 we have an arrow starting and ending at the vertex a, to which we assign a charge σ a h 3 .
a a + 1 a − 1 Given the charge assignment, and the fact that the exchange of h 1 , h 2 and the simultaneous flip of the orientation of all the arrows preserve the weights of the quiver, we can write the bond factor (8.75) ϕ a⇒b (u) as where Q + and Q − are matrices such that (Q + ) a,a = (Q − ) a,a for all vertices a.
The explicit expression for Q + and Q − are (recall the charge assignments in Figure 25 as well as the relation h 1 + h 2 + h 3 = 0): It turns out that the algebra defined from the function ϕ a⇒b coincides with the relations of the affine Yangian of gl m|n , up to Serre relations which we come to momentarily. This is slightly easier if we define a symmetric matrix A and an anti-symmetric matrix M by We can then write This coincides with the same function for the affine Yangian for the Lie superalgebra gl m|n , which in turn arises from the rational reduction of the quantum toroidal gl m|n algebra constructed recently in [65,66] 27 (which generalizes the case of quantum toroidal gl n constructed earlier in [62]). In particular, the symmetric matrix A is nothing but the Dynkin diagram for the Lie superalgebra gl m|n . In this language, different choices of the signs σ are interpreted as different choices of the simple roots and of the Dynkin diagram for the Lie superalgebra gl m|n . (It is known that the choice of the Dynkin diagram is not unique, see e.g. [67] for review of Lie superalgebras). The ambiguity of the quiver gauge theory, which as we have seen corresponds to the ambiguity in the choice of the resolution of the toric diagram, now is identified precisely with the ambiguity of the Dynkin diagram of the Lie superalgebra. Moreover the boson/fermion statistics of the generators as we derived from the quiver diagram coincides with the even/odd nature of the Lie superalgebra generators. The quantum toroidal algebra in principle depends on the choice of the sign σ, however it has recently been shown that algebras with different choices of the signs are related by toroidal braid groups [66]. This is the mathematical manifestation of the physical statement that different quiver gauge theories describe the same geometry. 28 Note that for the identification for the affine Lie superalgebra, it is crucial that both our quiver and the superpotential are invariant under a cyclic permutation of the signs σ. This existence of the affine Weyl group symmetry was noticed before, and also appears in the chamber structure of the Kähler moduli space when we consider BPS wall crossing phenomena [11,15].

OPE:
Initial: relation will likely require a non-trivial change of the generators of the algebra (see [68] for a related discussion). It is also the case that the BPS state counting in [51] is in a particular chamber of the Kähler moduli space. Our discussion by contrast applies to general chambers, which are known to have crystal-melting description. to be compared with the case of (C 2 /Z n )×C shown in (8.30), where both vertices are bosonic, i.e. |a| = 0.
The periodic quiver is shown in the left picture of where the fundamental regions of the torus are shown as shaded regions. Note its relation to the one for the orbifold (C 2 /Z 2 )×C, shown in (the right picture in) Figure 14. Starting from the right picture in Figure 14, if one removes all the diagonal arrows, which correspond to the self-arrows in the quiver, and further flip the directions of arrows as one passes each vertex as one moves along either x 1 or x 2 direction, one then obtains the periodic quiver shown in (8.101). As we will see later, this is a general pattern relating the periodic quivers for the orbifold (C 2 /Z n )×C and the generalized conifold with the same rank, resulting in the relation between affine Yangians of gl m+n and gl m|n .
The loop constraint (4.1) translates to Again, the central condition (8.12) is guaranteed by the loop constraint (8.102). One can then immediately read off the bond factors from the periodic quiver (8.101) by the definition (4.11) where the indices are understood as mod 2 and the four charges (α 1,2 , β 1,2 ) satisfy (8.102). Accordingly, the resulting algebra is From the initial conditions one can check that the combination ψ 0 ≡ ψ (1) 0 + ψ (2) 0 is indeed a central term.

Truncation
Consider the path from the origin to an atom 1 of color 1, at which the growth of the crystal stops. The coordinate function of 1 is a special case of (8.78), with γ a = 0: where N a is the number of segments 1 → 2 → 1 with charge α a and then β a , etc. Imposing the loop constraints (8.102) gives the truncation condition: namely the truncation can be characterized by the two integer coefficients multiplying (α 1 + β 1 ) and (α 1 + α 2 ). One can compare this result with the expectation from D4-branes. Starting with the bipartite graph in Figure 27, one obtains that the four perfect matchings (shown in Figure 28) give the linear combinations α 1 , α 2 , β 1 , β 2 = −(α 1 + α 2 + β 1 ) . (8.108) One might therefore conclude that we obtain linear combination of the first three elements with non-negative integer coefficient. This is more general than the previous result (8.106), which suggests that there should be more general representations than those in this paper. Figure 27. The bipartite graph for the conifold geometry.

Affine Yangian of gl 1|1
For the periodic quiver (8.101), the vertex constraint (4.30) translates to Together with the loop constraint (8.102), it reduces the four parameters (α 1,2 , β 1,2 ) to two independent parameters We have drawn the period quiver with both loop and vertex constraints imposed in the right figure of (8.101). With both the loop and vertex constraints imposed, the bond factor (8.103) becomes data of the superpotential.

Suspended Pinched Point and Affine Yangian of gl 2|1
Let us close this subsection with another special case of m = 2, n = 1. This is the Suspended Pinched Point geometry discussed in section 2. With both the loop constraints and the vertex constraint imposed, the corresponding algebra is the affine Yangian of gl 2|1 . The quiver diagram for SPP is where in the left one the charges are before any constraints are imposed; whereas in the right one, we have imposed both the loop constraints and the vertex constraint The solutions to the two sets of constraints are denoted by the three parameters (h 1 , h 2 , h 3 ) satisfying h 1 + h 2 + h 3 = 0. The corresponding periodic quivers are with the fundamental regions of the torus shown as shaded regions. (In these figures the fundamental regions are split into two to save space in this figure; in each case the understanding is that the trapezoids are meant to be glued together along edges with labels α 2 and −h 2 to obtain a parallelogram.) The vertex 1 is even while the vertices 2 and 3 are odd: The algebra before the vertex constraints (8.117) are imposed is given by where a = 1, 2, 3, and the β a is fixed in terms of α a and γ by the loop constraints (8.116). The algebra relations and the initial conditions for the SPP geometry can then be obtained by plugging the choice (σ 1 , σ 2 , σ 3 ) = (+, +, −) and the bond factors (8.120) into the general formulae (8.76) and (8.77).

Truncation
The truncation condition can be obtained by taking the general formula (8.80) and plugging in (σ 1 , σ 2 , σ 3 ) = (+, +, −). This gives namely the truncation can be characterized by the two integer coefficients multiplying γ and (α 1 + α 2 + α 3 ). Let us re-derive this result from perfect matchings. We have already shown the bipartite graph and the perfect matchings in Figures 3 and 10. Now we reproduce them in slightly different-looking (albeit equivalent) forms in Figures 29 and 30, to make the comparison with the quiver in (8.118) easier.
There are six perfect matchings as show in Figure 30, giving rise to linear combinations When we impose the vertex constraints, these reduce to From this we find that only the first four perfect matchings are corner perfect matchings: which by a change of basis can be replaced by This is (as in the conifold example) more general than the expectations from the representation theory. The bond factors are (8.128) Figure 30. The 6 perfect matchings for the Suspended Pinched Point geometry. They correspond to the combinations β 2 + γ, α 2 + γ, α 1 + α 3 , β 1 + β 3 , α 1 + β 3 , α 3 + β 2 .

Examples: Calabi-Yau Manifolds with Compact 4-Cycles
In the previous section we have restricted ourselves to the toric Calabi-Yau threefolds without compact 4-cycles. Our discussion of the BPS quiver Yangian, however, works for an arbitrary toric Calabi-Yau geometry, most of which have compact fourcycles and goes beyond the examples discussed in the previous section. This is in contrast with other existing approaches in the literature, where there seems to be technical problems associated with such generalizations. We will discuss in detail examples of the canonical bundles overs P 1 × P 1 and P 2 in the next subsections.
9.1 Quiver Yangians for K P 2

Quiver
Let us consider the geometry K P 2 , the canonical bundle over P 2 . The geometry coincides with C 3 /Z 3 , where the action of Z 3 is (z 1 , z 2 , z 3 ) → (ωz 1 , ωz 2 , ωz 3 ) with ω 3 = 1. Its toric diagram and its dual graph are (0,0) Note that this is different from the (C 2 /Z 3 ) × C geometry discussed in section 8.2.3. The quiver diagram is the McKay quiver [69] for the Z 3 -action with the superpotential with the totally antisymmetric tensor ε ijk . The loop constraint (4.1) from the superpotential is
For the state with the first atom 1 and one atom 2 (at the direction i, with i = 1, 2, 3) at the level-2: (9.12) One can thus proceed iteratively, and write down the charge function Ψ K (u) corresponds to the position of either an atom a (of color a) that can be added to K or an atom a that can be removed from K. Since the ϕ a⇒b (u) in (9.9) is not homogeneous, generically the charge functions Ψ (a) K (u) is also not homogeneous.

Truncation
Let us consider the truncation induced by the truncation of the crystal at an atom of color 1. The path starting and ending at the same vertex 1 goes around the loop of the quiver diagram. Each loop has the total weight of the form α where i, j, k runs separately from 1 to 3. Using the loop constraints (9.5) and (9.6), this is computed to be h i + h j + h k . This means that the coordinate function at the location of the truncation takes the form (9.14) Since h 1 + h 2 + h 3 = 0, we have integer linear combination of h 1 and h 2 , so that we have a truncation condition We can check this result from the perfect matching prescription introduced earlier, as worked out in Figures 31 and 32. There are six perfect matchings as shown in Figure 32, corresponding to the linear combinations  When we further impose the vertex constraints, these reduce to When we take the corner lattice points from the list (9.16) one obtains nonnegative integer linear combinations of so that we have integer linear combination of 3h 1 and 3h 2 . This matches with the analysis of the truncation above up to a rescaling of C by a factor of 3. Figure 31. The bipartite graph for the K P 2 geometry.

Vertex Constraint
The vertex constraint (4.30) for this case is which reduces the number of parameters to two, given by the triple (h 1 , h 2 , h 3 ): We have also drawn the periodic quiver with the charge assignment (9.21) in the right figure of (9.7). The bond factors (9.9) reduces to Accordingly the (reduced) quiver Yangian can be obtained by setting g (a) = 0 for a = 1, 2, 3 in (9.13).

Truncation
Let us consider the truncation induced by the truncation of the crystal at an atom of color 1. When we have a closed path starting and ending at the quiver vertex 1, we go around the quiver diagram. In each loop we obtain one of the 2 4 = 16 possible weights: The factors of δ 1 , δ 2 cancel out. Moreover, we need to impose the loop constraint (9.27), so that we obtain a linear combination of the following with non-negative integer coefficients: The coordinate function can then be written as Let us next consider truncations of the algebra corresponding to D4-branes. The bipartite graph and the perfect matchings are shown in Figures 33 and 34. There are eight perfect matchings, and they correspond to the linear combinations 2h 1 , 2h 2 , 2h 3 , 2h 4 , h 1 + h 3 + 2δ 1 , h 1 + h 3 − 2δ 1 , h 2 + h 4 + 2δ 2 , h 2 + h 4 − 2δ 2 . Note that the internal lattice point (0, 0) has multiplicity four. For the comparison with the truncation analysis, one needs to choose perfect matchings corresponding to the corner lattice points (±1, 0), (0, ±1). In the list (9.35) these are (9.36) and (9.37)) 2h 1 , 2h 2 , 2h 3 , 2h 4 = −2(h 1 + h 2 + h 3 ) .

Quiver Yangians for General Toric Calabi-Yau Manifolds
We can repeat straightforwardly the analysis above for more general toric Calabi-Yau manifolds. For example, when the toric diagram contains one internal lattice point, the geometry is a canonical bundle over a toric Fano surface: P 1 × P 1 , P 2 , and their toric blow-ups (Hirzebruch surfaces F n=0,1,2 and del Pezzo surfaces dP n=0,1,2,3 ). All the data required for the quiver Yangian, including the periodic quiver and the charge assignments, are known and can be obtained by following the algorithms in the literature. It is more challenging to obtain the reduced quiver Yangian, which requires the Serre relations. It would be interesting to identify the Serre relations in general, and study the representation theory of the reduced quiver Yangian, see section 4.4 for a general discussion.

Summary and Discussion
In this paper, we have proposed a general definition of an infinite-dimensional algebra, the BPS quiver Yangian Y (Q,W ) , associated with a quiver Q and a superpotential W . This algebra acts on configurations of BPS crystal melting model, which is also constructed by Q and W . The pair (Q, W ) specifies a supersymmetric quantum mechanics dual to a toric Calabi-Yau manifold X, whose torus fixed points of the vacuum moduli space are classified by the configurations of BPS crystals. Our algebra therefore acts on the (torus fixed points of) the BPS states in the type IIA compactifications on a toric Calabi-Yau manifold.
When the toric Calabi-Yau manifold has no compact 4-cycles, the quiver Yangian Y (Q,W ) , when supplemented with appropriate Serre relations, reproduces the affine Yangian for the Lie superalgebra gl m|n . More generally, our algebra seems to be new in the literature, but still acts on the configurations of the associated BPS crystals.
The algebra depends on the set of charge parameters h I . We can consider a truncation of the algebra when the charger parameters are non-generic. The resulting truncated algebra Y N (Q,W ) is labelled by 2 integers. We have discussed the relations of these integers to the numbers of D4-branes wrapping divisors.
The quiver/crystal-melting description of our algebra is rather powerful, and can naturally be adopted to discuss wall crossing phenomena of BPS states and open/closed BPS degeneracies.
We hope that the current paper uncovers only the tip of a huge iceberg, and we believe there are many interesting avenues for further research. Let us conclude this paper by mentioning some of the problems for future investigation.
• In this paper we studied BPS state counting in a particular chamber of the moduli space. Since BPS wall crossing for (closed/open) BPS state counting has been discussed in the literature in terms of crystal melting [9][10][11][12][13][14][15][16][17][18], our discussion should generalize straightforwardly to other chambers.
• A gluing construction for the affine Yangians has been worked out in [43,[70][71][72]. It would be interesting to compare the results of the current paper with those from the gluing approach in [43,[70][71][72]. Similarly, the truncations of our algebra, as discussed in section 7, should be related to another set of "web of W-algebras" obtained by gluing W 1+∞ -algebras [48,50].
• Given a quiver and a superpotential one can define a cohomological Hall algebra. We expect that the algebra Y + (Q,W ) in the triangular decomposition (4.21), which we recall are generated by e (a) n 's, can be directly related to the shuffle algebra description of the cohomological Hall algebra. While cohomological Hall algebras for C 3 are known [73], it seems to be difficult to generalize the discussion to a larger class of Calabi-Yau manifolds, and we hope that our work will shed some light on this problem. Note also that the cohomological Hall algebra was recently discussed in the language of supersymmetric quiver quantum mechanics, which is closely related to the approach of this paper [74].
• As we discussed in section 4.4, the question remains to identify the maximal set of Serre relation for the reduced quiver Yangian Y (Q,W ) , for a general toric quiver (Q, W ) (see the related discussion towards the end of section 8.3.6.3).
• We expect that the definition of our quiver Yangian Y (Q,W ) , as well as its representation in terms of crystal melting, can be lifted straightforwardly to the quiver quantum toroidal algebra U q,(Q,W ) . The latter will contain the quantum toroidal algebras for gl n [61] and gl m|n [65] as special examples. It seems that the crystal-melting representation for the gl m|n case was previously not known in the literature.
• BPS crystal melting allows for a refinement (a one-parameter extension) [14,15,75], which is natural in the context of wall crossing phenomena [76]. Is there a corresponding refinement for our algebra?
• It is known that the thermodynamic limit of the crystal melting model reproduces the geometry of the B-model mirror Calabi-Yau geometry [77]. It is then natural to ask if our BPS algebra has anything to do with the integrable hierarchies studied in the B-model geometry [78].
• Recently a new approach to integrable models has been proposed based on a four-dimensional analogue of Chern-Simons theory [79][80][81], which in particular explains the Yangians of integrable models in terms of the algebra of loop operators. It would be interesting to see if the quiver Yangians in this paper can be reproduced in a similar manner by a suitable Chern-Simons type gauge theory. This will in particular explain the geometrical origin of the spectral parameters, which are introduced as auxiliary parameters in the current discussion.