What Is The Vertical Line Test?
The vertical line test is a graphical method for deciding whether a curve in the plane is the graph of a function.
The rule. If every vertical line drawn through the graph meets it in at most one point, the graph is a function. If any vertical line meets the graph in two or more points, it is not a function.
The test enforces the definition of a function: every input must have exactly one output . A vertical line at shows every output the relation assigns to that input. If you find two outputs, the rule fails.
Why The Test Works
A function assigns each exactly one . A vertical line at collects every point with that -coordinate.
One intersection: the input has one output. Allowed for a function.
Zero intersections: the input is outside the domain. Allowed for a function (means is not in the domain).
Two or more intersections: the input has multiple outputs. Forbidden.
The test is a visual restatement of the "one input, one output" rule. The phrase "passes the vertical line test" and "is a function" mean the same thing.
The Pass-vs-Fail Table For Common Graphs
A quick reference covering the curves students meet through Grade 10.
Curve | Equation | Vertical line test | Function? |
|---|---|---|---|
Straight line (not vertical) | Passes — one intersection at each | Yes | |
Vertical line | Fails — infinitely many intersections at | No | |
Parabola opening up/down | Passes — one intersection at each | Yes | |
Sideways parabola | Fails — two intersections for most | No | |
Circle | Fails — two intersections for | No | |
Ellipse | Fails — two intersections for most | No | |
Cubic | Passes — one intersection at each | Yes | |
Hyperbola (rectangular) | Passes — undefined at , one intersection elsewhere | Yes | |
Square root curve | Passes — one intersection at each | Yes | |
(rotated 90°) | Fails if you allow both signs of | Depends on convention | |
Absolute value | Passes | Yes | |
Inverse absolute value | Fails — two intersections for | No | |
Sine, cosine | , | Passes — periodic but one output per | Yes |
The pattern: any curve where is expressed as a function of passes by construction. Curves where is a function of — sideways parabolas, circles, ellipses — generally fail.
How To Apply The Vertical Line Test — Three Worked Examples
We will walk through three problems — Quick, Standard, and Stretch.
Quick example
Quick. Does the graph of pass the vertical line test?
At any , the equation gives one . A vertical line at meets the graph exactly once at .
Final answer: Yes — is a function.
The detour students take
Standard. Does the graph of pass the vertical line test?
Wrong path. A student reads the equation as "one equation, must be a function" and concludes:
"Yes — it is a single equation involving and , so it represents a function."
That conclusion confuses having an equation with being a function. Every curve has an equation; only some curves are graphs of functions.
Correct path. Test a specific vertical line — say, .
The vertical line meets the circle at and — two intersections. The graph fails the vertical line test.
Final answer: No — the circle is not a function.
In Bhanzu's Grade 10 cohorts, the "every equation is a function" assumption shows up on roughly three out of ten first attempts when students first meet the vertical line test on conic sections. A Bhanzu trainer who hears this draws the circle, then drops a transparent ruler vertically across it — the two intersection points settle the matter without a single word.
Stretch example
Stretch. Does represent as a function of ?
Solve for : . For any positive , there are two values of — one positive, one negative.
A vertical line at hits the curve at and .
Final answer: No — is not a function. (If we restrict to , the upper half alone is a function — a common technique for "salvaging" failing relations.)
The Horizontal Line Test (for one-one functions)
Once a graph passes the vertical line test (so we know we have a function), the horizontal line test decides whether the function is one-one.
Rule. If every horizontal line meets the graph in at most one point, the function is one-one (injective).
passes the vertical line test (is a function) but fails the horizontal line test (the line hits at ).
passes both (function and one-one).
passes the vertical line test (function) but fails the horizontal line test (periodic — every value of in is hit infinitely often).
The two tests together classify a graph: vertical line for "is it a function?", horizontal line for "is it one-one?"
Why Does The Vertical Line Test Matter?
The test is the first thing a student does after sketching a graph — and the answer determines everything that follows.
Defining functions. Without the test, "function" is just a definition. With the test, "function" becomes a property you can check by looking.
Inverse functions. Only one-one functions have proper inverses (which is why the horizontal line test sits beside the vertical line test). A function whose graph fails the horizontal test needs domain restriction before it can be inverted.
Sketching parametric and implicit curves. Conic sections — circles, ellipses, hyperbolas (some orientations) — fail the vertical line test. Engineers and physicists work with these as relations, not as functions, and the test is the first sorting step.
Statistical scatter plots. A scatter plot of data points (where two y-values can share an x-value because of noise) fails the test — which is precisely why scatter plots represent relationships, not functions.
Where The Test Goes Sideways
Three errors account for most of the marks lost on vertical-line-test problems.
Mistake 1: Confusing "is a function" with "has an equation."
Where it slips in: Students assume any tidy equation defines a function.
Don't do this: Declaring a function because it is a single equation in and .
The correct way: Always apply the test. Pick a vertical line and count intersections.
Mistake 2: Mistaking the vertical line test for the horizontal line test.
Where it slips in: Reading "vertical line test" but visualising horizontal lines.
Don't do this: Saying fails the vertical line test because the horizontal line hits twice.
The correct way: The vertical line test uses vertical lines — those of the form . passes the vertical line test (is a function). It fails the horizontal line test (is not one-one).
Mistake 3: Forgetting that zero intersections is OK.
Where it slips in: Some students count "no intersection" as a failure.
Don't do this: Declaring not a function because the vertical line does not meet the graph.
The correct way: A vertical line that misses the graph entirely means is not in the domain — which is fine. The rule is "at most one intersection," and zero counts.
Conclusion
The vertical line test says: a curve is a function if and only if no vertical line crosses it at more than one point.
The test enforces the "one input, one output" definition visually.
The pass-vs-fail table covers the common curves — straight lines, parabolas, cubics, , pass; circles, ellipses, sideways parabolas fail.
The vertical line test answers "function?"; the horizontal line test answers "one-one?". They are complementary.
Zero intersections at a vertical line means that is outside the domain — still allowed.
A practical next step
Three problems to practise. If you stall, come back to the pass-vs-fail table above.
Does the graph of pass the vertical line test?
Does the graph of pass the vertical line test?
Does the graph of pass both the vertical and horizontal line tests?
Want a Bhanzu trainer to walk through more function-test problems live? Book a free demo class — online globally.
Was this article helpful?
Your feedback helps us write better content

