Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

This functionality can be implemented via solving a system of polynomial equations:

L = 6        # number of terms to compute
R = PolynomialRing(QQ,L,'N')
N = R.gens()
K.<x1,x2> = PowerSeriesRing(R,default_prec=3*L)
f = sum(N[d]*((d+1)*x1).exp()*x2^(3*(d+1)-1)/factorial(3*(d+1)-1) for d in range(L))
p = f.polynomial()    # differentiation seems to be broken for power series
x = p.parent().gens()
eq = p.derivative( x[1], 3 ) - p.derivative( x[0], x[0], x[1] )^2 + p.derivative( x[0], x[0], x[0] )*p.derivative( x[0], x[1], x[1] )
eq = K(eq).add_bigoh(3*L-3)
J = R.ideal( list(eq.dict().values())+[N[0]-1] )
print( J.variety() )

This functionality can be implemented via solving a system of polynomial equations:

L = 6        # number of terms to compute
R = PolynomialRing(QQ,L,'N')
N = R.gens()
K.<x1,x2> = PowerSeriesRing(R,default_prec=3*L)
f = sum(N[d]*((d+1)*x1).exp()*x2^(3*(d+1)-1)/factorial(3*(d+1)-1) for d in range(L))
p = f.polynomial()    # differentiation seems to be broken for power series
x = p.parent().gens()
eq = p.derivative( x[1], 3 ) - p.derivative( x[0], x[0], x[1] )^2 + p.derivative( x[0], x[0], x[0] )*p.derivative( x[0], x[1], x[1] )
eq = K(eq).add_bigoh(3*L-3)
J = R.ideal( list(eq.dict().values())+[N[0]-1] )
print( J.variety() )

Intermediate conversion to polynomial is needed here due to the bug https://trac.sagemath.org/ticket/34846