A rational function is a function that can be written as a fraction of two polynomials, f(x) = p(x)q(x), where q(x) is not the zero polynomial. It is undefined wherever q(x) = 0, so its graph often has vertical asymptotes or holes. Examples: f(x) = 1x and g(x) = x + 2x − 5.
In Spanish
función racional
Also called
ratio of polynomials, polynomial fraction function
After factoring, x + 1 cancels and leaves a hole at x = −1. The remaining denominator gives the vertical asymptote x = 1, the numerator gives the zero x = 3, and equal degrees give y = 1.
Formal definition and notation
A rational function is a function of the form f(x) = p(x)q(x), where p and q are polynomials and q is not the zero polynomial. Its domain is every real numberx with q(x) ≠ 0. After common factors are cancelled, zeros of the numerator are x-intercepts, zeros of the denominator are vertical asymptotes, and zeros of cancelled factors are holes.
Rational functions model rates and averages: average cost 500 + 4xx, time dr, work problems.
Reading a rational function
Reading a rational function
f(x) = p(x)q(x), factored and simplified
zeros of p
x-intercepts (where f(x) = 0)
zeros of q
vertical asymptotes
cancelled factors
holes in the graph
degrees of p and q
the horizontal or slant asymptote
Always factor first. You cannot read asymptotes and holes correctly until common factors are found.
Rational Function examples, step by step
Example 1: Domain
Warm-up
Find the domain of f(x) = x + 5x − 4.
Set the denominator equal to 0: x − 4 = 0, so x = 4.
Every other real number is allowed.
Answer: The domain is all real numbers except 4: x ≠ 4.
Example 2: Find every feature
Core
For f(x) = x2 − 1x2 + x − 2, find the hole, the vertical asymptote, the horizontal asymptote and the zero.
Factor: f(x) = (x − 1)(x + 1)(x + 2)(x − 1).
x − 1 cancels: hole at x = 1, where the simplified x + 1x + 2 gives 23. The hole is ( 1, 23 ).
The remaining denominator gives the vertical asymptote x = −2.
Equal degrees: y = 11 = 1. The zero comes from x + 1 = 0: x = −1.
Answer: Hole at (1, 2/3), vertical asymptote x = -2, horizontal asymptote y = 1, zero at x = -1.
Example 3: Average cost
Test-style
Making x shirts costs 500 dollars for setup plus 4 dollars per shirt, so the average cost per shirt is A(x) = 500 + 4xx. How many shirts bring the average cost down to 5 dollars?
Set 500 + 4xx = 5.
Multiply by x: 500 + 4x = 5x.
Solve: x = 500.
The horizontal asymptote y = 4 shows the average can approach, but never reach, 4 dollars.
Answer: 500 shirts bring the average cost to 5 dollars.
Common mistakes
✗ MistakeDomain of x − 2x2 − 4: simplify to 1x + 2, so only x ≠ −2.
✓ InsteadThe domain excludes both x = 2 and x = −2.
The original function is undefined at x = 2. Cancelling does not put that point back; it becomes a hole.
✗ MistakeZeros of x − 3x + 1 come from the denominator: x = −1.
✓ InsteadThe zero is x = 3, from the numerator.
A fraction is 0 when its numerator is 0 and its denominator is not. A zero denominator makes the function undefined.
✗ Mistakef(x) = √xx + 1 is a rational function.
✓ InsteadIt is not, because √x is not a polynomial.
Both the numerator and the denominator must be polynomials, with whole-number exponents on x.
A rational number is a ratio of two integers, like 34. A rational function is a ratio of two polynomials, like x + 3x − 4.
Rational Functionvs.Rational expression
A rational expression is the fraction itself, such as x + 1x − 2. A rational function uses that expression as a rule, f(x) = x + 1x − 2, and has a graph.
Rational Functionvs.Radical function
A radical function has the variable under a root, like √x − 1. A rational function has it in a fraction of polynomials.
Quick check: 3 questions
Question 1 of 3
Which is a rational function?
Show answer and explanation
Answer: C.x2 + 1x − 7 is a ratio of two polynomials. 2x is exponential, √x is a radical and |x − 7| is an absolute value, none of which is a polynomial.
Question 2 of 3
What is the domain of g(x) = xx2 − 4x?
Show answer and explanation
Answer: A.x2 − 4x = x(x − 4) is 0 at 0 and 4, so both are excluded, even though x cancels and leaves a hole at 0. “Except 4” forgets the cancelled factor.
Question 3 of 3
Where is the zero of h(x) = 2x − 6x + 3?
Show answer and explanation
Answer: B. Set the numerator to 0: 2x − 6 = 0, x = 3. x = −3 is the vertical asymptote, not a zero; 2 is the horizontal asymptote value.
Rational Function: frequently asked questions
How do you know if a function is rational?
Check whether it can be written as one polynomial divided by another. 3x2 − 1x + 4 is rational. A function with x under a root, in an exponent or inside an absolute value is not. Every polynomial counts as rational because you can divide it by 1, but the interesting cases have x in the denominator.
What is the difference between a hole and a vertical asymptote?
Both come from zeros of the denominator. If the factor also appears in the numerator and cancels, the graph has a hole: one missing point. If it does not cancel, the graph shoots off toward infinity along a vertical asymptote. In (x − 1)(x + 2)(x − 1)(x − 4), x = 1 is a hole and x = 4 is an asymptote.
What does the graph of a rational function look like?
It usually comes in separate pieces, called branches, split by vertical asymptotes. Far to the left and right it levels off toward a horizontal asymptote or follows a slant line. The parent graph y = 1x has two branches, one in quadrant I and one in quadrant III, approaching both axes without touching them.
Updated November 2026·Reviewed by the Effortless Math team·Standards: CCSS HSF-IF.C.7.d, CCSS HSA-APR.D.6
Cite this entry
Effortless Math Team. “Rational Function.” Effortless Math Dictionary. Updated November 2026. https://www.effortlessmath.com/math-dictionary/rational-function/
Flashcard
TermRational Functionf(x) = p(x)q(x)
DefinitionA function that is a fraction of two polynomials. f(x) = x + 2x − 5 is undefined at 5, where it has a vertical asymptote.
PolynomialA polynomial is an expression built from variables and coefficients using only addition, subtraction, and multiplication, with whole-number exponents. Examples are 3x2 + 5x − 7 and x + 9. Its degree is the highest exponent it contains. A variable in a denominator or under a square root usually means the expression is not a polynomial.Algebra · Algebra 1, Algebra 2DomainThe domain of a function is the set of all input values (usually x-values) the function can accept. Unless a problem says otherwise, it is every real number except values that would divide by zero or take an even root of a negative number. On a graph, the domain is how far the graph reaches left and right.Functions · Grade 8, Algebra 1, Algebra 2Real NumberA real number is any number that can be placed on the number line. The real numbers are all the rational numbers (fractions, integers, terminating and repeating decimals) together with all the irrational numbers (such as √2 and π). Square roots of negative numbers, like √−4, are not real.Number System · Grade 8, Algebra 1NumeratorThe numerator is the top number in a fraction. It tells how many parts are being counted, while the denominator below the fraction bar tells how many equal parts make one whole. In 35, the numerator is 3: three of five equal parts are taken.Number System · Grade 3, Grade 4, Grade 5X-InterceptAn x-intercept is a point where a graph crosses or touches the x-axis. Its y-coordinate is always 0, so it is written (a, 0). To find it, set y = 0 and solve for x. A non-horizontal line has one x-intercept, while a parabola can have two, one or none.Algebra · Grade 8, Algebra 1, Algebra 2DenominatorThe denominator is the bottom number in a fraction. It tells how many equal parts make one whole: in 35, the 5 means the whole is cut into 5 equal parts, and the numerator 3 counts the parts you have. The denominator can never be 0.Number System · Grade 3, Grade 4, Grade 5AsymptoteAn asymptote is a line that a graph gets closer and closer to as it heads off toward infinity. A vertical asymptote x = a appears where the function blows up, often at a zero denominator. A horizontal asymptote y = b shows the value it approaches far left or right. y = 1x has both: x = 0 and y = 0.Functions · Algebra 2, Precalculus, CalculusRatioA ratio compares two quantities by division. Ratios can be written with words, a colon, or a fraction: 3 boys to 5 girls is 3 to 5, 3 : 5, or 35. Order matters, and a ratio can compare part to part or part to whole. Multiplying both numbers by the same amount gives an equivalent ratio.Ratios and Proportions · Grade 6, Grade 7, Grade 8DegreeA degree is the standard unit for measuring an angle, written with the symbol °. One degree is 1360 of a full turn, so a full turn is 360°, a straight angle is 180° and a right angle is 90°. An angle that turns through 25 one-degree angles measures 25°.Geometry · Grade 4, Grade 5, Grade 7Leading CoefficientThe leading coefficient of a polynomial is the number multiplying the term with the highest power of the variable. In 3x2 − 5x4 + 2x, the highest power is x4, so the leading coefficient is −5. Write the polynomial in standard form first; its sign tells which way the graph’s ends point.Algebra · Algebra 1, Algebra 2AverageAn average is one number that stands for the typical size of the values in a data set. In everyday math, average means the mean: add all the values, then divide by how many values there are. In statistics, the median and the mode are also kinds of average.Statistics · Grade 5, Grade 6, Grade 7Equal ToEqual to means having exactly the same value or amount, and it is written with the symbol =. Numbers that look different can still be equal to each other: 12 is equal to 0.5. When two amounts are not the same, one is greater than or less than the other.Symbols and Notation · Kindergarten, Grade 1, Grade 2Rational NumberA rational number is any number that can be written as a fraction of two integers, ab, where b is not 0. Fractions, integers, terminating decimals, and repeating decimals are rational numbers: 34, −5 = −51, 1.6 and 0.333… all qualify. Numbers such as √2 and π are irrational.Number System · Grade 7, Grade 8, Algebra 1FractionA fraction is a number that names equal parts of a whole, written ab. The bottom number, the denominator, tells how many equal parts make one whole; the top number, the numerator, tells how many of those parts you have. So 34 means 3 of 4 equal parts. Every fraction is also a point on the number line.Number System · Grade 3, Grade 4, Grade 5FunctionA function is a rule that gives exactly one output for each input. If you put in one x-value, a function gives back one y-value. In f(x) = 2x + 1, the input 3 gives the output 7. Two inputs may share an output, but one input can never have two different outputs.Functions · Grade 8, Algebra 1, Algebra 2Rational ExpressionA rational expression is a fraction whose numerator and denominator are polynomials, such as x + 3x − 2 or 5x2. The denominator cannot equal 0, so values that make it 0 are excluded. You simplify, add, subtract, multiply and divide rational expressions the same way you work with numerical fractions.Functions · Algebra 1, Algebra 2LimitA limit is the value a function gets closer and closer to as the input approaches a certain number. We write limx → af(x) = L. The function need not even be defined at a. For f(x) = x2 − 1x − 1, f(1) is undefined, but the limit as x → 1 is 2.Calculus · Precalculus, CalculusDomain and RangeDomain and range describe a function: the domain is the set of all inputs it accepts, and the range is the set of all outputs it produces. For the points (1, 4) and (2, 5), the domain is {1, 2} and the range is {4, 5}. Restrictions usually come from division by zero or square roots of negatives.Functions · Grade 8, Algebra 1, Algebra 2End BehaviorEnd behavior describes what the y-values of a graph do at the far left and far right, as x → −∞ and x → ∞. For a polynomial, only the leading term matters: its degree (even or odd) and the sign of its coefficient. For example, f(x) = −2x3 + x rises on the left and falls on the right.Functions · Algebra 2, PrecalculusInversely ProportionalInversely proportional describes two quantities whose product never changes: y = kx, or xy = k, for a fixed nonzero number k. When one quantity doubles, the other is cut in half. On a 120-mile trip, speed and time are inversely proportional: 60 mph takes 2 hours and 30 mph takes 4 hours.Ratios and Proportions · Grade 8, Algebra 1, Algebra 2