The asymptotes for the graph of the tangent function are vertical lines that occur regularly, each of them π, or 180 degrees, apart. They separate each piece of the tangent curve, or each complete cycle from the next.
This is because those points< every 180 degrees starting at 90, are where the cosine function is equal to 0.
Conversely an has an identity: tanθ=y/x=sinθ/cosθ. This means that we will have undefined/impossible situation when cosθ=0, that is, the denominator equals 0.