BLOG Carl McTague mathematician, composer, photographer, fiddler

23 May 2020 | categories: Mathematics

Computing p-Typical Formal Group Laws

As part of my ongoing project with Doug Ravenel and Vitaly Lorman to compute the homotopy type of the string bordism spectrum $\mathrm{MO}\langle8\rangle$ at the prime 3, I wrote the following Mathematica code to efficiently compute the coefficients of p-typical formal group laws. It works at any prime p, with Araki or Hazewinkel generators. It also efficiently supports truncation, i.e. $\mathrm{BP}\langle k\rangle$. [This is a sliver of a much larger library I have written for computing in Hopf rings.]

The code uses two methods. Method I is naïve but fast at low precision. Method II is more sophisticated, based on a perhaps not widely known theorem in Doug’s Green Book. It is generally slower at low precision, but faster at high precision. My purpose here is both to make code for computing these things readily available, and to popularize this second method.

A little background: Formal group laws (henceforth FGL’s) are the sort of formal power series you get when you take the Taylor expansion of a Lie group at the identity. They lie between Lie groups and Lie algebras. There is a universal 1-dimensional FGL, and when you localize it at a prime p, it breaks up into simpler, p-typical FGL’s. These are FGL’s $\newcommand{\Fplus}{+_F} x\Fplus y=F(x,y)$ whose logarithms $\log_F(x)=\int_0^x\frac{dt}{d/dy(F(0,y))}$ have the form $\log_F(x)=\sum \ell_n x^{p^n}$. The sparsity of their coefficients makes them easier to work with.

Such FGL’s play an important role in algebraic topology, specifically chromatic homotopy theory. They describe how Chern classes within a given cohomology theory behave with respect to tensor product. And just as the universal 1-dimensional FGL splits up, when localized at a prime $p$, into $p$-typical formal group laws, the cohomology theory MU (complex cobordism) splits up, when localized, into simpler cohomology theories called BP (Brown-Peterson cohomology). The p-typical FGL’s computed below thus play an important role in computations involving BP and, via the Adams-Novikov spectral sequence, the homotopy groups of spheres.

There are two systems of generators commonly used when working with p-typical FGL’s – Araki and Hazewinkel, both denoted $v_i$, and defined by the nearly identical recursive formulas $p\ell_n = \sum_{i=0}^n \ell_i v_{n-i}^{p^i}$ and $p\ell_n = \sum_{i=0}^{n-1} \ell_i v_{n-i}^{p^i}$ respectively. The code supports both. Switch between them anytime by setting gen=Araki or gen=Hazewinkel. Similarly, switch between primes anytime by setting p=3 etc.

Back to the algorithms. Method I computes the p-typical FGL by the formula $$F(x,y) = \exp_F( \log_F(x)+\log_F(y) ).$$ This reduces the computation to off-the-shelf algorithms for the inverse and composition of power series.

Method II is based on Theorem 4.3.9 of the Green Book, which estabilishes an equality of p-typical formal sums, $${\sum_t}^F x_t = {\sum_I}^F v_I w_I(x_1,x_2,\dots).$$ On the RHS, the sum ranges over all finite sequences $I$ of positive integers, $v_I$ is a certain polynomial in the $v_i$’s of degree $2(p^{\|I\|}-1)$, and $w_I$ is a polynomial of degree $p^{\|I\|}$, where $\|I\|$ is the sum of the entries of $I$. (See Section 4.3 of the Green Book for details.)

This might not look like a promising way to compute $x \Fplus y$, since it transforms it into an infinite formal sum of complicated polynomials, $$x \Fplus y = v_{\emptyset}w_{\emptyset}(x,y) \Fplus v_{(1)}w_{(1)}(x,y) \Fplus v_{(2)}w_{(2)}(x,y) \Fplus v_{(1,1)}w_{(1,1)}(x,y) \Fplus \cdots$$ But it has its pluses! If you are only working to some fixed precision, say, then since the degrees of the polynomials $w_I$ grow quickly, only a few of them matter. In fact, you can apply the theorem a second time to obtain $$x \Fplus y = v_{\emptyset}w_{\emptyset}(v_{\emptyset}w_{\emptyset}(x,y),w_{(1)}(x,y),v_{(2)}w_{(2)}(x,y),\dots) \Fplus v_{(1)}w_{(1)}(\dots) \Fplus v_{(2)}w_{(2)}(\dots)\Fplus \cdots$$ Again, this might not look promising. In fact, it might even look crazy. But now the degrees of the formal summands (technically they are no longer homogeneous) grow even more quickly than before. By applying the theorem again and again, you can make each summand except the first have such high degree that it is irrelevant to your working precision, and thereby eliminate formal sums from the RHS altogether. That’s exactly how the code below works. [The code is also available from github.]

p=2; gen=Araki; gen=Hazewinkel;

