Loading [MathJax]/jax/output/SVG/jax.js
Research article Special Issues

Motives meet SymPy: studying λ-ring expressions in Python

  • We present a new Python package called "motives", a symbolic manipulation package based on SymPy capable of handling and simplifying motivic expressions in the Grothendieck ring of Chow motives and other types of λ-rings. The package is able to manipulate and compare arbitrary expressions in λ-rings and, in particular, it contains explicit tools for manipulating motives of several types of commonly used moduli schemes and moduli stacks of decorated bundles on curves. We have applied this new tool to advance in the verification of Mozgovoy's conjectural formula for the motive of the moduli space of twisted Higgs bundles, proving that it holds in rank 2 and 3 for any curve of genus up to 18 and any twisting bundle of small degree.

    Citation: Daniel Sanchez, David Alfaya, Jaime Pizarroso. Motives meet SymPy: studying λ-ring expressions in Python[J]. Electronic Research Archive, 2025, 33(4): 2118-2147. doi: 10.3934/era.2025093

    Related Papers:

    [1] Lie Fu, Victoria Hoskins, Simon Pepin Lehalleur . Motives of moduli spaces of rank $ 3 $ vector bundles and Higgs bundles on a curve. Electronic Research Archive, 2022, 30(1): 66-89. doi: 10.3934/era.2022004
    [2] Álvaro Antón-Sancho . A construction of Shatz strata in the polystable $ G_2 $-bundles moduli space using Hecke curves. Electronic Research Archive, 2024, 32(11): 6109-6119. doi: 10.3934/era.2024283
    [3] Juxiang Sun, Guoqiang Zhao . Gorenstein invariants under right Quasi-Frobenius extensions. Electronic Research Archive, 2025, 33(6): 3561-3570. doi: 10.3934/era.2025158
    [4] Jian-Tao Liu, Mei-Tong Fu . Theoretical modeling of thin binder interphases in highly filled PBX composites together with the closed form expression of the effective isotropic moduli of a simplified PBX model. Electronic Research Archive, 2025, 33(2): 1045-1069. doi: 10.3934/era.2025047
    [5] Francisco Javier García-Pacheco, María de los Ángeles Moreno-Frías, Marina Murillo-Arcila . On absolutely invertibles. Electronic Research Archive, 2024, 32(12): 6578-6592. doi: 10.3934/era.2024307
    [6] Bolin Zhao . Seeking optimal parameters for achieving a lightweight reservoir computing: A computational endeavor. Electronic Research Archive, 2022, 30(8): 3004-3018. doi: 10.3934/era.2022152
    [7] Weiran Ding, Jiansong Li, Yumeng Jia, Wanru Yang . Tractability of $ L_2 $-approximation and integration over weighted Korobov spaces of increasing smoothness in the worst case setting. Electronic Research Archive, 2025, 33(2): 1160-1184. doi: 10.3934/era.2025052
    [8] Amila Muthunayake, Cac Phan, Ratnasingham Shivaji . An infinite semipositone problem with a reversed S-shaped bifurcation curve. Electronic Research Archive, 2023, 31(2): 1147-1156. doi: 10.3934/era.2023058
    [9] Juan Gerardo Alcázar, Carlos Hermoso, Hüsnü Anıl Çoban, Uğur Gözütok . Computation of symmetries of rational surfaces. Electronic Research Archive, 2024, 32(11): 6087-6108. doi: 10.3934/era.2024282
    [10] Rafael Ortega . Variations on Lyapunov's stability criterion and periodic prey-predator systems. Electronic Research Archive, 2021, 29(6): 3995-4008. doi: 10.3934/era.2021069
  • We present a new Python package called "motives", a symbolic manipulation package based on SymPy capable of handling and simplifying motivic expressions in the Grothendieck ring of Chow motives and other types of λ-rings. The package is able to manipulate and compare arbitrary expressions in λ-rings and, in particular, it contains explicit tools for manipulating motives of several types of commonly used moduli schemes and moduli stacks of decorated bundles on curves. We have applied this new tool to advance in the verification of Mozgovoy's conjectural formula for the motive of the moduli space of twisted Higgs bundles, proving that it holds in rank 2 and 3 for any curve of genus up to 18 and any twisting bundle of small degree.



    The Grothendieck motive of a scheme encodes crucial information about its geometry. For instance, if two schemes share the same class in the Grothendieck ring of Chow motives, then their E-polynomials and their Poincaré polynomials for cohomology with compact support are the same. For this reason, there have been numerous efforts to compute closed formulas for the motives of several types of moduli spaces and moduli stacks in terms of elementary components, like moduli of vector bundles [1,2,3,4], moduli of pairs and chains [5,6], moduli of Higgs bundles and twisted Higgs bundles [6,7,8] and other moduli of Lie algebroid connections [8] or character varieties [9,10,11] among others. However, handling expressions in the Grothendieck ring of motives can be a challenging task, and even comparing if two expressions are equal can become a hard problem. For instance, some of these expressions contain motivic sums with increasing numbers of terms [6,8] or nontrivial plethystic operations on motivic expressions [7,11], whose manipulation can become nontrivial at times.

    In order to tackle this problem, in [12] a theoretical algorithm was proposed for simplifying these types of expressions into polynomials in certain sets of motivic generators, as well as expressions in other types of λ-rings. In that paper, a focus was put on simplifying expressions in the subring of the Grothendieck ring of Chow motives spanned (as a λ-ring) by a finite set of complex projective algebraic curves, and an ad-hoc MATLAB code was implemented to apply this theoretical algorithm to successfully compare two different formulas for the moduli space of L-twisted Higgs bundles: a conjectural equation obtained by Mozgovoy as a solution to the ADHM equations [7] and two formulas proven in [8] for the Grothendieck virtual class of that moduli space in rank 2 and 3 obtained through a Bialynicki-Birula decomposition of the variety. The resulting program was able to verify that Mozgovoy's conjecture for the motive holds for curves of genus at most 11 and any twisting bundle L of low degree.

    In this paper, we have further improved the algorithm proposed in [12], and we have built a full-general purpose λ-ring manipulation Python package, integrating the algorithm into the SymPy symbolic framework [13], a Python library for symbolic mathematics. This new library called motives defines an abstract λ-ring expression class and provides general simplification algorithms capable of simplifying effectively any λ-ring expression into a polynomial in a finite set of motivic generators. By building upon SymPy, these algorithms further integrate into the symbolic manipulation toolbox from SymPy, extending the functionality of its general-purpose simplification and manipulation functionality to work on λ-rings and, at the same time, enriching it with new tools explicitly aimed to simplify and compare λ-ring expressions.

    The simplification algorithms are designed to work with any user-defined λ-ring class, but the library also includes some out-of-the-box types of λ-rings and modules aimed at the working mathematician.

    The current release of the package includes:

    λ-rings of integers.

    ● Free λ-rings and free λ-ring extensions of a λ-ring.

    ● Polynomial λ-ring extensions of a λ-ring.

    ● Grothendieck ring of Chow motives, including the following pre-programmed motives:

    – Complex algebraic curves.

    – Jacobian varieties of curves.

    – Symmetric and alternated products of any variety given its motive.

    – Moduli spaces of vector bundles on curves.

    – Moduli spaces of L-twisted Higgs bundles on curves.

    – Moduli spaces of chain bundles and variations of Hodge structure on curves in low rank.

    – Algebraic groups.

    – Moduli stacks of vector bundles and principal G-bundles on curves.

    – Classifying stacks BG for several groups G.

    and we plan to expand the library with more λ-rings and geometric elements in future releases. The code of the library is publicly hosted at https://github.com/CIAMOD/motives. Additionally, the motives package can be installed directly from PyPI by running pip install motives in a terminal.

    In order to test the capabilities of this—now general-purpose—symbolic package, we have applied it to the same problem treated originally in [12]: the proof of Mozgovoy's conjectural formula of the moduli space of L-twisted Higgs bundles. The new package was proven to be significantly more efficient than the ad-hoc code implemented for the problem in [12]. Using the new algorithm, we were able to prove that Mozgovoy's conjecture holds for curves of genus up to 18 (increasing significantly the current verification, limited to genus 11 curves). Concretely, we prove the following (see Section 5 and Theorem 5.3 for details).

    For each integer n1, let

    Hn(t)=aP(n)sd(a)(ta(s)l(s)La(s))pt(1g)(2l(s)+1)ZX(th(s)La(s)),

    where P(n) denotes the set of ordered partitions of n, d(a) is the Young diagram of the partition aP(n), and, given sd(a), a(s), l(s), and h(s) denote the arm, leg and hook lengths of s in the partition, respectively (see Sections 2 and 5 for details). From Hn(t), define Hr(t) for each r1 as follows:

    r1Hr(t)Tr=(1t)(1Lt)j1k1(1)k+1μ(j)jk(n1ψj[Hn(t)]Tjn)k.

    Let us compute

    MADHMg,r,p:=(1)prLr2(g1)+pr(r+1)2Hr(1).

    Then Mozgovoy's conjecture states that MADHMg,r,p yields the motive of the moduli space of L-twisted Higgs bundles of rank r and degree d on a genus g curve. On the other hand, for r=1,2,3 consider the following motivic formulas MBBg,r,p.

    ⅰ) For r=1

    MBBg,1,p:=[Jac(X)×H0(X,L)]=Lg1+pPX(1)

    ⅱ) For r=2, if (2,d)=1,

    MBBg,2,p:=L4g4+4p(PX(1)PX(L)LgPX(1)2)(1L)(1L2)   +L4g4+3pPX(1)2g1+p2i=1λ2g1+p2i([X]).

    ⅲ) For r=3, if (3,d)=1,

    MBBg,3,p=L9g9+9pPX(1)(L1)(L21)2(L31)(L3g1(1+L+L2)PX(1)2L2g1(1+L)2PX(1)PX(L)+PX(L)PX(L2))+L9g9+7pPX(1)2L113+2g2+p2i=1(Li+gλ2i+2g2+p([X]+L2)λ2i+2g2+p([X]L+1))+L9g9+7pPX(1)2L123+2g2+p2i=1(Li+g1λ2i+2g1+p([X]+L2)λ2i+2g1+p([X]L+1))+L9g9+6pPX(1)2g2+pi=1(2g1+pi)/2j=max{22gp+i,1i}λi+j+2g2+p([X])λi2j+2g1+p([X]).

    These equations were proven in [8] to give expressions for the motives of L-twisted Higgs bundles on a genus g2 curve if the rank and degree of the underlying bundle are coprime. By simplifying computationally both expressions and showing that they are equal (MADHMg,r,p=MBBg,r,p) for low g and p, we proved the following result, significantly expanding the results obtained in [12].

    Theorem 1.1 (Theorem 5.3). Mozgovoy's conjectural formula for the motive of the moduli spaces of L-twisted Higgs bundles hold in the Grothendieck ring of Chow motives in rank at most 3 for any smooth complex projective curve of genus g such that 2g18 and any line bundle L on the curve such that 2g1deg(L)2g+18.

    To put the increment in the genus bound in perspective, the newly obtained motivic polynomials are 5 times larger than the largest motive that the algorithm in [12] was capable of processing before reaching the memory limit of the machine used for the test (128 GB), and the new library is able to perform these simplifications up to an order of magnitude faster than its task-specific predecessor, showcasing an enhanced scaling behavior.

    The paper is structured as follows: Section 2 includes some generalities on λ-rings and introduces some explicit algebraic relations between operators in λ-rings, which will be used by the simplification algorithm. Section 3 explores the properties of the λ-rings of Grothendieck motives (Grothendieck ring of varieties, Grothendieck rings of Chow motives, and other related rings). The description of the main simplification algorithms and the implementation details are described in Section 4.2. Section 5 explores the application of the motives library to proving Mozgovoy's conjecture in low genus and the comparison between the results of this library and the ones obtained in [12]. Finally, as the development of the package continues, some future lines of work and expected future additions to the package are described in Section 6.

    Let R be a unital commutative ring. A λ-ring structure on R is a set of maps λ={λn:RR}nN such that for each x,yR and each nN, the following hold.

    1) λ0(x)=1

    2) λ1(x)=x,

    3) λn(x+y)=ni=0λi(x)λni(y)

    The pair (R,λ) is called a λ-ring. A λ-ring structure is called special if, moreover, for each x,yR and each n,mN, we have

    4) λn(xy)=Pn(λ1(x),,λn(x),λ1(y),,λn(y)),

    5) λn(λm(x))=Pn,m(λ1(x),,λnm(x)),

    where Pn and Pn,m are the Grothendieck universal polynomials, defined as follows (for more information, see [14,15]). If

    sd(ˉX)=sd(X1,,Xn)=1i1<<idndk=1Xik

    is the d-th elementary symmetric polynomial in the variables given by ˉX=(X1,,Xn), then Pn and Pn,m are the unique integral polynomials such that

    Pn(s1(ˉX),,sn(ˉX),s1(ˉY),,sn(ˉY))=coefftnni,j=1(1+tXiYj),
    Pn,m(s1(ˉZ),,snm(ˉZ))=coefftnI{1,,mn}|I|=m(1+tiIZi),

    where ˉX=(X1,,Xn), ˉY=(Y1,,Yn) and ˉZ=(Z1,,Znm). For example, if we denote λn(xy)=Pn=Pn(λ1(x),,λn(x),λ1(y),,λn(y)) and λn(λm(x))=Pn,m=Pn,m(λ1(x),,λnm(x)), then

    P0=1,P1=λ1(x)λ1(y),P2=λ1(x)2λ2(y)+λ1(y)2λ2(x)2λ2(x)λ2(y),P3=λ1(x)3λ3(y)+λ1(x)λ1(y)λ2(x)λ2(y)3λ1(x)λ2(x)λ3(y)+λ1(y)3λ3(x)3λ1(y)λ2(y)λ3(x)+3λ3(x)λ3(y),P0,5=1,P5,0=0,P1,1=λ1(x),P1,2=λ2(x),P2,1=λ2(x),P2,2=λ1(x)λ3(x)λ4(x),P2,3=λ1(x)λ5(x)+λ2(x)λ4(x)+λ6(x),P2,4=λ1(x)λ7(x)λ2(x)λ6(x)+λ3(x)λ5(x)λ8(x).

    For more examples, see, for instance, [15]. Further examples can also be computed using the Python package motives proposed in this work.

    Given an element xR, let

    λt(x)=n0λn(x)tn1+tR[[t]]

    denote the generating series of the λ-powers of x in the variable t. Condition (3) of the definition of λ-ring is equivalent to

    λt(x+y)=λt(x)λt(y). (2.1)

    Given a λ-ring structure on R, we define its opposite λ-ring structure σ as follows. For each xR, take

    σt(x):=(λt(x))1. (2.2)

    It is easy to verify that if λ is a λ-ring structure, then σt(x)=n0σn(x)tn defines another λ-ring structure σ on R. Thus, any λ-ring structure on a ring R defines a triple (R,λ,σ). In this work, we will assume that at least one of the mutually opposite λ-ring structures, λ or σ, is special, and, without loss of generality, we will assume that σ always denotes a special structure and that λ is a structure that may not be special (as will be described in Section 3, this will be the situation in the Grothendieck ring of Chow motives).

    If we assume that σ is a special λ-ring structure, we can associate to it a set of Adams operations ψn:RR for each n1 taking

    ψn(x)=Nn(σ1(x),,σn(x)), (2.3)

    for each xR, where Nn(X1,,Xn) is the Hirzebruch-Newton polynomial, which is the unique polynomial such that

    ni=1Xni=Nn(s1(ˉX),,sn(ˉX))

    for ˉX=(X1,,Xn). For example, if we denote ψn(x)=Nn=Nn(σ1(x),,σn(x), then,

    N1=σ1(x),N2=σ1(x)22σ2(x),N3=σ1(x)33σ1(x)σ2(x)+3σ3(x),N4=σ1(x)44σ1(x)2σ2(x)+4σ1(x)σ3(x)+2σ2(x)24σ4(x).

    Further examples can also be computed using the proposed Python package motives. Furthermore, for each xR, let

    ψt(x):=n1ψn(x)tn

    denote the generating function for the sequence {ψn(x)}n0 in the variable t. Then, it can be shown (see, for instance, [15]) that

    ψt(x)=tddtlog(σt(x)). (2.4)

    Notice that, as σt(x)=(λt(x))1, we have

    ψt(x)=tddtlog(λ(x)). (2.5)

    By [15, Theorem 9.2], if σ is special, then the following hold.

    1) For each nN, ψn:(R,σ)(R,σ) is a λ-ring homomorphism.

    2) ψ1(x)=x.

    3) For each i,jN, ψiψj=ψij.

    In [12], several recurrence formulas were inferred and used for computing certain multivariate polynomials, which allowed expressing λ, σ, and ψ in terms of each other. An efficient computation and manipulation of these polynomials is fundamental to applying the algorithm described in [12] for simplifying algebraic expressions in λ-rings. However, some of the expressions found in [12] were based on iterated substitutions of some multivariate polynomials inside other multivariate polynomial expressions. This was highly inefficient, and we found that it was one of the computational bottlenecks for the application of the cited algorithm (for instance, to the verification of Mozgovoy's conjecture, described in Section 5).

    In order to solve this issue, we will start this work by presenting some alternative equations providing algebraic relations between λ, σ and ψ.

    Let Pk(n) denote the set of ordered partitions of a natural number nN into a sum of k positive natural numbers ordered decreasingly, i.e., the set of decompositions of a number n into a sum of the form

    {n=a1+a2++ak,a1a2ak>0,aiNi=1,,k.

    We will use the notation a=(a1,,ak)Pk(n) to denote the partition n=a1+a2++ak. Let P(n)=nk=1Pk(n) denote the set of all partitions of the number n into sums of positive natural numbers, with an arbitrary number of summands. Given a partition a=(a1,a2,,ak)Pk(n), let ni(a) denote the number of times that i appears in the partition a. For example, a=(3,3,2,1,1)p5(10) satisfies n1(a)=2, n2(a)=1, n3(a)=2, and ni(a)=0 for any other i>3.

    On the other hand, recall that we say that a ring R has additive torsion whenever there exists an element xR and integer n>0 such that nx:=x++xn=0.

    Proposition 2.1. Let σ be a special λ-ring structure on a ring R with no additive torsion and let ψn be the Adams operations associated with σ. Then

    σn(x)=ni=0a=(a1,,ai)Pi(n)((1)n+in1(a)!n2(a)!nn(a)!jψaj(x)aj). (2.6)

    Proof. We solve for σt(x) in Eq (2.4).

    σt(x)=eψt(x)tdt. (2.7)

    Now, we expand ψt(x)tdt:

    ψt(x)tdt=n=0ψn(x)tntdt=n=0ψn(x)tn1dt=n=01nψn(x)tn.

    By using this equality and applying the Taylor series expansion of ex to the right-hand side of Eq (2.7), we obtain:

    σt(x)=i=01i!(ψt(x)tdt)i=i=01i!(n=01nψn(x)tn)i.

    Changing t for t yields

    σt(x)=i=01i!(1)i(n=0(1)n1nψn(x)tn)i.

    We can now expand (n=0(1)n1nψn(x)tn)i by using the multinomial theorem.

    σt(x)=i=01i!n=0(a=(a1,a2,,ai)Pi(n)(1)i(in1(a),n2(a),,nn(a))(1)a1a1ψa1(x)(1)a2a2ψa2(x)(1)aiaiψai(x))tn=n=0ni=0a=(a1,,ai)Pi(n)(1)i+jaji!jaj(in1(a),n2(a),,nn(a))jψaj(x)tn=n=0ni=0a=(a1,,ai)Pi(n)(1)n+ii!jψaj(x)i!n1(a)!n2(a)!nn(a)!jajtn.

    By equating the coefficients and cancelling the factorials, we achieve the desired equality.

    σn(x)=ni=0a=(a1,,ai)Pi(n)((1)n+in1(a)!n2(a)!nn(a)!jψaj(x)aj).

    Proposition 2.2. Let λ and σ be two opposite λ-ring structures on a ring R with no additive torsion and such that σ is special, and let ψn be the Adams operations associated with σ. Then

    λn(x)=ni=0a=(a1,,ai)Pi(n)(1n1(a)!n2(a)!nn(a)!jψaj(x)aj). (2.8)

    Proof. The proof is analogous to the previous lemma, using Eq (2.5) instead of Eq (2.4) and adjusting the signs accordingly.

    Proposition 2.3. Let σ be a special λ-ring structure on a ring R with no additive torsion, and let ψn be the Adams operations associated with σ. Then

    ψn(x)=ni=1(1)i+n+1n1l=0a=(a1,,ai)Pi(l)(nl)i!n1(a)!n2(a)!nl(a)!σnl(x)jσaj(x). (2.9)

    Proof. We apply the Taylor series expansion of the natural logarithm to the right-hand side of Eq (2.4):

    ψt(x)=tddtlog(σt(x))=tddti=11i(σt(x)1)i(1)i1.

    Next, we expand the derivative.

    ψt(x)=ti=11ii(σt(x)1)i1(ddtσt(x))(1)i1=i=0(1)i(n=1σn(x)(t)n)in=1(1)nnσn(x)tn.

    Now we use the multinomial theorem to expand the sum (n=1σn(x)(t)n)i.

    ψt(x)=ni=0(1)i(n=1(a=(a1,,ai)Pi(n)(in1(a),n2(a),,nn(a))j(1)ajσaj(x))tn)n=1(1)nnσn(x)tn

    By applying the convolution, we obtain

    ψt(x)=ni=0(1)in=1nl=0(nl)σnl(x)(a=(a1,,ai)Pi(l)(in1(a),n2(a),,nl(a))(1)ljσaj(x))tn=n=1ni=0(1)in1l=0(1)n(nl)σnl(x)(a=(a1,,ai)Pi(l)(in1(a),n2(a),,nl(a))jσaj(x))tn,

    and, equating the coefficients, we arrive at the desired formula

    ψn(x)=ni=1(1)i+n+1n1l=0a=(a1,,ai)Pi(l)(nl)i!n1(a)!n2(a)!nl(a)!σnl(x)jσaj(x).

    Proposition 2.4. Let λ and σ be two opposite λ-ring structures on a ring R with no additive torsion, and such that σ is special and let ψn be the Adams operations associated with σ. Then

    ψn(x)=ni=1(1)in1l=0a=(a1,,ai)Pi(l)(nl)i!n1(a)!n2(a)!nl(a)!λnl(x)jλaj(x). (2.10)

    Proof. The proof is analogous to the previous lemma, using Eq (2.5) instead of Eq (2.4) and adjusting the signs accordingly.

    Proposition 2.5. Let λ and σ be two opposite λ-ring structures on a ring R such that σ is special, and let ψn be the Adams operations associated with σ. Then

    ψn(x)=ni=1(1)niiσni(x)λi(x).

    Proof. As λ is a λ-ring structure, by (2.1) we have

    λt(x+y)=λt(x)λt(y).

    By substituting x and x, we obtain

    λt(0)=λt(x)λt(x),

    and so

    λt(x)=(λt(x))1. (2.11)

    Next, we use the derivative of the logarithm on the right-hand side of Eq (2.5).

    ψt(x)=tddtlog(λt(x))=tddtλt(x)λt(x)=tn=1nλn(x)tn1λt(x)=λt(x)1n=1nλn(x)tn.

    Now, we apply Eq (2.11) to this result, yielding

    ψt(x)=λt(x)k=1kλk(x)tk=(j=0λj(x)tj)(k=1kλk(x)tk).

    We apply the convolution

    ψt(x)=n=1ni=1iλi(x)λni(x)tn.

    and, by equating the coefficients, we obtain

    ψn(x)=ni=1iλi(x)λni(x).

    Now we use the fact that (1)nσn(x)=λn(x), which follows from (2.11) and the definition of opposite structure, to obtain

    ψn(x)=ni=1(1)niiσni(x)λi(x).

    Remark 2.6. We can further use the equations from [12, Proposition 2] to express σn(x) in terms of λn(x) (or vice versa) in order to expand the right-hand side of the equation from Proposition 2.5 into a polynomial formula in σ or λ that represents a specific degree of ψ. We can obtain it by substituting the corresponding operator by the polynomial PopnZ[X1,,Xn], which expresses λ in terms of σ and vice versa (see [12, Proposition 2] for details)

    σn=Popn(λ1(x),,λn(x)),λn=Popn(σ1(x),,σn(x)),xR (2.12)

    and which can be defined recursively as follows:

    Pop0=1Popn=n1i=0PopiXnin1.

    This yields a polynomial expression

    ψn(x)=ni=1(1)niiσni(x)Popi(σ1(x),,σi(x))

    for ψn(x) in terms of σ operations of x or, equivalently, a polynomial

    ψn(x)=ni=1(1)niiPopni(λ1(x),,λni(x))λi(x)

    in terms of λ operations of x.

    Finally, let us recall the notion of dimension of an element xR in a λ-ring. We say that x is d-dimensional for the structure λ (respectively, for the structure σ) if λt(x) (respectively σt(x)) is a degree d-polynomial. This implies that λn(x)=0 or σn(x)=0 for each n>d, respectively.

    Remark 2.7. If xR is a d-dimensional object for λ, then σn(x) and ψn(x) can be expressed as polynomials in d variables depending on λ1(x),,λd(x) through (2.10) and (2.12).

    Let VarC denote the category of quasi-projective varieties over C. The Grothendieck ring of varieties, denoted by K0(VarC), is the quotient of the free commutative group generated by isomorphism classes of varieties in VarC quotiented by the following relation. If Z is a closed subvariety of X, then

    [X]=[XZ]+[Z],

    where [X] denotes the class of X in K0(VarC). The product of the ring is defined by taking

    [X][Y]=[X×Y]

    for any pair of varieties X and Y.

    Similarly, let CMC denote the category of Chow motives and let K0(CMC) denote the Grothendieck ring of Chow motives. For both rings, we will denote by L:=[A1] the Lefschetz object, and we will also consider the dimensional completions of the localizations of these rings with respect to L. Concretely, let

    ˆK0(VarC):={r0[Xr]Lr|[Xr]VarC, and limr(dim(Xr)r)=}

    denote the completion of the localized ring K0(VarC)[L1] and let ˆK0(CMC) be the completion of K0(CMC)[L1] defined in analogous terms (see [16] or [17] and [1] for more details).

    These rings admit two naturally opposite λ-ring structures of geometric nature. Given a variety XVarC, let

    Symn(X):=nX×X×XSn

    denote its symmetric product. The map Symn extends to a map λn:ˆK0(VarC)ˆK0(VarC) induced by

    λn([X])=[Symn(X)].

    By [18], λ defines a λ-ring structure on K0(VarC), but it is not a special λ-ring structure. Instead, its opposite λ-ring structure, which we will denote by σ, is special.

    Analogous λ-ring structures also exist in ˆK0(CMC). Given a Chow motive [X]ˆK0(CMC), define λn([X])=Symn(X) as the image of the map

    1n!αSnα:XnXn

    and define σn([X])=Altn(X) as the image of the map

    1n!αSn(1)|α|α:XnXn.

    Then, λ and σ are opposite λ-ring structures on ˆK0(CMC) and σ is a special λ-ring structure (see, for instance, [19]). Moreover, the natural map ˆK0(VarC)ˆK0(CMC) is a λ-ring map for these structures and, as a consequence of [20, Proposition 2.7], the localizations ˆK0(VarC) and ˆK0(CMC) have no additive torsion, and, therefore, the identities from Section 2 relating the λ structures λ and σ with the Adams operations ψ in these rings hold.

    Given a variety X, it is common to use the notation

    ZX(t):=n0[Symn(X)]tn=λt(X).

    This is usually called the motivic zeta-function of X [19].

    The motives package is organized around two principal subpackages:

    ⅰ. Core. This subpackage provides the fundamental abstract classes for working with λ-rings and integrates Sympy's capabilities. These classes inside the motives.core subpackage are not expected to be used directly, but instead they serve as base classes for the rest of the objects implemented in the package. The main modules in this subpackage are:

    LambdaRingExpr. This is the abstract class from which all of the implemented classes inherit. It sets the layout that all subclasses should follow. It expands the functionality from SymPy's Expr in order to be able to manage λ-rings.

    Operand. This is the abstract class from which all of the implemented operands inherit. Operands are all classes that act as leaf nodes in the expression tree. It specifies all of the necessary methods operands should implement, as well as defining default behaviours for some of them. These necessary methods are get_adams_var, get_lambda_var, _to_adams, _apply_adams, _to_adams_lambda and _subs_adams. The role of these functions in the main simplification algorithm will be described in Section 4.2.

    Operators. All nodes in an expression tree that are not operands are operators, i.e., all non-root nodes. These include the ring operators Sigma (σ), Lambda_ (λ), and Adams (ψ). The ring operators are implemented as their own classes, inheriting from RingOperator, which itself extends LambdaRingExpr. The SymPy operators, such as Add, Mul, and Pow, are not implemented as subclasses. Instead, the necessary methods are added directly to their classes by defining them as external functions and associating them with the appropriate SymPy methods. This approach ensures compatibility with SymPy's internal instantiation mechanisms, which directly create these classes and would otherwise lack the necessary methods. Note that Lambda_ has purposely a final "_" due to "" being a reserved word in the Python programming language.

    LambdaRingContext. A singleton (i.e., globally shared) class that computes and caches the universal polynomials relating λ, σ, and ψ operators of a λ-ring, computed through the equations described in Propositions 2.2, 2.1, 2.4, 2.3, 2.5, and [12, §2]. The polynomials are computed on demand either recursively or using the explicit formulas described in Section 2 and saved for future use each time a new polynomial is generated.

    Object1Dim. Denotes a 1-dimensional object in a λ-ring for the structure σ. Recall that if an element x in a λ-ring (R,λ,σ) is d-dimensional (for the λ-structure σ), then σn(x)=0 for each n>d. Thus, a 1-dimensional object x satisfies

    σt(x)=1+x

    and, as a consequence of Eqs (2.2) and (2.5), we have

    λn(x)=ψn(x)=xn.

    ⅱ. Grothendieck motives subpackage. On top of these core abstractions, this subpackage defines specific Operand subclasses for elements in the λ-ring of Grothendieck motives (e.g., Curve, Jacobian, Lefschetz, etc.). These can implement specialized rules about Adams or λ-operations, thereby integrating geometric relations with the library's symbolic manipulations. Other domain-specific subpackages can follow the same pattern, using the core λ-ring machinery to handle rewriting and caching. See Section 4.4 for more details on each of the elements of the λ-ring of Grothendieck motives implemented.

    ⅲ. Other base λ-rings implemented not in a subpackage:

    Polynomial1Var: Abstract polynomial symbolic variable yielding a polynomial extension of a λ-ring. Given a λ-ring (R,λ), the ring of polynomials R[T] acquires a natural λ-ring structure in which λn(T)=Tn (in particular, it becomes a 1-dimensional object for the opposite λ-ring structure to λ). It allows defining expressions in polynomial extensions of rings of motives, like the Grothendieck ring of motives.

    Free: Element in a free λ-ring. If no further information is provided, all its λ-powers will be treated as independent algebraic elements in the ring.

    Figure 1 shows the relationship among these classes and subpackages.

    Figure 1.  High-level class diagram of the motives library and its integration with Sympy. Only the most important public methods are shown; all other methods and internal details have been omitted for clarity. Classes are organized into two colored regions: Core (foundation of the lambda-ring framework, including LambdaRingExpr, Operand, and ring operators), and Grothendieck Motives (domain-specific classes for algebraic curves, groups, and moduli schemes/stacks). Solid arrows indicate inheritance, dashed arrows denote usage/composition, dashed borders identify singleton classes, dotted borders indicate private classes and solid borders indicate public classes.

    As mentioned before, the motives package is built on top of SymPy [13]. By leveraging SymPy's existing capabilities for symbolic computation, the motives package extends its functionality to support operations using λ-rings and Grothendieck motives. This integration allows for seamless manipulation of λ-ring expressions using familiar symbolic expressions while introducing specialized classes and methods to handle the motivic expressions. Let us give some details on this integration.

    The motives package introduces a new class, LambdaRingExpr, to define an abstract λ-ring expression that inherits and expands the functionality of SymPy's Expr. As stated in the previous section, this class serves as the base for all expressions in the λ-ring context. Subclasses of LambdaRingExpr implement methods to handle specific types of expressions, ensuring that they conform to the operations and properties of λ-rings.

    The other base classes that have been extended are the basic SymPy operators (Add for addition, Mul for element-wise multiplication, and Pow for power) and the Rational class, which represents all rational numbers. For these classes, no new specific extension has been created, but instead they implement specific methods that are needed to manipulate λ-rings and motives. For instance, they all need the to_adams method, which converts an arbitrary expression into a polynomial of Adams operators and operands. For rational numbers, an extension of the following natural λ-ring structures on the integers has been implemented:

    λn(x)=(x+n1n),σn(x)=(xn),ψn(x)=x,xZ.

    The bulk of the module is on the operands. All of them inherit either from SymPy's Symbol, or from SymPy's AtomicExpr, which is an abstraction of Symbol. This gives them many useful properties, such as the associative and commutative properties, but it also allows the expression to handle more powerful methods, such as expand or simplify. The λ-ring operators (Adams, Lambda and Sigma) are extensions of SymPy's Function.

    The main strategy followed for the simplification algorithm is based on [12, Algorithm 1 and Theorem 4], but some further abstractions and simplifications have been made in order to yield a general implementation of such an algorithm. In order to simplify arbitrary algebraic expressions possibly combining λ, σ, and ψ in non-trivial ways, we use the fact that Adams operations are ring homomorphisms (see, for instance, [15, Theorem 9.2]) and that we can use the expressions obtained in Section 2 and in [12, Section 2] to rewrite any other operators λn or σn as polynomials in Adams operations. More concretely, as ψn is a ring homomorphism for any n, if P(ψk1(x1),,ψks(xs))Q[ψk1(x1),,ψks(xs)] is a rational polynomial expression depending on Adams operations of some x1,,xsR, then,

    ψn(P(ψk1(x1),,ψks(xs)))=P(ψnk1(x1),,ψnks(xs)). (4.1)

    This could also be done if P is a rational expression instead of a polynomial. We can use this principle recursively to transform any expression tree formed by a composition of ring operations and Adams operations into a polynomial (respectively, rational expression) in a finite set of Adams operations of the leaves of the given expression tree.

    Furthermore, the Eqs (2.8) and (2.6) provide a way to compute λn(x) and σn(x) as polynomials depending on the Adams operations ψk(x) for kn for any xR. The motives package combines these two methods to recursively transform any λ-ring expression into a polynomial in Adams operations as follows.

    As introduced in Section 4.1, each expression tree is a LambdaRingExpr whose leaf nodes are subclasses of Operand. The to_adams method rewrites any such expression as a SymPy polynomial depending on the Adams operations of its leaves. The Operand class has been defined to characterize admissible "leaf objects" or "operands" for λ-ring expressions. In order for the simplification algorithm to take into account possible non-trivial and domain-specific algebraic relations between different Adams operations of a certain type of objects, the computation and symbolic representation of Adams operations of an element are always delegated to the corresponding Operand object in the following sense.

    Any Operand object representing an element xR in the λ-ring must implement an _apply_adams method capable of receiving a positive integer n and a polynomial P of the form

    P(ψ1(x),,ψk(x),ψk1(x1),,ψks(xs)) (4.2)

    depending on Adams operations of x and possibly other elements x1,,xs and performs a partial Adams operation on the polynomial, by replacing the instances of the Adams operations of x on which P depends, namely ψ1(x),,ψk(x), with the result of applying ψn to them, leaving any other Adams operation in the expression P unaffected. Concretely, if P is a polynomial as in (4.2), then x._apply_adams(n, P) would yield

    P(ψn(x),,ψnk(x),ψk1(x1),,ψks(xs)).

    Depending on the specific context of what x represents, the concrete λ-ring where this expression lives and possible algebraic relations existing between the Adams operations of x, the computed elements ψkn(x) substituted into P might be new algebraically independent symbolic variables created to represent such Adams operations, some expressions (depending possibly on other Adams operations of x or other elements in the ring), etc. Some more complex manipulations of the polynomials could also be possible. This is left to depend on the implementation of the specific Operand.

    Notice that if P=P(ψk1(x1),,ψks(xs)) is an Adams polynomial depending on x1,,xsR, then applying P = xi._apply_adams(n, P) iteratively for each i=1,,s would yield exactly ψn(P), by (4.1). This behaviour is actually what defines functionally the _apply_adams method. Each Operand must implement it so that an iterated application of the method for each element on which an Adams polynomial depends results in the application of ψn to such a polynomial.

    Counting on the existence of this delegated _apply_adams method on the leaves of an expression tree, the simplification to_adams algorithm performs a recursive walk through the tree acting as follows on each traversed node.

    1) If the node is a built-in SymPy operator node corresponding to a ring operation (Add, Mul, Pow), then perform to_adams at the operand children of the node to transform the operand expressions into Adams polynomials and perform the operation designated by the node on the corresponding results.

    2) If the node is an Adams operation, representing ψn(T) for some child expression tree T, then apply to_adams to the child T to obtain a polynomial (respectively, a rational expression)

    P(ψk1,1(x1),,ψk1,n1(x1),,ψks,ns(xs))

    which represents T and depends on the Adams operations of the Operand objects x1,,xn appearing in the leaves of the tree T. Then, as described before, iteratively apply P = xi.to_adams(n, P) in order to compute ψn(P)=ψn(T), delegating the computation of the Adams operations to the operands xi in T.

    3) If the node is a Lambda_ or Sigma operator, i.e., it represents λn(T) or σn(T) respectively for some child expression tree T, then apply to_adams to T in order to obtain an equivalent Adams polynomial P to T. Then, compute ψk(P) for each k=1,,n by applying the same technique as for the Adams nodes as follows. For each k, apply iteratively xi._apply_lambda(k, P) for each leaf xi in T to obtain a polynomial Pk:=ψk(P). Then, use the polynomials Ln and Lopn from [12, Proposition 3 and Corollary 1], computed through Eqs (2.8) and (2.6), respectively, to compute

    λn(T)=λn(P)=Lopn(ψ1(P),,ψn(P))=Lopn(P1,,Pk)

    or

    σn(T)=σn(P)=Ln(ψ1(P),,ψn(P))=Ln(P1,,Pk)

    as necessary.

    4) Finally, for terminal Operand nodes (that is, a leaf of the tree), the implementation of the to_adams method depends on the specific λ-ring and element being computed. For example, an integer or free symbolic variable will simply return itself.

    Figure 2 shows an overview of the steps taken to convert the expression λ2(ψ2(x)y2) to a polynomial of Adams operators of x and y following the algorithm described.

    Figure 2.  Step-by-step illustration of the to_adams() algorithm. Starting with the expression λ2(ψ2(x)y2), the algorithm iteratively expands the λ2 and ψ2 operations following universal λ-ring relations. Each intermediate tree replaces higher-level operators with expanded terms in the corresponding ψ-powers, until the final expression is a polynomial purely in Adams operators and basic ring operations.

    An additional to_lambda method was also implemented for transforming the expression into a polynomial depending only on λ-powers instead of depending on λ-operations. This becomes useful when the expression depends on objects that are known to be finite-dimensional for the λ structure, so that the resulting simplified polynomial only depends on a known finite set of generators (see Remark 2.7). Moreover, as explained in Section 3, in the Grothendieck rings of varieties and Chow motives λ-operations have an actual geometric meaning, and a decomposition in terms of polynomials of such objects can sometimes be interpreted as very useful geometric decompositions of a variety. To compute to_lambda, first to_adams is computed so that the tree T is transformed into a polynomial of the form T=P(ψk1(x1),,ψks(xs)). Then Propositions 2.4 and 2.5 are used to compute ψki(xi) as a polynomial in terms of λ1(xi),,λki(xi) for each i. These polynomials are then substituted into P to yield the desired polynomial expression for the tree T. This substitution is again delegated to the leaf operands, which must implement a method called _subs_adams. Analogously to _apply_adams, the _subs_adams method is called iteratively on the Adams polynomial for each leaf Operand appearing in the expression tree, and calling it for a leaf substitutes all instances of Adams operations of the given operand by their corresponding polynomial expressions in terms of its λ-powers.

    One could remark that, if the starting expression only depends on λ-operations to begin with, then transforming them completely to Adams operations ψk in order to transform them back to λ-operations λk at the end could be unnecessary for simplifying it in some situations. For instance, if an expression has some parts that are already polynomials in λ, then it would be very inefficient to transform that part of the tree to Adams just to transform it back to λ. This would actually only be needed if there is another operator (λ, σ, or ψ) acting on the subtree, which would require transforming all operators to Adams in order to compute the corresponding composition. In order to avoid this, an optimization was made in the code to detect these types of situations and only transform λ operators into Adams when needed, implemented through a _to_adams_lambda method.

    As the polynomials relating λ, σ, and ψ are universal, a singleton class LambdaRingContext was implemented to compute these polynomials and save them cached for reuse to improve efficiency.

    motives can simplify any expression into a polynomial in Adams or λ operations by calling the methods to_adams() or to_lambda() on the expression, respectively. An example goes as follows. To perform the simplification of the expression

    λ2(ψ2(x)y2),

    Using the motives package, we can run the following Python code:

    x, y = Free("x"), Free("y")
    expr = (x.adams(2) - y / 2).lambda_(2)
    print(expr.to_adams())

    which yields the following equivalent polynomial expression depending solely on x, y and the necessary Adams operations of x and y.

    ψ2(y)4+ψ4(x)2+(ψ2(x)y2)22.

    In the code, x and y were declared as Free objects, so no further assumptions were made on them, and the computation was performed in the free λ-ring spanned by x and y. If to_lambda() is called on the expression instead of to_adams(), we get the following polynomial depending on the λ powers of x and y instead of their Adams operations

    x42+2x2λ2(x)2xλ3(x)+y24(λ2(x))2λ2(y)2+2λ4(x)+(x2y2+2λ2(x))22.

    A graphical depiction of this process can be seen in Figure 2. This expression can be further simplified using the simplify() method provided by Sympy:

    print(expr.to_lambda().simplify())

     | Show Table
    DownLoad: CSV

    which yields the following polynomial still depending on the λ powers of x and y.

    x2y22xλ3(x)+3y28yλ2(x)+λ2(x)2λ2(y)2+2λ4(x).

    Let us describe the main classes implemented in the motives.grothendieck subpackage for handling expressions in extensions of the Grothendieck ring of Chow motives ˆK0(CMC). It contains some classes for handling basic motives, as well as some sub-packages for handling motives depending on algebraic curves, algebraic groups, and moduli schemes and stacks. The package includes the following base classes.

    Motive: Base class for all Grothendieck motives. All other classes inherit from it. It implements methods for computing the symmetric and alternated powers of a motive.

    Lefschetz: Lefschetz object L=[A1].

    Point: Class of a point.

    Proj: Class of the projective space [Pn]. Even though this motive can be clearly expressed in terms of L as [Pn]=Ln++L+1, we have included it as an independent class as a convenient shortcut that can be used in formulas, as well as to give support to symbolic factorizations that could involve projective factors.

    Moreover, the following sub-packages are included.

    Submodule with classes for handling and simplifying motives depending on the class of an abstract smooth complex algebraic curve of genus g, for a given g. Every smooth complex projective curve X admits a canonical decomposition for its Chow motive

    [X]=h0(X)+h1(X)+h2(X)=1+h1(X)+L.

    and, by [21], h1(X) is 2g-dimensional for λ. Concretely, in the following formulas, we will use the notation

    PX(t)=Zh1(X)(t)=2gn=0λn(h1(X))tn

    The module contains the following classes.

    Curve: Class representing the motive of an abstract complex projective curve of genus g. It implements the identities and decompositions from [21] and [19], articulating expressions depending on the curve X as algebraic expressions in a finite set of algebraic generators depending on its Chow decomposition h1(X) (see below for details).

    CurveChow: Chow decomposition h1(X) of a generic genus g curve X. It corresponds to h1(X)=[X]1L. Since X is considered as an abstract algebraic curve, the only algebraic relations between the elements λk(h1(X)) being considered during simplification are the following identities arising from [21] (see also [19]).

    λk(h1(X))=Lkgλ2gk(X)g<k2g
    λk(h1(X))=0k>2g

    In particular, by default, λk(X) for k=1,,g and L are considered as algebraically independent objects in the ring of motives. So are λi(X) and λj(Y) for i,j=1,,g if X and Y are different curves.

    Jacobian: Jacobian of a curve X. Computed in terms of the motivic zeta function of h1(X) (see [21] and [19])

    [Jac(X)]=2gk=0λk(h1(X))=PX(1).

    Piccard: Picard variety of a curve X. The motive coincides with that of its Jacobian.

    Submodule with classes of several complex algebraic groups, based on the formulas from [2]. For a connected semisimple complex group G, the motive is computed as a polynomial in L through the following equation from [2, Proposition 2.1]

    [G]=LdimGri=1(1Ldi), (4.3)

    where di are the degrees of the basic invariant generators of G, and r is its rank. For classical groups, these were obtained from [22, Table 1, pp. 59]. The implemented groups include the following.

    Table 1.  Comparison between the computation times in seconds for the verification of Mozgovoy's conjectural formula using the simplification algorithm from the Motives Python package and the MATLAB implementation of the algorithm from [12]. From g=11, the MATLAB program reached the memory limit of the machine.
    g Motives Python package implementation (s) MATLAB implementation of [12] (s)
    2 4.48e+01 7.58e+01
    3 9.96e+01 1.09e+02
    4 2.41e+02 2.01e+02
    5 4.06e+02 4.18e+02
    6 7.78e+02 8.51e+02
    7 1.47e+03 1.79e+03
    8 2.74e+03 3.44e+03
    9 4.96e+03 1.01e+04
    10 8.80e+03 4.60e+04
    11 1.58e+04 > 2.85e+05
    12 2.87e+04 -
    13 5.14e+04 -
    14 1.02e+05 -
    15 2.18e+05 -
    16 3.83e+05 -
    17 6.09e+05 -
    18 1.79e+06 -

     | Show Table
    DownLoad: CSV

    SemisimpleG: Class of a general connected semisimple complex algebraic group with exponents d1,,dn. Computed through Eq (4.3). It is also used to describe any other possibly non-semisimple group whose motive is nonetheless computed analogously to a that of a connected semisimple complex algebraic group in the sense that it can be calculated in terms of a set of exponents d1,,dn through Eq (4.3) (like GLn).

    A: Motivic class of any connected semisimple complex algebraic group of type An.

    B: Connected semisimple complex algebraic group of type Bn.

    C: Connected semisimple complex algebraic group of type Cn.

    D: Connected semisimple complex algebraic group of type Dn.

    E: Connected semisimple complex algebraic group of type En, for n=6,7,8.

    F4: Connected semisimple complex algebraic group of type F4.

    G2: Connected semisimple complex algebraic group of type G2.

    GL: GLn(C).

    SL: SLn(C).

    PSL: PSLn(C).

    SO: SOn(C).

    Sp: Sp2n(C).

    Spin: Spinn(C).

    Remark 4.1. In addition to the classical and exceptional groups, the motivic equations computed in the package for groups of types An, Bn, Cn, Dn, En, F4, or G2 remain valid for any other connected semisimple complex algebraic group of the given types, since the invariant polynomials and, therefore, the invariant degrees of two semisimple groups with the same Lie algebra coincide and, thus, Eq (4.3) yields the same motivic expression for any of them. For example, the Python class E in this package can be used to compute the motive of the exceptional group E6, but also to obtain the motive of the quotient group E6/Z3 of E6 by its center Z3.

    Submodule with classes for describing the motivic class of some moduli spaces of decorated bundles on curves (in the future, other moduli spaces will be added to this package as well; see Section 6). See Section 5 for further details on the considered moduli. It is composed of a submodule for handling moduli schemes and another submodule for handling moduli stacks.

    The moduli schemes already implemented are:

    VectorBundleModuli: Class of the moduli space of semistable vector bundles of rank r and degree d on a smooth complex projective algebraic curve X of genus g2, computed using the following equations from [6], [5], and [17, Theorem 4.11], assuming that r and d are coprime.

    [M(X,2,d)]=[Jac(X)]PX(L)Lg[Jac(X)]2(L1)(L21)[M(X,3,d)]=[Jac(X)](L1)(L21)2(L31)(L3g1(1+L+L2)[Jac(X)]2L2g1(1+L)2[Jac(X)]PX(L)+PX(L)PX(L2))[M(X,r,d)]=rs=1r1++rn=rri>0(1)s1PX(1)s(1L)s1sj=1rj1i=1ZX(Li)s1j=111Lrj+rj+1Li<jrirj(g1)+s1i=1(ri+ri+1){(r1++ri)d/n}

    where {x} denotes the decimal part of xR, i.e., {x}=xx.

    VHS: Class of the moduli space of variations of Hodge structure, or moduli space of chains of a given type. The currently implemented types are (1,1), (1,2), (2,1), (1,1,1) and (r) (which corresponds to moduli spaces of vector bundles). Further types will be added in the future. Computed using the equations from [6], [5], and the computations from [8]. See [8, §8] for details.

    TwistedHiggsModuli Class of the moduli space of L-twisted Higgs bundles of rank r and degree d on a genus g2 smooth complex projective curve. Two methods have been implemented for computing this class.

    TwistedHiggsModuliBB: Class computed for rank 2 and 3 of the moduli space of L-twisted through a Bialynicki-Birula of the moduli using [8, Corollary 8.1] and [6, Theorem 3]. These formulas were proven when the rank and degree are coprime.

    TwistedHiggsModuliADHM: Conjectural class for the moduli on arbitrary rank and degree. Based on the formulas from [7, Conjecture 3], which are solutions to the motivic ADHM equations [23].

    The moduli stacks already implemented are:

    BG: Classifying space for the group G, BG=[pt/G] for a connected semisimple complex algebraic group G. It is computed as

    [BG]=1/[G],

    with [G] computed through equation (4.3). This formula is conjectural in general, but it has been proven for special groups (like GLn(C), SLn(C) and Sp2n(C)) [2, Example 2.6], for PSLn(C) if n=2,3 [24, Theorem A], for SOn(C) [25, Theorem 3.7 and Corollary 3.8]), and for On [26, Theorem 3.1 and Corollary 3.2].

    Bun: Moduli stack of principal G-bundles on a smooth complex projective curve X, computed through the following conjectural formula from [2, Conjecture 3.4]

    [Bun(X,G)]=|π1(G)|L(g1)dimGri=1ZC(Ldi),

    where di are the exponents of the group and r its rank. The conjecture was proven for G=SLn(C) in [2, §6].

    Let X be a smooth complex projective curve of genus g2, and let L be a line bundle on X of degree deg(L)=2g2+p with p>0. An L-twisted Higgs bundle of rank r on X is a pair (E,φ) consisting of a rank r vector bundle E and a homomorphism φH0(End(E)L). We say that (E,φ) is semistable if for any subbundle FE such that φ(F)FL, the following inequality holds.

    deg(F)rk(F)deg(E)rk(E).

    Let ML(X,r,d) denote the moduli space of semistable L-twisted Higgs bundles on X of degree r and rank d. Through this section, assume that r and d are coprime. There is a natural C action on the moduli space given by t(E,φ)=(E,tφ), giving the moduli space the structure of a smooth semiprojective variety of dimension 1+r2(2g2+p). In [7], Mozgovoy stated the following conjectural formula for this moduli space, which is a solution to the motivic ADHM recursion formula [23].

    Conjecture 5.1. [7, Conjecture 3] For each integer n1, let

    Hn(t)=aP(n)sd(a)(ta(s)l(s)La(s))pt(1g)(2l(s)+1)ZX(th(s)La(s)),

    where P(n) denotes the set of ordered partitions of n, a partition a=(a1,,ak)P(n) is considered as a non-increasing sequence of positive integers a1a2ak>0 summing n, and, for each aP(n), we consider the Young diagram of a, given as

    d(a)={(i,j)Z2|1i,1jai},

    and for each element (i,j)d(a), its arm, leg and hook functions, defined as

    a(i,j)=aij,l(i,j)=max{l|alj}i,h(i,j)=a(i,j)+l(i,j)+1.

    From Hn(t), define Hr(t) for each r1 as follows:

    r1Hr(t)Tr=(1t)(1Lt)j1k1(1)k+1μ(j)jk(n1ψj[Hn(t)]Tjn)k.

    Then Hr(t) is a polynomial in t and

    [ML(X,r,d)]=MADHMg,r,p:=(1)prLr2(g1)+pr(r+1)2Hr(1). (5.1)

    This conjecture implies analogous formulas for the E-polynomial of the moduli space and for the number of rational points in the moduli space, which were later proven in [27, Theorems 1.1 and 4.6].

    On the other hand, in [8], the following formulas were proven for the virtual classes of moduli spaces of L-twisted Higgs bundles of degree d and rank at most 3 by computing the Bialynicki-Birula decomposition of the variety with respect to the previously mentioned natural C-action on the L-twisted Higgs moduli scheme.

    Theorem 5.2. ([6, Theorem 3], [8, Corollary 8.1]). The following equalities hold in ˆK0(VarC).

    1). For r=1

    [ML(X,1,d)]=MBBg,1,p:=[Jac(X)×H0(X,L)]=Lg1+pPX(1) (5.2)

    2). For r=2, if (2,d)=1,

    [ML(X,2,d)]=MBBg,2,p:=L4g4+4p(PX(1)PX(L)LgPX(1)2)(1L)(1L2)   +L4g4+3pPX(1)2g1+p2i=1λ2g1+p2i([X]). (5.3)

    3). For r=3, if (3,d)=1,

    [ML(X,3,d)]=MBBg,3,p:=L9g9+9pPX(1)(L1)(L21)2(L31)(L3g1(1+L+L2)PX(1)2L2g1(1+L)2PX(1)PX(L)+PX(L)PX(L2))+L9g9+7pPX(1)2L113+2g2+p2i=1(Li+gλ2i+2g2+p([X]+L2)λ2i+2g2+p([X]L+1))+L9g9+7pPX(1)2L123+2g2+p2i=1(Li+g1λ2i+2g1+p([X]+L2)λ2i+2g1+p([X]L+1))+L9g9+6pPX(1)2g2+pi=1(2g1+pi)/2j=max{22gp+i,1i}λi+j+2g2+p([X])λi2j+2g1+p([X]). (5.4)

    A direct comparison between the conjectured expression (5.1) and the proven expressions (5.2)–(5.4) is not immediate, especially due to the Adams operations acting on the terms Hn(t) in (5.1) and the sums in the Eqs (5.3) and (5.4). In [12], an ad hoc MATLAB code was written for manipulating these specific expressions using the general simplification algorithm described in that article. As a result, it was proven that the conjectural formulas MADHMg,r,p from 5.1 and the proved formulas MBBg,r,p from Theorem 5.2 agree in ˆK0(CMC) in the following cases:s

    X is any curve of genus g with 2g11,

    L is any line bundle on X of degree 2g1deg(L)2g+18, and

    1r3.

    The computations were carried out on an Intel(R) Xeon(R) E5-2680v4@2.40GHz with 128GB of RAM, and it was found that the main limitation for extending the verification beyond these limits was the over-exponential growth of the memory usage of the MATLAB code with respect to the genus. The test for r=3, g=11 curves, and deg(L)=2g+18 used all the available RAM in the machine. As a way to test the general-purpose simplification library proposed in this work, we have revisited this problem using the new motives package and compared its performance with the previous ad-hoc MATLAB implementation of the algorithm. First, the following simplifications, which were also applied in [12], were performed in Eq (5.4). As λ is a λ-ring structure and L is a 1-dimensional object, then for any n0

    λn([X]+L2)=nk=0λk([X])λnk(L2)=nk=0λk([X])L2n2k,
    λn([X]L+1)=nk=0λk([X]L)=nk=0λk([X])Lk.

    The to_lambda method from motives was then applied to both expressions for the motive of the moduli space. In the case of (5.1), terms in t1 were collected and cancelled before evaluating Hr(1), and the resulting polynomials were compared through a standard SymPy comparison of symbolic expressions.

    We run an instance of motives in the same machine with the same RAM limitations for this problem. The library was able to greatly surpass the capabilities of the previous ad-hoc code, and it compared both expressions successfully, showing that they are equal in ˆK0(CMC) whenever

    X is any curve of genus g with 2g18.

    L is any line bundle on X of degree 2g1deg(L)2g+18, and

    1r3.

    As a consequence, Theorem 5.2 implies that Mozgovoy's conjecture holds under those conditions, yielding the following theorem.

    Theorem 5.3. Let X be any smooth complex projective curve of genus 2g18. Let L be any line bundle on X of degree deg(L)=2g2+p with 0<p20. If r3 and d is coprime with r, then, in ˆK0(CMC),

    [ML(X,r,d)]=MBBg,r,p.

    To put in perspective the jump from genus g=11 to genus g=18, one should consider how the expressions grow with respect to the genus. The moduli space has dimension dim(ML(X,r,d))=r2deg(L)+1, so the largest moduli space processed in [12], corresponding to genus 11, rank 3, and deg(L)=2g+18=40, had dimension 361. The largest moduli space considered in the current work, corresponding to genus 18, rank 3, and deg(L)=2g+18=54, has now dimension 487. The algorithm simplifies the motivic expressions into a multivariate polynomial in g+1 (independent) generators, and its degree is at most the dimension of the moduli space. In [12], the maximum test performed resulted in a degree 361 polynomial in 12 variables with 45,318 terms. In contrast, the new results were attained for a moduli space whose motive is represented by a degree 487 polynomial in 19 variables with 226,100 terms, 5 times larger than the largest expression which the old code was able to handle in that given machine. Figure 3 shows the increase in the number of terms of the computed simplified expression. It is important to notice that the computational complexity of manipulating and simplifying the type of nested polynomial expressions arising naturally from the application of the method to the given expressions raises significantly when the number of variables of the polynomials increases, even slightly. Consider, for instance, that even though the obtained final simplified polynomials are relatively small in this case, polynomials of degree 361 in 12 variables can have at most 3.41024 possible terms, whereas polynomials of degree 487 in 19 variables could have up to 3.11036 terms.

    Figure 3.  Size comparison between the polynomials generated for MBBg,3,20=MADHMg,3,20 after simplification for different g, all taken with r=3 and p=20.

    Figure 4 shows a comparison between the time taken by the algorithm in [12] and the motives library to simplify and compare the motivic expressions MBBg,r,p and MADHMg,r,p for r=3 and p20 for different values of g. The variation in execution time with respect to other choices of p is relatively small, so only the time needed for computing the biggest moduli for each g (r=3 and p=20) with the two methods is shown in the figure for clarity. The chart for the [12] algorithm ends at g=11 as the memory limit for the machine was reached at that point. Table 1 shows the actual time taken to perform the calculations. During the experiments, running the motives library for g=18 also used a significant part of the memory, but there was still room to continue increasing the genus. The test of the library was stopped at g=18 due to the exponential growth of the run time of the algorithm for the given problem.

    Figure 4.  Time comparison between algorithm [12] and motives package for the computational verification of Mozgovoy's conjectural formula. [12] data is limited to g11 because the program reached the memory limit for the machine for that g. The y-axis represents the logarithm with base 10 of the time in seconds spent running the computations.

    It is worth remarking that the new (general purpose) library took less time to compute the biggest g=15 case (whose simplified polynomial has 122,808 terms) than it took for the code in [12] to compute the g=11 case (with 45,318 terms, almost three times less), and it computed the g=11 cases an order of magnitude faster than its predecessors ad-hoc implementation for the problem.

    Another great benefit of the library is its simplicity of use. For example, the code needed to simplify and check the equality of MBBg,r,p and MADHMg,r,p is as follows.

    cur = Curve("x", g = g)
    # Compute the motive of rank r using ADHM derivation
    adhm = TwistedHiggsModuli(x = cur, p = p, r = r, method="ADHM")
    eq_adhm = adhm.compute(verbose = verbose)
    # Compute the motive of rank r using BB derivation
    bb = TwistedHiggsModuli(x = cur, p = p, r = r, method="BB")
    eq_bb = bb.compute(verbose = verbose)
    # Compare the two polynomials
    if eq_adhm - eq_bb = = 0:
      print("Polynomials are equal")

    We plan to continue the development of the library motives, expanding its functionalities in different directions and exploring new applications of its symbolic manipulation capabilities to other problems related to motives of moduli spaces.

    Some features to be implemented in future releases of motives include the following.

    ● Tools for computing E-polynomials, Poincaré polynomials with compact support, and other invariants (like the dimension) from a motive.

    ● Further manipulation tactics capable of partial simplification or manipulation of expression trees in λ-rings, which complement the full simplification algorithm described in this paper.

    ● Implementations for equations of new types of motives of commonly used geometric constructions, like character or representation varieties, general formulas for moduli spaces of chain bundles, and other additional moduli spaces and moduli stacks of bundles and decorated bundles on curves. For instance, we are considering including equations for the motives of Hilbert schemes deduced in [28], or motives for moduli spaces of stable curves of genus 0 with n marked points derived in [29].

    ● Implementations for other commonly used λ-rings. For instance, the implementation of a sub-package for handling expressions in the K-theory of a variety could be a useful tool for handling and simplifying expressions in characteristic classes. The inclusion of sub-packages oriented for the manipulation of symmetric polynomials or some purely combinatorial problems is also being considered.

    Furthermore, the methodology used to verify computationally Mozgovoy's conjecture for curves of small genus could also be used to verify other existing conjectures on the motives of certain moduli spaces, like the conjectures on the geometry of Hilbert schemes described in [28].

    The authors declare they have not used Artificial Intelligence (AI) tools in the creation of this article.

    This research was supported by project CIAMOD (Applications of computational methods and artificial intelligence to the study of moduli spaces, project PP2023_9) funded by Convocatoria de Financiación de Proyectos de Investigación Propios 2023, Universidad Pontificia Comillas, and by grants PID2022-142024NB-I00 and RED2022-134463-T funded by MCIN/AEI/10.13039/501100011033. The authors would like to thank Tomás Gómez for useful discussions.

    The authors declare there are no conflicts of interest.



    [1] S. del Baño, On the motive of moduli spaces of rank two vector bundles over a curve, Compos. Math., 131 (2002), 1–30. https://doi.org/10.1023/A:1014756205008 doi: 10.1023/A:1014756205008
    [2] K. Behrend, A. Dhillon, On the motivic class of the stack of bundles, Adv. Math., 212 (2007), 617–644. https://doi.org/10.1016/j.aim.2006.11.003 doi: 10.1016/j.aim.2006.11.003
    [3] K. S. Lee, Remarks on motives of moduli spaces of rank 2 vector bundles on curves, preprint, arXiv: 1806.11101. https://doi.org/10.48550/arXiv.1806.11101
    [4] T. L. Gómez, K. S. Lee, Motivic decompositions of moduli spaces of vector bundles on curves, preprint, arXiv: 2007.06067. https://doi.org/10.48550/arXiv.2007.06067
    [5] J. Sánchez, Motives of Moduli Spaces of Pairs and Applications, PhD thesis, Universidad Complutense, Madrid, 2014.
    [6] O. García-Prada, J. Heinloth, A. Schmitt, On the motives of moduli of chains and Higgs bundles, J. Eur. Math. Soc., 16 (2014), 2617–2668. https://doi.org/10.4171/jems/494 doi: 10.4171/jems/494
    [7] S. Mozgovoy, Solutions of the motivic ADHM recursion formula, Int. Math. Res. Not., 2012 (2012), 4218–4244. https://doi.org/10.1093/imrn/rnr187 doi: 10.1093/imrn/rnr187
    [8] D. Alfaya, A. Oliveira, Lie algebroid connections, twisted Higgs bundles and motives of moduli spaces, J. Geom. Phys., 201 (2024), 105195. https://doi.org/10.1016/j.geomphys.2024.105195 doi: 10.1016/j.geomphys.2024.105195
    [9] Á. González-Prieto, Motivic theory of representation varieties via topological quantum field theories, preprint, arXiv: 1810.09714. https://doi.org/10.48550/arXiv.1810.09714
    [10] Á. González-Prieto, Virtual classes of parabolic SL2(C)-character varieties, Adv. Math., 368 (2020), 107148. https://doi.org/10.1016/j.aim.2020.107148 doi: 10.1016/j.aim.2020.107148
    [11] C. Florentino, A. Nozad, A. Zamora, Serre polynomials of SLn- and PGLn-character varieties of free groups, J. Geom. Phys., 161 (2021), 104008. https://doi.org/10.1016/j.geomphys.2020.104008 doi: 10.1016/j.geomphys.2020.104008
    [12] D. Alfaya, Simplification of λ-ring expressions in the Grothendieck ring of Chow motives, Appl. Algebra Eng. Commun. Comput., 33 (2022), 599–628. https://doi.org/10.1007/s00200-022-00558-3 doi: 10.1007/s00200-022-00558-3
    [13] A. Meurer, C. P. Smith, M. Paprocki, O. Čertík, S. B. Kirpichev, M. Rocklin, et al., Sympy: symbolic computing in python, PeerJ Comput. Sci., 3 (2017), e103, https://doi.org/10.7717/peerj-cs.103. doi: 10.7717/peerj-cs.103
    [14] D. Knutson, λ-Rings and the Representation Theory of the Symmetric Group, Springer Berlin Heidelberg, Berlin, Heidelberg, 1973, https://doi.org/10.1007/BFb0069217.
    [15] D. Grinberg, λ-rings: Definitions and basic properties, 2019. Available from: https://www.cip.ifi.lmu.de/grinberg/algebra/lambda.pdf.
    [16] J. Manin, Correspondences, motifs and monoidal transformations, Mat. Sb., 77 (1968), 475–507, https://doi.org/10.1070/SM1968v006n04ABEH001070 doi: 10.1070/SM1968v006n04ABEH001070
    [17] S. del Baño, On the Chow motive of some moduli spaces, J. Reine Angew. Math., 532 (2001), 105–132, https://doi.org/10.1515/crll.2001.019 doi: 10.1515/crll.2001.019
    [18] M. Larsen, V. A. Lunts, Rationality criteria for motivic zeta functions, Compos. Math., 140 (2004), 1537–1560. https://doi.org/10.1112/S0010437X04000764 doi: 10.1112/S0010437X04000764
    [19] F. Heinloth, A note on functional equations for zeta functions with values in Chow motives, Ann. Inst. Fourier, 57 (2007), 1927–1945. https://doi.org/10.5802/aif.2318 doi: 10.5802/aif.2318
    [20] M. Larsen, V. A. Lunts, Motivic measures and stable birational geometry, Moscow Math. J., 3 (2003), 85–95. https://doi.org/10.17323/1609-4514-2003-3-1-85-95 doi: 10.17323/1609-4514-2003-3-1-85-95
    [21] M. Kapranov, The elliptic curve in the S-duality theory and Eisenstein series for Kac-Moody groups, preprint, arXiv: math/0001005. https://doi.org/10.48550/arXiv.math/0001005
    [22] J. E. Humphreys, Reflection Groups and Coxeter Groups, Cambridge Studies in Advanced Mathematics, Cambridge University Press, 1990, https://doi.org/10.1017/CBO9780511623646
    [23] W. Y. Chuang, D. E. Diaconescu, G. Pan, Wallcrossing and cohomology of the moduli space of Hitchin pairs, Commun. Number Theory Phys., 5 (2011), 1–56, https://doi.org/10.4310/CNTP.2011.v5.n1.a1 doi: 10.4310/CNTP.2011.v5.n1.a1
    [24] D. Bergh, Motivic classes of some classifying stacks, J. London Math. Soc., 93 (2016), 219–243. https://doi.org/10.1112/jlms/jdv059 doi: 10.1112/jlms/jdv059
    [25] A. Dhillon, M. B. Young, The motive of the classifying stack of the orthogonal group, Mich. Math. J., 65 (2016), 189–197, https://doi.org/10.1307/mmj/1457101817 doi: 10.1307/mmj/1457101817
    [26] M. Talpo, A. Vistoli, The motivic class of the classifying stack of the special orthogonal group, Bull. London Math. Soc., 49 (2017), 818–823. https://doi.org/10.1112/blms.12072 doi: 10.1112/blms.12072
    [27] S. Mozgovoy, R. O'Gorman, Counting twisted Higgs bundles, Math. Res. Lett., 29 (2022), 1551–1570. https://doi.org/10.4310/MRL.2022.v29.n5.a11 doi: 10.4310/MRL.2022.v29.n5.a11
    [28] M. Graffeo, S. Monavari, R. Moschetti, A. T. Ricolfi, The motive of the Hilbert scheme of points in all dimensions, preprint, arXiv: 2406.14321. https://doi.org/10.48550/arXiv.2406.14321
    [29] P. Aluffi, M. Marcolli, E. Nascimento, Explicit formulas for the Grothendieck class of ¯M0,n, preprint, arXiv: 2406.13095. https://doi.org/10.48550/arXiv.2406.13095
  • Reader Comments
  • © 2025 the Author(s), licensee AIMS Press. This is an open access article distributed under the terms of the Creative Commons Attribution License (http://creativecommons.org/licenses/by/4.0)
通讯作者: 陈斌, bchen63@163.com
  • 1. 

    沈阳化工大学材料科学与工程学院 沈阳 110142

  1. 本站搜索
  2. 百度学术搜索
  3. 万方数据库搜索
  4. CNKI搜索

Metrics

Article views(536) PDF downloads(40) Cited by(0)

Other Articles By Authors

/

DownLoad:  Full-Size Img  PowerPoint
Return
Return

Catalog