Hello,
I've got a rational expression in sage and I would like to convert it to a polynomial with coefficients in some fraction field.
More precisely, I've got something like this:
a , x = var( 'a , x' ) ;
P = x/a ;
and I would like to see it like a polynomial in the polynomial ring in the variable x with coefficients on the fraction field Q(a) of rational expressions in the variable a:
C.<a> = PolynomialRing(QQ) ;
B = FractionField(C) ;
A.<x> = PolynomialRing(B) ;
But when I try
P.polynomial(A)
I get the following error
TypeError: unable to coerce since the denominator is not 1
Could somebody help me? Thanks in advance!
Néstor