62.4 Properties and Attributes of Rational Functions

  • IsRationalFunction( obj ) C

    A rational function is an element of the quotient field of a polynomial ring over an UFD. It is represented as a quotient of two polynomials, its numerator (see NumeratorOfRationalFunction) and its denominator (see DenominatorOfRationalFunction)

  • NumeratorOfRationalFunction( ratfun ) A

    returns the nominator of the rational function ratfun.

    As no proper multivariate gcd has been implemented yet, numerators and denominators are not guaranteed to be reduced!

  • DenominatorOfRationalFunction( ratfun ) A

    returns the denominator of the rational function ratfun.

    As no proper multivariate gcd has been implemented yet, numerators and denominators are not guaranteed to be reduced!

    gap> x:=Indeterminate(Rationals,1);;y:=Indeterminate(Rationals,2);;
    gap> DenominatorOfRationalFunction((x*y+x^2)/y);
    y
    gap> NumeratorOfRationalFunction((x*y+x^2)/y);  
    x^2+x*y
    

  • IsPolynomial( ratfun ) P

    A polynomial is a rational functions whose denominator is one. (If the coefficients family forms a field this is equivalent to the denominator being constant.)

    If the base family is not a field, it may be impossible to represent the quotient of a polynomial by a ring element as a polynomial again, but it will have to be represented as a rational function.

    gap> IsPolynomial((x*y+x^2*y^3)/y);
    true
    gap> IsPolynomial((x*y+x^2)/y);
    false
    

  • AsPolynomial( poly ) A

    If poly is a rational function that is a polynomial this attribute returns an equal rational function p such that p is equal to its numerator and the denominator of p is one.

    gap> AsPolynomial((x*y+x^2*y^3)/y);
    x+x^2*y^2
    

  • IsUnivariateRationalFunction( ratfun ) P

    A rational function is univariate if its numerator and its denominator are both polynomials in the same one indeterminate. The attribute IndeterminateNumberOfUnivariateRationalFunction can be used to obtain the number of this common indeterminate.

  • IsUnivariatePolynomial( ratfun ) P

    A univariate polynomial is a polynomial in only one indeterminate.

  • CoefficientsOfUnivariatePolynomial( pol ) A

    CoefficientsOfUnivariatePolynomial returns the coefficient list of the polynomial pol, sorted in ascending order.

  • IsLaurentPolynomial( ratfun ) P

    A Laurent polynomial is a univariate rational function whose denominator is a monomial. Therefore every univariate polynomial is a Laurent polynomial.

    The attribute CoefficientsOfLaurentPolynomial (see CoefficientsOfLaurentPolynomial) gives a compact representation as laurent polynomial.

  • IsConstantRationalFunction( ratfun ) P

    A constant rational function is a function whose numerator and denominator are polynomials of degree 0.

    All these tests are applicable to every rational function. Depending on the internal representation of the rational function, however some of these tests (in particular univariatness) might be expensive in some cases.

    For reasons of performance within algorithms it can be useful to use other attributes, which give a slightly more technical representation. See section The Representations of Rational Functions for details.

    [Top] [Previous] [Up] [Next] [Index]

    GAP 4 manual
    February 2000