BPl[0,_.,_.,_.] = 1;
BPl[n_,k_Integer:Infinity] := BPl[n,k,p,gen];
BPl[n_,k_,p_Integer,gen_Symbol] := BPl[n,k,p,gen] =
Simplify[1/(p-If[gen===Araki,p^p^n,0])
Sum[BPl[i,k,p,gen] Subscript[v,n-i]^p^i, {i,Max[n-k,0],n-1}] /. Subscript[v,0]->p ];
logBP[ord_Integer,k_Integer:Infinity] := logBP[ord,k,p,gen];
logBP[ord_Integer,k_,p_Integer,gen_Symbol] := logBP[ord,k,p,gen] =
Function[d,Evaluate[Sum[BPl[n,k,p,gen] d^p^n, {n, 0, Log[p, ord]}] + O[d]^ord]];
expBP[ord_Integer,k_Integer:Infinity] := expBP[ord,k,p,gen];
expBP[ord_Integer,k_,p_Integer,gen_Symbol] := expBP[ord,k,p,gen] =
Function[d,Evaluate[Map[Simplify,InverseSeries[logBP[ord,k,p,gen][d]],{2}]]];
fglBP[ord_Integer,k_Integer:Infinity,d_Symbol:d] := fglBP[ord,k,d,p,gen];
fglBP[ord_Integer,k_,d_Symbol,p_Integer,gen_Symbol]:=
fglBP[ord,k,d,p,gen]=Function[{x,y},Evaluate[Module[{z}, Map[Expand,
ComposeSeries[expBP[ord,k,p,gen][d],
ComposeSeries[logBP[ord,k,p,gen][z],x d+O[d]^ord] +
ComposeSeries[logBP[ord,k,p,gen][z],y d+O[d]^ord]], {2}]]]];
pSerBP[ord_Integer,k_Integer:Infinity,d_Symbol:d]:=pSerBP[ord,k,d,p,gen];
pSerBP[ord_Integer,k_,d_Symbol,p_Integer,gen_Symbol][x_]:=
Module[{z}, With[{xPlus=(Normal[fglBP[ord,k,d,p,gen][x,z]]/.d->1)+O[z]^ord},
Map[Expand,Nest[ComposeSeries[xPlus,#]&,x+O[x]^ord,p-1],{2}]]];

vI[I_List] := vI[I,p]; vI[{},_] = 1;
vI[I_List,p_Integer] := vI[I,p] =
Subscript[v, First[I]] vI[Rest[I]]^p^First[I] /. Subscript[v,0]->p;
II[I_List] := II[I,p]; II[n_Integer,p_Integer] := II[n,p]=p-p^p^n;
II[{},_]=1; II[I_List,p_Integer] := II[I,p]=II[Plus@@I,p]II[Most[I],p];

w[K_List,nvars_Integer] := w[K,nvars,p,gen];
w[{},_,_,_][vars__] := Plus[vars];
w[K_List,nvars_Integer,p_Integer,gen_Symbol] :=
With[{slotvars = Slot/@Range[1,nvars]},
With[{formula  = 1/If[gen===Hazewinkel, p^Length[K], II[K]]
(Plus@@(#^p^(Plus@@K) & /@ slotvars)
- Plus@@(Function[j,With[{I=Drop[K,-j],J=Take[K,-j]},
If[gen===Hazewinkel, p^Length[J], II[K]/II[I]]
w[J,nvars,p,gen][Sequence@@slotvars]^p^(Plus@@I)]]
/@ Range[0,Length[K]-1]))},
w[K,nvars,p,gen]=formula&; formula& ]];

BPSumSimplify[ord_Integer,k_Integer:Infinity,d_Symbol:d] := BPSumSimplify[ord,k,d,p,gen];
BPSumSimplify[ord_Integer,k_,d_Symbol,p_Integer,gen_Symbol][terms_List] :=
Cases[ Map[Simplify, vI[#](w[#,Length[terms],p,gen]@@terms) + O[d]^ord, {2}]& /@
Flatten[Permutations/@IntegerPartitions[#,All,Range[1,Min[k,#]]]&/@Range[0,Log[p,ord]],2],
Except[O[d]^ord]]

BPSumToOrder[ord_Integer,k_Integer:Infinity,d_Symbol:d] := BPSumToOrder[ord,k,d,p,gen];
BPSumToOrder[ord_Integer,k_,d_Symbol,p_Integer,gen_Symbol][terms__]:=
Map[Expand,First[NestWhile[BPSumSimplify[ord,k,d,p,gen],{terms}d,Length[#]>1&],{2}]];

pSeriesBP[ord_Integer,k_Integer:Infinity] := pSeriesBP[ord,k,p,gen];
pSeriesBP[ord_Integer,k_,p_Integer,gen_Symbol][x_] :=
Module[{d},Normal[BPSumToOrder[ord,k,d,p,gen]@@Table[x,p]]/.d->1]+O[x]^ord;


To warm up, let’s compute the p-typical FGL at p=2 in terms of Hazewinkel generators to degree 20 by running

p=2; gen=Hazewinkel;
fglBP[20][x,y]


which outputs

$(x+y)d +\left(v_1 x^2 (-y)-v_1 x y^2\right)d^3 +\left(3 v_1^2 x^3 y^2+3 v_1^2 x^2 y^3+v_1^2 x^4 y+v_1^2 x y^4\right)d^5 +\left(-6 v_1^3 x^5 y^2-13 v_1^3 x^4 y^3-13 v_1^3 x^3 y^4-6 v_1^3 x^2 y^5+v_1^3 x^6 (-y)-v_1^3 x y^6\right)d^7 +\left(6 v_1^4 x^7 y^2-12 v_2 x^7 y^2+27 v_1^4 x^6 y^3-28 v_2 x^6 y^3+52 v_1^4 x^5 y^4-42 v_2 x^5 y^4+52 v_1^4 x^4 y^5-42 v_2 x^4 y^5+27 v_1^4 x^3 y^6-28 v_2 x^3 y^6+6 v_1^4 x^2 y^7-12 v_2 x^2 y^7-3 v_2 x^8 y-3 v_2 x y^8\right)d^9 + \left(45 v_1 v_2 x^9 y^2-27 v_1^5 x^8 y^3+163 v_1 v_2 x^8 y^3-106 v_1^5 x^7 y^4+362 v_1 v_2 x^7 y^4-192 v_1^5 x^6 y^5+532 v_1 v_2 x^6 y^5-192 v_1^5 x^5 y^6+532 v_1 v_2 x^5 y^6-106 v_1^5 x^4 y^7+362 v_1 v_2 x^4 y^7-27 v_1^5 x^3 y^8+163 v_1 v_2 x^3 y^8+45 v_1 v_2 x^2 y^9+v_1^5 x^{10} y+6 v_1 v_2 x^{10} y+v_1^5 x y^{10}+6 v_1 v_2 x y^{10}\right)d^{11}+ \left(-15 v_1^6 x^{11} y^2-108 v_1^2 v_2 x^{11} y^2-31 v_1^6 x^{10} y^3-568 v_1^2 v_2 x^{10} y^3+30 v_1^6 x^9 y^4-1770 v_1^2 v_2 x^9 y^4+246 v_1^6 x^8 y^5-3637 v_1^2 v_2 x^8 y^5+484 v_1^6 x^7 y^6-5164 v_1^2 v_2 x^7 y^6+484 v_1^6 x^6 y^7-5164 v_1^2 v_2 x^6 y^7+246 v_1^6 x^5 y^8-3637 v_1^2 v_2 x^5 y^8+30 v_1^6 x^4 y^9-1770 v_1^2 v_2 x^4 y^9-31 v_1^6 x^3 y^{10}-568 v_1^2 v_2 x^3 y^{10}-15 v_1^6 x^2 y^{11}-108 v_1^2 v_2 x^2 y^{11}-2 v_1^6 x^{12} y-9 v_1^2 v_2 x^{12} y-2 v_1^6 x y^{12}-9 v_1^2 v_2 x y^{12}\right)d^{13}+ \left(42 v_1^7 x^{13} y^2+210 v_1^3 v_2 x^{13} y^2+226 v_1^7 x^{12} y^3+1517 v_1^3 v_2 x^{12} y^3+655 v_1^7 x^{11} y^4+6333 v_1^3 v_2 x^{11} y^4+1168 v_1^7 x^{10} y^5+17350 v_1^3 v_2 x^{10} y^5+1412 v_1^7 x^9 y^6+33137 v_1^3 v_2 x^9 y^6+1370 v_1^7 x^8 y^7+45493 v_1^3 v_2 x^8 y^7+1370 v_1^7 x^7 y^8+45493 v_1^3 v_2 x^7 y^8+1412 v_1^7 x^6 y^9+33137 v_1^3 v_2 x^6 y^9+1168 v_1^7 x^5 y^{10}+17350 v_1^3 v_2 x^5 y^{10}+655 v_1^7 x^4 y^{11}+6333 v_1^3 v_2 x^4 y^{11}+226 v_1^7 x^3 y^{12}+1517 v_1^3 v_2 x^3 y^{12}+42 v_1^7 x^2 y^{13}+210 v_1^3 v_2 x^2 y^{13}+3 v_1^7 x^{14} y+12 v_1^3 v_2 x^{14} y+3 v_1^7 x y^{14}+12 v_1^3 v_2 x y^{14}\right)d^{15}+ \left(-72 v_1^8 x^{15} y^2+108 v_2^2 x^{15} y^2-288 v_1^4 v_2 x^{15} y^2-613 v_1^8 x^{14} y^3+624 v_2^2 x^{14} y^3-3010 v_1^4 v_2 x^{14} y^3-2842 v_1^8 x^{13} y^4+2310 v_2^2 x^{13} y^4-16940 v_1^4 v_2 x^{13} y^4-8500 v_1^8 x^{12} y^5+6132 v_2^2 x^{12} y^5-60962 v_1^4 v_2 x^{12} y^5-17987 v_1^8 x^{11} y^6+12348 v_2^2 x^{11} y^6-152080 v_1^4 v_2 x^{11} y^6-28612 v_1^8 x^{10} y^7+19440 v_2^2 x^{10} y^7-274530 v_1^4 v_2 x^{10} y^7-35675 v_1^8 x^9 y^8+24309 v_2^2 x^9 y^8-366965 v_1^4 v_2 x^9 y^8-35675 v_1^8 x^8 y^9+24309 v_2^2 x^8 y^9-366965 v_1^4 v_2 x^8 y^9-28612 v_1^8 x^7 y^{10}+19440 v_2^2 x^7 y^{10}-274530 v_1^4 v_2 x^7 y^{10}-17987 v_1^8 x^6 y^{11}+12348 v_2^2 x^6 y^{11}-152080 v_1^4 v_2 x^6 y^{11}-8500 v_1^8 x^5 y^{12}+6132 v_2^2 x^5 y^{12}-60962 v_1^4 v_2 x^5 y^{12}-2842 v_1^8 x^4 y^{13}+2310 v_2^2 x^4 y^{13}-16940 v_1^4 v_2 x^4 y^{13}-613 v_1^8 x^3 y^{14}+624 v_2^2 x^3 y^{14}-3010 v_1^4 v_2 x^3 y^{14}-72 v_1^8 x^2 y^{15}+108 v_2^2 x^2 y^{15}-288 v_1^4 v_2 x^2 y^{15}-3 v_1^8 x^{16} y+9 v_2^2 x^{16} y-9 v_1^4 v_2 x^{16} y-3 v_1^8 x y^{16}+9 v_2^2 x y^{16}-9 v_1^4 v_2 x y^{16}\right)d^{17}+ \left(90 v_1^9 x^{17} y^2-486 v_1 v_2^2 x^{17} y^2+243 v_1^5 v_2 x^{17} y^2+1150 v_1^9 x^{16} y^3-3867 v_1 v_2^2 x^{16} y^3+4305 v_1^5 v_2 x^{16} y^3+7536 v_1^9 x^{15} y^4-18828 v_1 v_2^2 x^{15} y^4+34080 v_1^5 v_2 x^{15} y^4+31084 v_1^9 x^{14} y^5-63888 v_1 v_2^2 x^{14} y^5+162382 v_1^5 v_2 x^{14} y^5+89278 v_1^9 x^{13} y^6-161560 v_1 v_2^2 x^{13} y^6+523992 v_1^5 v_2 x^{13} y^6+189242 v_1^9 x^{12} y^7-316276 v_1 v_2^2 x^{12} y^7+1216154 v_1^5 v_2 x^{12} y^7+306815 v_1^9 x^{11} y^8-490014 v_1 v_2^2 x^{11} y^8+2099671 v_1^5 v_2 x^{11} y^8+388687 v_1^9 x^{10} y^9-608258 v_1 v_2^2 x^{10} y^9+2747309 v_1^5 v_2 x^{10} y^9+388687 v_1^9 x^9 y^{10}-608258 v_1 v_2^2 x^9 y^{10}+2747309 v_1^5 v_2 x^9 y^{10}+306815 v_1^9 x^8 y^{11}-490014 v_1 v_2^2 x^8 y^{11}+2099671 v_1^5 v_2 x^8 y^{11}+189242 v_1^9 x^7 y^{12}-316276 v_1 v_2^2 x^7 y^{12}+1216154 v_1^5 v_2 x^7 y^{12}+89278 v_1^9 x^6 y^{13}-161560 v_1 v_2^2 x^6 y^{13}+523992 v_1^5 v_2 x^6 y^{13}+31084 v_1^9 x^5 y^{14}-63888 v_1 v_2^2 x^5 y^{14}+162382 v_1^5 v_2 x^5 y^{14}+7536 v_1^9 x^4 y^{15}-18828 v_1 v_2^2 x^4 y^{15}+34080 v_1^5 v_2 x^4 y^{15}+1150 v_1^9 x^3 y^{16}-3867 v_1 v_2^2 x^3 y^{16}+4305 v_1^5 v_2 x^3 y^{16}+90 v_1^9 x^2 y^{17}-486 v_1 v_2^2 x^2 y^{17}+243 v_1^5 v_2 x^2 y^{17}+2 v_1^9 x^{18} y-27 v_1 v_2^2 x^{18} y+2 v_1^9 x y^{18}-27 v_1 v_2^2 x y^{18}\right)d^{19}+O\left(d^{20}\right)$

[Mathematica handles single-variable power series better than multi-variable ones, so the code represents this two-variable power series in $x$ and $y$ as a power series in a single dummy variable $d$.]

fglBP and the rest of the commands take an optional second parameter k (which defaults to ∞) for restricting to $\mathrm{BP}\langle k\rangle$. Put simply, this kills $v_n$ for $n>k$. Let’s go to $\mathrm{BP}\langle1\rangle$ and increase precision, remaining at p=2,

fglBP[30,1][x,y]


to get

$(x+y)d + \left(v_1 x^2 (-y)-v_1 x y^2\right)d^3+ \left(3 v_1^2 x^3 y^2+3 v_1^2 x^2 y^3+v_1^2 x^4 y+v_1^2 x y^4\right)d^5+ \left(-6 v_1^3 x^5 y^2-13 v_1^3 x^4 y^3-13 v_1^3 x^3 y^4-6 v_1^3 x^2 y^5+v_1^3 x^6 (-y)-v_1^3 x y^6\right)d^7+ \left(6 v_1^4 x^7 y^2+27 v_1^4 x^6 y^3+52 v_1^4 x^5 y^4+52 v_1^4 x^4 y^5+27 v_1^4 x^3 y^6+6 v_1^4 x^2 y^7\right)d^9+ \left(-27 v_1^5 x^8 y^3-106 v_1^5 x^7 y^4-192 v_1^5 x^6 y^5-192 v_1^5 x^5 y^6-106 v_1^5 x^4 y^7-27 v_1^5 x^3 y^8+v_1^5 x^{10} y+v_1^5 x y^{10}\right)d^{11}+ \left(-15 v_1^6 x^{11} y^2-31 v_1^6 x^{10} y^3+30 v_1^6 x^9 y^4+246 v_1^6 x^8 y^5+484 v_1^6 x^7 y^6+484 v_1^6 x^6 y^7+246 v_1^6 x^5 y^8+30 v_1^6 x^4 y^9-31 v_1^6 x^3 y^{10}-15 v_1^6 x^2 y^{11}-2 v_1^6 x^{12} y-2 v_1^6 x y^{12}\right)d^{13}+ \left(42 v_1^7 x^{13} y^2+226 v_1^7 x^{12} y^3+655 v_1^7 x^{11} y^4+1168 v_1^7 x^{10} y^5+1412 v_1^7 x^9 y^6+1370 v_1^7 x^8 y^7+1370 v_1^7 x^7 y^8+1412 v_1^7 x^6 y^9+1168 v_1^7 x^5 y^{10}+655 v_1^7 x^4 y^{11}+226 v_1^7 x^3 y^{12}+42 v_1^7 x^2 y^{13}+3 v_1^7 x^{14} y+3 v_1^7 x y^{14}\right)d^{15}+ \left(-72 v_1^8 x^{15} y^2-613 v_1^8 x^{14} y^3-2842 v_1^8 x^{13} y^4-8500 v_1^8 x^{12} y^5-17987 v_1^8 x^{11} y^6-28612 v_1^8 x^{10} y^7-35675 v_1^8 x^9 y^8-35675 v_1^8 x^8 y^9-28612 v_1^8 x^7 y^{10}-17987 v_1^8 x^6 y^{11}-8500 v_1^8 x^5 y^{12}-2842 v_1^8 x^4 y^{13}-613 v_1^8 x^3 y^{14}-72 v_1^8 x^2 y^{15}-3 v_1^8 x^{16} y-3 v_1^8 x y^{16}\right)d^{17}+ \left(90 v_1^9 x^{17} y^2+1150 v_1^9 x^{16} y^3+7536 v_1^9 x^{15} y^4+31084 v_1^9 x^{14} y^5+89278 v_1^9 x^{13} y^6+189242 v_1^9 x^{12} y^7+306815 v_1^9 x^{11} y^8+388687 v_1^9 x^{10} y^9+388687 v_1^9 x^9 y^{10}+306815 v_1^9 x^8 y^{11}+189242 v_1^9 x^7 y^{12}+89278 v_1^9 x^6 y^{13}+31084 v_1^9 x^5 y^{14}+7536 v_1^9 x^4 y^{15}+1150 v_1^9 x^3 y^{16}+90 v_1^9 x^2 y^{17}+2 v_1^9 x^{18} y+2 v_1^9 x y^{18}\right)d^{19}+ \left(-75 v_1^{10} x^{19} y^2-1594 v_1^{10} x^{18} y^3-14730 v_1^{10} x^{17} y^4-81106 v_1^{10} x^{16} y^5-302978 v_1^{10} x^{15} y^6-822816 v_1^{10} x^{14} y^7-1692592 v_1^{10} x^{13} y^8-2704615 v_1^{10} x^{12} y^9-3407106 v_1^{10} x^{11} y^{10}-3407106 v_1^{10} x^{10} y^{11}-2704615 v_1^{10} x^9 y^{12}-1692592 v_1^{10} x^8 y^{13}-822816 v_1^{10} x^7 y^{14}-302978 v_1^{10} x^6 y^{15}-81106 v_1^{10} x^5 y^{16}-14730 v_1^{10} x^4 y^{17}-1594 v_1^{10} x^3 y^{18}-75 v_1^{10} x^2 y^{19}\right)d^{21}+ \left(1368 v_1^{11} x^{20} y^3+20915 v_1^{11} x^{19} y^4+159130 v_1^{11} x^{18} y^5+774174 v_1^{11} x^{17} y^6+2665810 v_1^{11} x^{16} y^7+6860630 v_1^{11} x^{15} y^8+13632623 v_1^{11} x^{14} y^9+21339672 v_1^{11} x^{13} y^{10}+26625777 v_1^{11} x^{12} y^{11}+26625777 v_1^{11} x^{11} y^{12}+21339672 v_1^{11} x^{10} y^{13}+13632623 v_1^{11} x^9 y^{14}+6860630 v_1^{11} x^8 y^{15}+2665810 v_1^{11} x^7 y^{16}+774174 v_1^{11} x^6 y^{17}+159130 v_1^{11} x^5 y^{18}+20915 v_1^{11} x^4 y^{19}+1368 v_1^{11} x^3 y^{20}-3 v_1^{11} x^{22} y-3 v_1^{11} x y^{22}\right)d^{23}+ \left(144 v_1^{12} x^{23} y^2+349 v_1^{12} x^{22} y^3-16170 v_1^{12} x^{21} y^4-218544 v_1^{12} x^{20} y^5-1480107 v_1^{12} x^{19} y^6-6597862 v_1^{12} x^{18} y^7-21312102 v_1^{12} x^{17} y^8-52390812 v_1^{12} x^{16} y^9-100871068 v_1^{12} x^{15} y^{10}-154803940 v_1^{12} x^{14} y^{11}-191317862 v_1^{12} x^{13} y^{12}-191317862 v_1^{12} x^{12} y^{13}-154803940 v_1^{12} x^{11} y^{14}-100871068 v_1^{12} x^{10} y^{15}-52390812 v_1^{12} x^9 y^{16}-21312102 v_1^{12} x^8 y^{17}-6597862 v_1^{12} x^7 y^{18}-1480107 v_1^{12} x^6 y^{19}-218544 v_1^{12} x^5 y^{20}-16170 v_1^{12} x^4 y^{21}+349 v_1^{12} x^3 y^{22}+144 v_1^{12} x^2 y^{23}+6 v_1^{12} x^{24} y+6 v_1^{12} x y^{24}\right)d^{25}+ \left(-351 v_1^{13} x^{25} y^2-4424 v_1^{13} x^{24} y^3-17874 v_1^{13} x^{23} y^4+105902 v_1^{13} x^{22} y^5+1780416 v_1^{13} x^{21} y^6+11701358 v_1^{13} x^{20} y^7+49712322 v_1^{13} x^{19} y^8+153825690 v_1^{13} x^{18} y^9+365492475 v_1^{13} x^{17} y^{10}+686412386 v_1^{13} x^{16} y^{11}+1036492252 v_1^{13} x^{15} y^{12}+1270800184 v_1^{13} x^{14} y^{13}+1270800184 v_1^{13} x^{13} y^{14}+1036492252 v_1^{13} x^{12} y^{15}+686412386 v_1^{13} x^{11} y^{16}+365492475 v_1^{13} x^{10} y^{17}+153825690 v_1^{13} x^9 y^{18}+49712322 v_1^{13} x^8 y^{19}+11701358 v_1^{13} x^7 y^{20}+1780416 v_1^{13} x^6 y^{21}+105902 v_1^{13} x^5 y^{22}-17874 v_1^{13} x^4 y^{23}-4424 v_1^{13} x^3 y^{24}-351 v_1^{13} x^2 y^{25}-9 v_1^{13} x^{26} y-9 v_1^{13} x y^{26}\right)d^{27}+ \left(567 v_1^{14} x^{27} y^2+11121 v_1^{14} x^{26} y^3+104832 v_1^{14} x^{25} y^4+497609 v_1^{14} x^{24} y^5+495302 v_1^{14} x^{23} y^6-9309850 v_1^{14} x^{22} y^7-73330587 v_1^{14} x^{21} y^8-318071474 v_1^{14} x^{20} y^9-974825601 v_1^{14} x^{19} y^{10}-2280928346 v_1^{14} x^{18} y^{11}-4224444012 v_1^{14} x^{17} y^{12}-6315448095 v_1^{14} x^{16} y^{13}-7703253728 v_1^{14} x^{15} y^{14}-7703253728 v_1^{14} x^{14} y^{15}-6315448095 v_1^{14} x^{13} y^{16}-4224444012 v_1^{14} x^{12} y^{17}-2280928346 v_1^{14} x^{11} y^{18}-974825601 v_1^{14} x^{10} y^{19}-318071474 v_1^{14} x^9 y^{20}-73330587 v_1^{14} x^8 y^{21}-9309850 v_1^{14} x^7 y^{22}+495302 v_1^{14} x^6 y^{23}+497609 v_1^{14} x^5 y^{24}+104832 v_1^{14} x^4 y^{25}+11121 v_1^{14} x^3 y^{26}+567 v_1^{14} x^2 y^{27}+10 v_1^{14} x^{28} y+10 v_1^{14} x y^{28}\right)d^{29}+O\left(d^{30}\right)$

So far we have only used Method I. To compute the same thing using Method II, run BPSumToOrder[30,1][x,y]. Unlike fglBP, you can list more than two summands when calling BPSumToOrder, e.g. BPSumToOrder[30,1][x,y,z].

Method II excels at high-precision calculations, and at handling more than two summands, for example computing p-series, $$[p](x)=x\Fplus\cdots\Fplus x \quad\text{(p times).}$$

Let’s move to the prime p=3, switch to Araki generators, and compute the p-series by running BPSumToOrder[100,1][x,x,x] or equivalently

p=3;gen=Araki;
pSeriesBP[100,1][x]


which outputs

$3 x+v_1 x^3+\frac{9}{8} v_1^2 x^5+\frac{105}{64} v_1^3 x^7+\frac{1377}{512} v_1^4 x^9+\frac{3985389 v_1^5 x^{11}}{839680}+\frac{59092773 v_1^6 x^{13}}{6717440}+\frac{907229781 v_1^7 x^{15}}{53739520}+\frac{2859206553 v_1^8 x^{17}}{85983232}+\frac{47125533252921 v_1^9 x^{19}}{705062502400}+\frac{770136329076849 v_1^{10} x^{21}}{5640500019200}+\frac{12753311865572673 v_1^{11} x^{23}}{45124000153600}+\frac{213532277359138857 v_1^{12} x^{25}}{360992001228800}+\frac{739786458803938484949 v_1^{13} x^{27}}{592026882015232000}+\frac{160172528275426594739975069765697 v_1^{14} x^{29}}{60194116033843632543723683840}+\frac{13738036759250152674233106309048117 v_1^{15} x^{31}}{2407764641353745301748947353600}+\frac{1185477657285968285516675671657275153 v_1^{16} x^{33}}{96310585654149812069957894144000}+\frac{4216662079836460024248686951104873563261 v_1^{17} x^{35}}{157949360472805691794730946396160000}+\frac{14702311640613766553277435605893531072017 v_1^{18} x^{37}}{252718976756489106871569514233856000}+\frac{51481454969227141262970049234204541209581 v_1^{19} x^{39}}{404350362810382570994511222774169600}+\frac{22619865468101997268381331962254155535415917 v_1^{20} x^{41}}{80870072562076514198902244554833920000}+\frac{81780367256576925922593959120230527044587607049 v_1^{21} x^{43}}{132626919001805483286199681069927628800000}+\frac{1446850754068022215344154197219899554433739571041 v_1^{22} x^{45}}{1061015352014443866289597448559421030400000}+\frac{5134276111750341028497261779080422333084076800477 v_1^{23} x^{47}}{1697624563223110186063355917695073648640000}+\frac{456690167246529306226420669455873418326343080577113 v_1^{24} x^{49}}{67904982528924407442534236707802945945600000}+\frac{1669565611681890038520057448914914396263990024439943141 v_1^{25} x^{51}}{111364171347436028205756148200796831350784000000}+\frac{727817101785830204621571412299085854513880916800080117 v_1^{26} x^{53}}{21729594409255810381610955746496942702592000000}+\frac{169814244977278563421836617483275107836618284414581196923503600973849 v_1^{27} x^{55}}{2264582253184894429713717786111977316728786330337673216000000}+\frac{609463945405606309062035428984430796639924562118998968145181222363661 v_1^{28} x^{57}}{3623331605095831087541948457779163706766058128540277145600000}+\frac{11230439210575524257619419784462139227943168786897763521612717937525008269 v_1^{29} x^{59}}{29711319161785814917843977353789142395481676654030272593920000000}+\frac{202232391003004256418106108936578268353191736402021774131378054679681296901 v_1^{30} x^{61}}{237690553294286519342751818830313139163853413232242180751360000000}+\frac{3647430129095356423427669614071855519455147270410494624615116571869971787637 v_1^{31} x^{63}}{1901524426354292154742014550642505113310827305857937446010880000000}+\frac{65881440673225574039174522467643717638054608719738905973342309633526955084893 v_1^{32} x^{65}}{15212195410834337237936116405140040906486618446863499568087040000000}+\frac{244283593110532235430591083138353368072170191211763203057563338040691731389194841 v_1^{33} x^{67}}{24948000473768313070215230904429667086638054252856139291662745600000000}+\frac{884845995963904206064729063646734589517774341598365248314009675623765925443165277 v_1^{34} x^{69}}{39916800758029300912344369447087467338620886804569822866660392960000000}+\frac{16045192773117109726584378363098532358833777543403514716199218943853422453408308269 v_1^{35} x^{71}}{319334406064234407298754955576699738708967094436558582933283143680000000}+\frac{1456453195021108204728173502218102229770819846447193787044959616396498480278838048 777 v_1^{36} x^{73}}{12773376242569376291950198223067989548358683777462343317331325747200000000}+\frac{54263673965181618437973795892274782971393415423638288729048062214411287269753668 68393589 v_1^{37} x^{75}}{20948337037813777118798325085831502859308241395038243040423374225408000000000}+\frac{19744685090892984759126199567593621261169588013339393380889587929721153931776 974856111689 v_1^{38} x^{77}}{33517339260502043390077320137330404574893186232061188864677398760652800000000}+\frac{71915147210074396046915779772281737879438554534983392433332150039293487288889 386012014757 v_1^{39} x^{79}}{53627742816803269424123712219728647319829097971297902183483838017044480000000}+\frac{10412882817149839147666682587021596414901101555118789041971899320645107835607 046488267397589480547838193 v_1^{40} x^{81}}{3407863172909864859794219382673671341575209181355255162571746644049883603440500736000000000}+\frac{877520655355328809430762508324377158669585640123241420133995105 33865924472306769046530973212105631635587260769608465831332732347491987132461 v_1^{41} x^{83}}{12592806659801646509716190767406520881304923590105057362169481545378684534362144919272854388317206040411595182272675840000000000}+\frac{85688261450460475584027958 65834205985031022417188527248262972121889817829004859282410573680361429836946579431131844571128812414099825492607 v_1^{42} x^{85}}{538729696676006267795345059568193406686841650913585341697090119588392921256134542000977727842447317236859686942146560000000000}+\frac{1171334779082591153799419325 354930483616485910905132265325488959505640181098767664753688530138287280428482002067045935025011230619412786801693 v_1^{43} x^{87}}{32237585049092215064873448364560693456140604390668946847153872756169432407967090993338507234092047463453683666618050150400000000}+\frac{53556937408107101850303189 2494088423517613398608111975469092173821135094687728177240210752316090212126710917046369227231039476229290124816503517 v_1^{44} x^{89}}{6447517009818443012974689672912138691228120878133789369430774551233886481593418198667701446818409492690736733323610030080000000000}+\frac{200949060102479039863514 3269557830536276423709841669066835481452339649603074383819927743569717208897889050401197952341205794074775433363983247998969 v_1^{45} x^{91}}{10573927896102246541278491063575907453614118240139414565866470264023573829813205845815030372782191568012808242650720449331200000000000}+\frac{36805281629651020533 002750064833859068632365990794186533139171145441317498336695775284989608711084264956936317437201095201195265298345729650995591953 v_1^{46} x^{93}}{84591423168817972330227928508607259628912945921115316526931762112188590638505646766520242982257532544102465941205763594649600000000000}+\frac{67457317127897383652 9736663813603985590824776936685125595935002591190118923180509191599401262560574536351281068756584622564570150345440659156401962561 v_1^{47} x^{95}}{676731385350543778641823428068858077031303567368922532215454096897508725108045174132161943858060260352819727529646108757196800000000000}+\frac{9897385979815121522 5736052554617268023790878190119292419290707626332114912048284091024976212148802044506375080702777394226982137748619674310517670781 v_1^{48} x^{97}}{43310808662434801833076699396406916930003428311611042061789062201440558406914891144458364406915856662580462561897350960460595200000000}+\frac{46543270964452495233 779587922918083916607930388047754721091419737131820802162836997060732705842704462627860922646178983274751981881010922824510752019859221 v_1^{49} x^{99}}{8878715775799134375780723376263417970650702803880263622666757751295314473417552684613964703417750615828994825188956946894422016000000000000}+O\left(x^{100}\right)$

How do Methods I and II compare in performance? Here is a logarithmic plot of their runtimes when computing the p-series of $\mathrm{BP}\langle1\rangle$ at p=2 to various precisions, with Method I in blue and Method II in orange. As you can see, Method II scales far better. It should be said though that this is a particularly favorable match for Method II: the smaller k is, the better Method II handles $\mathrm{BP}\langle k\rangle$ since this makes the sum on the RHS of Theorem 4.3.9 small. On the other hand, Method II does even better at larger primes.

I was thrilled when I first tried Method II. It feels like a battering ram – sluggish to start, it crushes through high precision calculations.

In general, the code’s ability to compute FGL’s exceeds MathJax’s ability to display them in a browser.

Don’t have Mathematica? Get hold of a Raspberry Pi (which includes it), or run the FGL or p-series code in the Wolfram Cloud.