Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Speeding up solve for a simple system

Mathematica solves the following system of multivariate polynomials almost instantaneously while sagemath takes around 10 seconds. Is there any way to speed up solve?

vars('a15, x13_14, a4, a11, a0, x14_15, x11_13, x5_5, x9_12, a5, a12, x3_4, a1, x7_7, x11_14, x12_15, x5_6, x4_4, x9_9, a6, a13, x3_5, a2, x10_10, x7_8, x6_6, x5_7, x12_12, x8_8, a7, x3_6, x6_7, x14_14, a9, x15_15, x4_6, x11_11, x8_9, a8, x10_12, a14, x13_13, a3, a10, x4_7, x12_14, x11_12, x13_15, x10_13')

polys = [-x3_4*x9_12, -x10_12*x3_4, -x10_13*x3_4, -x11_12*x3_4, -x11_13*x3_4, -x11_14*x3_4, x3_4^2*x7_7, x7_8*x8_9, -x11_12^2*x8_8, -x12_12*x3_4 + x3_4*x4_4, -x12_14*x3_4 + x3_4*x4_6, -x12_15*x3_4 + x3_4*x4_7, -x13_13*x3_4 + x3_4*x5_5, -x13_14*x3_4 + x3_4*x5_6, -x13_15*x3_4 + x3_4*x5_7, -x14_14*x3_4 + x3_4*x6_6, -x14_15*x3_4 + x3_4*x6_7, -x15_15*x3_4*x7_8 + x3_4*x7_8, x3_4*x3_5*x7_7, x3_4*x3_6*x7_7, a0 - 1, a1 - 1, a2 - 1, a3 - 1, a4*x4_4 - 1, a5*x5_5 - 1, a6*x6_6 - 1, a7*x7_7 - 1, a8*x8_8 - 1, a9*x9_9 - 1, a10*x10_10 - 1, a11*x11_11 - 1, a12*x12_12 - 1, a13*x13_13 - 1, a14*x14_14 - 1, a15*x15_15 - 1]

vs = [a15, x13_14, a4, a11, a0, x14_15, x11_13, x5_5, x9_12, a5, a12, x3_4, a1, x7_7, x11_14, x12_15, x5_6, x4_4, x9_9, a6, a13, x3_5, a2, x10_10, x7_8, x6_6, x5_7, x12_12, x8_8, a7, x3_6, x6_7, x14_14, a9, x15_15, x4_6, x11_11, x8_9, a8, x10_12, a14, x13_13, a3, a10, x4_7, x12_14, x11_12, x13_15, x10_13]

%time solve(polys, *vs)

This takes about 10 seconds

Speeding up solve for a simple system

Mathematica solves the following system of multivariate polynomials almost instantaneously while sagemath takes around 10 seconds. Is there any way to speed up solve?

vars('a15, x13_14, a4, a11, a0, x14_15, x11_13, x5_5, x9_12, a5, a12, x3_4, a1, x7_7, x11_14, x12_15, x5_6, x4_4, x9_9, a6, a13, x3_5, a2, x10_10, x7_8, x6_6, x5_7, x12_12, x8_8, a7, x3_6, x6_7, x14_14, a9, x15_15, x4_6, x11_11, x8_9, a8, x10_12, a14, x13_13, a3, a10, x4_7, x12_14, x11_12, x13_15, x10_13')

polys = [-x3_4*x9_12, -x10_12*x3_4, -x10_13*x3_4, -x11_12*x3_4, -x11_13*x3_4, -x11_14*x3_4, x3_4^2*x7_7, x7_8*x8_9, -x11_12^2*x8_8, -x12_12*x3_4 + x3_4*x4_4, -x12_14*x3_4 + x3_4*x4_6, -x12_15*x3_4 + x3_4*x4_7, -x13_13*x3_4 + x3_4*x5_5, -x13_14*x3_4 + x3_4*x5_6, -x13_15*x3_4 + x3_4*x5_7, -x14_14*x3_4 + x3_4*x6_6, -x14_15*x3_4 + x3_4*x6_7, -x15_15*x3_4*x7_8 + x3_4*x7_8, x3_4*x3_5*x7_7, x3_4*x3_6*x7_7, a0 - 1, a1 - 1, a2 - 1, a3 - 1, a4*x4_4 - 1, a5*x5_5 - 1, a6*x6_6 - 1, a7*x7_7 - 1, a8*x8_8 - 1, a9*x9_9 - 1, a10*x10_10 - 1, a11*x11_11 - 1, a12*x12_12 - 1, a13*x13_13 - 1, a14*x14_14 - 1, a15*x15_15 - 1]

vs = [a15, x13_14, a4, a11, a0, x14_15, x11_13, x5_5, x9_12, a5, a12, x3_4, a1, x7_7, x11_14, x12_15, x5_6, x4_4, x9_9, a6, a13, x3_5, a2, x10_10, x7_8, x6_6, x5_7, x12_12, x8_8, a7, x3_6, x6_7, x14_14, a9, x15_15, x4_6, x11_11, x8_9, a8, x10_12, a14, x13_13, a3, a10, x4_7, x12_14, x11_12, x13_15, x10_13]

%time solve(polys, *vs)

This takes about 10 seconds