'Convert a rational function to ``dtype``.'

def from_FractionField(K1, a, K0):

    (q, r) = K0.numer(a).div(K0.denom(a))
    if r.is_zero:
        return K1.from_PolynomialRing(q, K0.field.ring.to_domain())
    else:
        return None
