Polynomial dependency

Consider a quantity $[v_1,v_2,\dots,v_N]$ where each component is a polynomial $$v_1=P_1(x_1,x_2,x_3,x_4),v_2=P_2(x_1,x_2,x_3,x_4),\dots,v_N=P_N(x_1,x_2,x_3,x_4),$$ with $x_1,x_2,x_3,x_4$ being independent variables.

Allowed polynomial forms are: \begin{align} P(x_1) &= a_1 + a_2 x_1 + a_3 x_1^2 + a_4 x_1^3 \\[1mm] P(x_1,x_2) &= a_1 + a_2 x_1 + a_3 x_2 + a_4 x_1^2 + a_5 x_2^2 + a_6 x_1 x_2 + a_7 x_1^3 + a_8 x_2^3 + {} \\& + a_9 x_1^2 x_2 + a_{10} x_1 x_2^2 \\[1mm] P(x_1,x_2,x_3) &= a_1 + a_2 x_1 + a_3 x_2 + a_4 x_3 + a_5 x_1^2 + a_6 x_2^2 + a_7 x_3^2 + a_8 x_1 x_2 + {} \\& + a_9 x_1 x_3 + a_{10} x_2 x_3 + a_{11} x_1^3 + a_{12} x_2^3 + a_{13} x_3^3 + a_{14} x_1^2 x_2 {} \\& + a_{15} x_1^2 x_3 + a_{16} x_2^2 x_1 + + a_{17} x_2^2 x_3 \\[1mm] P(x_1,x_2,x_3,x_4) &= a_1 + a_2 x_1 + a_3 x_2 + a_4 x_3 + a_5 x_4+ a_6 x_1^2 + a_7 x_2^2 + a_8 x_3^2 + {} \\& + a_9 x_4^2 + a_{10} x_1 x_2 + a_{11} x_1 x_3 + a_{12} x_1 x_4 + a_{13} x_2 x_3 + a_{14} x_2 x_4 + {} \\& + a_{15} x_3 x_4 + a_{16} x_1^3 + a_{17} x_2^3 + a_{18} x_3^3 + a_{19} x_4^3 \end{align} Each component $v_n$ is thus represented by the coefficient vector $[a]_n.$

The quantity $[v_1,v_2,\dots,v_N]$ is entered by the batch

XY ISET T -KQT I [IV] V $[a]_1$ $\dots$ V $[a]_N$

where