Question: Forming a coefficient matrix from polynomial ideal w.r.t. a monomial ordering

Let I=<3x^2+2xy+x, y-xy+3, y^2-2x+4> be a polynomial ideal in K[x,y]. I want to form a matrix M corresponding to this ideal as the following:      

                                 x^2     xy     x      y^2      y      constant

                               -----     ----   ----    ----     ----     ------

                                  [3       2       1       0       0           0]

                             M= [0      -1      0        0       1           3]

                                  [0       0     -2        1       0           4]

 

Please note that in the first, the all monomials appeared in generators of I,  sorted by lexicographic ordering x>y. How can I from matrix M from polynomial I?

Please Wait...