If we have a graph of an equation in two variables, we can tell whether or not the graph depicts a function using the vertical line test.
Recall that if y is a function of x, then no two y values can correspond to a single x value. Graphically, this means that no vertical line can intersect the graph at more than one point. If a vertical line can be found that intersects the graph more than once, then the graph is not a function. For example:
Source: Wikipedia