Solving system of equations in coefficients of expansion of a generating function

I am sorry I couldn't strip my problem down to the bare essentials, without putting things into a bit of context. The idea is to look at the following generating function(known as the Gromov-Witten potential):

$\Phi ^{\mathbb{C}\mathbb{P}^n}(s,t)= \phi ^{\mathbb{C}\mathbb{P}^n}(t)+\sum _{d>0} \sum _{k_2+k_3+\text{...}+k_n\geq2}N_d\left(k_2,\text{...},k_n\right)\frac{t_2^{k_2}\text{...}t_n^{k_n}}{k_2!\text{...} k_n!}e^{d t_1}s^d$

where

$\phi ^{\mathbb{C}\mathbb{P}^n}(t)\text{ = }\frac{1}{6} \sum _{i+j+k=n} t_i t_j t_k$

which satisfies the following third order non-linear partial differential equation: $2 \partial_{t1}\partial_{t2}\partial_{t3}\Phi=\partial _{t1}^3\Phi .\partial _{t2}^3\Phi -\partial _{t1}^2\partial_{t2}\Phi.\partial _{t1}\partial _{t2}^2\Phi$

My goal is to use the PDE to solve for the $N_d$'s. This can be done by plugging into the PDE the expansion of $\Phi(s,t)$ and comparing the coefficient of $e^{t_1}s^d\; {t_2}^{k_2}\;{t_3}^{k3}\;...\;{t_n}^{k_n}$ on both sides of the PDE.

My code to get the $N_d's$:

Definition of $\Phi$:

