Horizontal line test
From Wikipedia, the free encyclopedia
In mathematics, the horizontal line test is a test used to determine if a function is injective, surjective or bijective.
Suppose there is a function f : X → Y with a graph., and you have a horizontal line of X x Y : .
- If the function is injective, then it can be visualized as one whose graph is never intersected by any horizontal line more than once.
- Iff f is surjective any horizontal line will intersect the graph at least at one point
- If f is bijective any horizontal line will intersect the graph at exactly one point.
Passes the test (injective) |
Fail the test (not injective) |
This test is also used to find whether or not the inverse of the function is indeed a function as well. This is due to the reflective properties of the function over y=x.