So we have to graph the function:
First is important to note that the cotangent can be defined by the quotient between the cosine and the sine:
By looking at this new expression we can infer a few things about the graph. First of all, we have a sine in the denominator which means that the denominator can be equal to 0. Let's assume that the denominator is 0 at x=a. Then the graph has a vertical asymptote at x=a. What's more, the sine is a periodic funtion that is equal to zero for an infinite amount of x values so the graph of the cotangent has infinite vertical asymptotes. The good part is that we just need to graph one full period and in the case of the cotangent one full period is completed between two consecutive vertical asymptote. So basically we have to find two consecutive vertical asymptote and graph the function between them.
So let's begin by finding two x values that makes the denominator equal to 0. The sine is equal to 0 when its argument is equal to 0 and the next value at which the sine is equal to zero is pi so:
Then we can construct two equations:
The equations are:
We can substract π/6 from both sides of both equations:
So we have a vertical asymptote at x=-π/6 and another one at x=5π/6. This means that we just need to graph f(x) between these two vertical lines. It is also important to note that f(x) reaches positive or negative values when the value of x approaches to -π/6 or 5π/6.
Now that we have the asymptotes let's find the x-intercept i.e. the point where f(x) meets with the x-axis. This happens when f(x)=0 which happens when the numerator is equal to 0. Then we get:
The cosine is equal to zero at π/2 so we have:
We can substract π/6 from both sides:
So the x-intercept is located at x=π/3. So for now we have the x-intercept and two vertical asymptotes so at the moment we have the following:
The black dot is the x-intercept at (π/3,0) and the dashed lines are the asymptotes. Our function passes through the black dot and is limited by the asymptotes.
We still need to find if it reaches positive or negative infinite values when approaching to the asymptotes. As we saw the function is equal to zero at x=π/3. This means that between the first asymptote and x=π/3 the function is either entirely positive or entirely negative. The same happens with the interval between x=π/3 and the second asymptote. So we have two intervals where the function mantains its sign: (-π/6,π/3) and (π/3,5π/6). Let's evaluate f(x) in one value of each interval and see if it's positive or negative there. For example, x=0 is inside the first interval and x=2 is inside the second interval:
So f(x) is positive at (-π/6,π/3) which means that as x approaches to -π/6 from the right it reaches positive infinite values. We also have that f(x) is negative at (π/3,5π/6) so as x approaches 5π/6 from the left the function reaches negative infinite values.
Using this information and the fact that the graph must pass throug the x-intercept we can graph the function. It should look like this:
And that's the graph of f(x).