Trigonometric Functions Having No Holes

When a rational function such as y = (x^2)/x is shown on a graph, there is a hole at x = 0. But, for the rational trigonometric function y = (cos^2(x))/(cos(x)) is shown on a graph, there are no holes at pi/2, 3pi/2, and so on. Why does this occur?

Thank you for your help.

I think it has something to do with approximating pi. If you use cos^2(pix)/cos(pix), then the undefined points will show up as undefined. Without this change the point’s x-value never reaches exactly pi/2.