ClearAll[Sum1];
Attributes[Sum1] = {HoldFirst};
Sum1[f_, {ks_List, ksummax_Integer?Positive}] :=
With[{perms =
Flatten[Permutations /@
IntegerPartitions[#, {Length@ks}, Range[0, #]] & /@
Range[2, ksummax], 2]}, Total[f /. (Thread[ks -> #] & /@ perms)]];

\[CapitalPhi][dmax_, ksummax_][n_, s_,
t_List] := (1/6*
Sum[t[[i + 1]] t[[j + 1]] t[[n - i - j + 1]], {i, 0, n}, {j, 0,
n - i}] +
Sum1[Sum[
No[d][Sequence @@ Table[k[i], {i, 2, n}]]*
Product[t[[i + 1]]^k[i]/k[i]!, {i, 2, n}]*E^(d t[[2]])*s^d, {d,
0, dmax}], {k[#] & /@ Range[2, n], ksummax}])


Example of function evaluation:

In[218]:= \[CapitalPhi][2, 4][3, s, Array[t, 4, 0]] // Simplify

Out[218]= 1/24 (4 t[1]^3 + 24 t[0] t[1] t[2] + 12 t[0]^2 t[3] +
12 t[3]^2 No[0][0, 2] + 4 t[3]^3 No[0][0, 3] +
t[3]^4 No[0][0, 4] + 24 t[2] t[3] No[0][1, 1] +
12 t[2] t[3]^2 No[0][1, 2] + 4 t[2] t[3]^3 No[0][1, 3] +
12 t[2]^2 No[0][2, 0] + 12 t[2]^2 t[3] No[0][2, 1] +
6 t[2]^2 t[3]^2 No[0][2, 2] + 4 t[2]^3 No[0][3, 0] +
4 t[2]^3 t[3] No[0][3, 1] + t[2]^4 No[0][4, 0] +
12 E^t[1] s t[3]^2 No[1][0, 2] + 4 E^t[1] s t[3]^3 No[1][0, 3] +
E^t[1] s t[3]^4 No[1][0, 4] + 24 E^t[1] s t[2] t[3] No[1][1, 1] +
12 E^t[1] s t[2] t[3]^2 No[1][1, 2] +
4 E^t[1] s t[2] t[3]^3 No[1][1, 3] +
12 E^t[1] s t[2]^2 No[1][2, 0] +
12 E^t[1] s t[2]^2 t[3] No[1][2, 1] +
6 E^t[1] s t[2]^2 t[3]^2 No[1][2, 2] +
4 E^t[1] s t[2]^3 No[1][3, 0] +
4 E^t[1] s t[2]^3 t[3] No[1][3, 1] + E^t[1] s t[2]^4 No[1][4, 0] +
12 E^(2 t[1]) s^2 t[3]^2 No[2][0, 2] +
4 E^(2 t[1]) s^2 t[3]^3 No[2][0, 3] +
E^(2 t[1]) s^2 t[3]^4 No[2][0, 4] +
24 E^(2 t[1]) s^2 t[2] t[3] No[2][1, 1] +
12 E^(2 t[1]) s^2 t[2] t[3]^2 No[2][1, 2] +
4 E^(2 t[1]) s^2 t[2] t[3]^3 No[2][1, 3] +
12 E^(2 t[1]) s^2 t[2]^2 No[2][2, 0] +
12 E^(2 t[1]) s^2 t[2]^2 t[3] No[2][2, 1] +
6 E^(2 t[1]) s^2 t[2]^2 t[3]^2 No[2][2, 2] +
4 E^(2 t[1]) s^2 t[2]^3 No[2][3, 0] +
4 E^(2 t[1]) s^2 t[2]^3 t[3] No[2][3, 1] +
E^(2 t[1]) s^2 t[2]^4 No[2][4, 0])


Setting up the LHS and RHS of the PDE:

LHS = 2 Composition[D[#, t[1]] &, D[#, t[2]] &,
D[#, t[3]] &] @\[CapitalPhi][2, 4][3, s, Array[t, 4, 0]] //
Simplify // Expand;
RHS = Composition[D[#, t[1]] &, D[#, t[1]] &, D[#, t[1]] &,
D[#, t[2] ] &, D[#, t[2]] &,
D[#, t[2] ] &]@\[CapitalPhi][2, 4][3, s, Array[t, 4, 0]] -
Composition[D[#, t[1] ] &, D[#, t[1] ] &,
D[#, t[2] ] &]@\[CapitalPhi][2, 4][3, s, Array[t, 4, 0]]*
Composition[D[#, t[1] ] &, D[#, t[2] ] &,
D[#, t[2] ] &]@\[CapitalPhi][2, 4][3, s, Array[t, 4, 0]] //
Simplify // Expand;


Finding the coeffcients on both sides:

coeffLHS = Flatten@CoefficientList[LHS, {Sequence @@ Array[t, 4, 0], E^t[1], s}];
coeffRHS = Flatten@CoefficientList[RHS, {Sequence @@ Array[t, 4, 0], E^t[1], s}];


Finally, comparing both sides and solving for the $N_d$'s:

lim = Min[Length@coeffLHS, Length@coeffRHS];
varsLHS = Variables[coeffLHS[[1 ;; lim]]];
varsRHS = Variables[coeffRHS[[1 ;; lim]]];
Solve[LogicalExpand[coeffLHS[[1 ;; lim]] == coeffRHS[[1 ;; lim]]],
Union[varsLHS, varsRHS]]


The solution I get is the trivial solution(all zeros). It is well known that this system yields non-trivial solutions(all depending only on the seed value of $N_1(0,2)$).

How can I get those solutions?

Edit 1: Solution I am expecting:

For seed value $N_1(0,2)=1$, $N_1(2,1)=1, N_1(4,0)=2, N_2(0,4)=0, N_2(2,3)=1, N_2(4,2)=4, N_2(6,1)=18, N_2(8,0)=92, N_2(0,6)=1, N_3(0,6)=1, N_3(2,5)=5, N_3(4,4)=30, N_3(6,3)=190$

$N_d(k_2,k_3)\neq 0$ if $k_2+2 k_3=4 d$

Here are two snapshots taken from the book J-Holomorphic Curves and Symplectic Topology by Dusa McDuff on Chapter 7, pg. 236 and pg. 237:

As you can see, I used the first out of the set of 4 PDE's to find the $N_d$'s.

• I am not familar with the topic but I executed your code. It seems that the last set of equations only has a trivial solution. I checked that by evaluating step by step always substituting the variables that are exactly zero: eqns = Thread[coeffLHS[[1 ;; lim]] == coeffRHS[[1 ;; lim]]]; rules := Select[eqns, #[[2]] == 0 && Head[#[[1]]] =!= Times && Head[#[[1]]] =!= Plus &] /. Equal -> Rule; Do[eqns = Simplify[Select[eqns, # =!= True &]]; Print["step"]; Print[eqns]; Print[rules]; eqns = eqns /. rules, {3}] – Matthias Bernien Mar 20 '18 at 21:46
• Just a tip, you might consider using FrobeniusSolve[] in Sum1[] instead to generate the summation indices. – J. M. will be back soon Mar 20 '18 at 23:28
• @J.M. Any suggestions following the edit? – Subho Mar 25 '18 at 13:47