quorem takes as arguments
two polynomials A and B with coefficients in ℤ/pℤ, where
A and B are list polynomials or symbolic polynomials with
respect to x or to an optional third argument.

quorem returns the list of the quotient and remainder of the
euclidean division of A by B in ℤ/pℤ[x]
(see also 5.6.12 and 5.26.6).

Input :

quorem((x

`^`

3+x`^`

2+1)%13,(2*x`^`

2+4)%13)or :

quorem((x

`^`

3+x`^`

2+1,2*x`^`

2+4)%13)Output:

[(-6%13)*x+-6%13,(-2%13)*x+-1%13]

Indeed
x^{3}+x^{2}+1=(2x^{2}+4)(x+1/2)+5x−4/4

and −3*4=−6*2=1 mod13.