Cotangent Calculator
Enter an angle in degrees or radians to find its cotangent, cot θ.
Updated
Cotangent Calculator
Our Cotangent Calculator finds cot θ for any angle in degrees or radians. Type the angle and the answer appears straight away to 10 decimal places, with the exact value for special angles (such as √3 for 30°), the angle in the other unit, the quadrant, and sin θ and cos θ. It tells you clearly when the cotangent is undefined, at 0°, 180° and similar angles, and it gives cot 90° as exactly 0 rather than the 6.12 × 10⁻¹⁷ many programs show.
Quick answer
The cotangent of an angle is the reciprocal of the tangent: the adjacent side divided by the opposite side, or cos θ ÷ sin θ. For example, cot 45° = 1. Enter any angle above and the calculator shows cot θ instantly.
- Formula: cot θ = 1 ÷ tan θ = cos θ ÷ sin θ = adjacent ÷ opposite
- Key values: cot 30° ≈ 1.7321, cot 45° = 1, cot 60° ≈ 0.5774, cot 90° = 0
- Undefined: at 0°, 180° and every multiple of 180°, where sin θ = 0
- Range and period: any real number, repeating every 180° (π)
What Is Cotangent?
Cotangent is one of the three reciprocal trigonometric functions, with secant and cosecant. It flips the tangent upside down, so in a right triangle it compares the side next to the angle with the side opposite it:
cot θ = cos θ ÷ sin θ
cot θ = 1 ÷ tan θ
tan θ = opposite ÷ adjacent
Because cotangent divides by sin θ, it has no value where sin θ = 0. Like tangent, it is not limited to −1 to 1: it can be any real number, getting huge near 0° and 180°. The name comes from “complement’s tangent”: cot θ = tan(90° − θ).
Cotangent Table of Common Angles
| Angle | Exact | Decimal |
|---|---|---|
| 0° (0) | undefined | undefined |
| 30° (π/6) | √3 | 1.7321 |
| 45° (π/4) | 1 | 1 |
| 60° (π/3) | √3/3 | 0.5774 |
| 90° (π/2) | 0 | 0 |
| 120° (2π/3) | −√3/3 | −0.5774 |
| 135° (3π/4) | −1 | −1 |
| 150° (5π/6) | −√3 | −1.7321 |
| 180° (π) | undefined | undefined |
The cotangent column is the tangent column read backwards: the cotangent of an angle equals the tangent of its complement, so cot 30° = tan 60° = √3.
The Cotangent Graph
- Period: the curve repeats every 180° (π radians).
- Asymptotes: vertical lines at 0°, 180°, 360° and every multiple of 180°, where cot θ is undefined.
- Zeros: cot θ = 0 at 90°, 270° and every 90° + k × 180°.
- Always falling: between two asymptotes the curve drops from +∞ to −∞, the opposite of tangent.
- Odd function: cot(−θ) = −cot θ.
Cotangent Rules and Identities
- Reciprocal: cot θ = 1 ÷ tan θ, wherever tan θ is defined and not 0.
- Quotient: cot θ = cos θ ÷ sin θ.
- Pythagorean: 1 + cot2θ = csc2θ.
- Complement: cot(90° − θ) = tan θ.
- Negative angle: cot(−θ) = −cot θ.
- Half turn: cot(θ + 180°) = cot θ.
- Calculus: the derivative of cot θ is −csc2θ.
Worked Examples
Exact value of cot 60°.
= (1/2) ÷ (√3/2)
= 1/√3 = √3/3
≈ 0.5774
Length of a shadow. A 10 m pole stands in sunlight coming in at 40° above the horizon. Its shadow is the side next to the angle:
= 10 × 1.1918
≈ 11.92 m
Radian inputs. cot(1) ≈ 0.6421, cot(2) ≈ −0.4577, cot(3) ≈ −7.0153 and cot(4) ≈ 0.8637. 3 radians is close to π (180°), where sin θ is nearly 0, so the cotangent is large.
Cotangent in Excel and Code
| Tool | cot 60° |
|---|---|
| Excel / Google Sheets | =COT(RADIANS(60)) |
| Older Excel | =1/TAN(RADIANS(60)) |
| Python | 1 / math.tan(math.radians(60)) |
| JavaScript | 1 / Math.tan(60 * Math.PI / 180) |
| Scientific calculator | DEG mode, tan 60, then 1/x |
Python and JavaScript have no built-in cotangent. 1 / tan(x) returns about 6.12 × 10−17 at 90° instead of 0 and 1.0000000000000002 at 45°; using cos(x) / sin(x) is slightly more robust. All of these expect radians.
Common Mistakes
- Confusing cot with tan⁻¹. cot θ = 1 ÷ tan θ; tan−1 (arctan) returns an angle.
- Calling cot 90° undefined. It is 0, because cos 90° ÷ sin 90° = 0 ÷ 1.
- Forgetting cot 0° is undefined. sin 0° = 0, so there is no value.
- Wrong angle mode. cot 60 is about 0.5774 in degrees but about 3.1246 in radians.
- Swapping the sides. Cotangent is adjacent ÷ opposite; opposite ÷ adjacent is the tangent.
Key Terms
- Adjacent
- The side next to θ that is not the hypotenuse.
- Opposite
- The side across from the angle θ.
- Reciprocal
- 1 divided by a value; cotangent is the reciprocal of tangent.
- Asymptote
- A line the graph approaches but never reaches; cotangent has them at multiples of 180°.
- Cosecant
- The reciprocal of sine, csc θ = 1 ÷ sin θ.
- Arccot
- The inverse of cotangent, written cot⁻¹ or acot.
How to Use the Cotangent Calculator
- Enter the angle. Type the angle θ, for example 60, or press one of the angle buttons (30°, 45°, 60° and 90° in degrees, π/6, π/4, π/3 and π/2 in radians). In radians you can type a decimal such as 1 or a multiple of π such as pi/3 or 3π/4.
- Choose degrees or radians. Pick Degrees (°) or Radians (rad). Typing 60° or 1 rad also sets the unit for that angle.
- Read and copy the result. cot θ appears as you type, to 10 decimal places, with the exact value where there is one (for example cot(30°) = √3 ≈ 1.7320508076). The table below shows the angle in the other unit, the quadrant, sin θ and cos θ. At 0°, 180° and similar angles the cotangent is undefined and the calculator says so. Press Copy to copy the result, or Clear or Esc to start again.
Example: enter 135 in degrees and the result is −1, with the note that 135° is in quadrant II with a reference angle of 45°, and 135° = 3π/4 rad.
Who Can Use This Calculator?
Frequently Asked Questions (FAQs)
What is the cotangent of an angle?
The cotangent is the reciprocal of the tangent: cot θ = 1 ÷ tan θ = cos θ ÷ sin θ. In a right triangle it is the side next to the angle divided by the side opposite it: cot θ = adjacent ÷ opposite. For example cot 45° = 1 and cot 30° = √3 ≈ 1.7321.
What is cot 30°, cot 45°, cot 60° and cot 90°?
cot 30° = √3 ≈ 1.7321, cot 45° = 1, cot 60° = √3/3 ≈ 0.5774 and cot 90° = 0. cot 0° is undefined, because sin 0° = 0.
Why is cot 0° undefined?
cot θ = cos θ ÷ sin θ, and sin 0° = 0, so cot 0° would mean dividing 1 by 0. As θ gets close to 0° the cotangent grows without limit (cot 0.1° ≈ 573). The same happens at 180°, 360° and every multiple of 180°, where the graph has vertical asymptotes.
Is cot 90° zero or undefined?
cot 90° is exactly 0, because cos 90° = 0 and sin 90° = 1, so cos ÷ sin = 0 ÷ 1 = 0. Writing it as 1 ÷ tan 90° suggests it is undefined, but that only shows that the reciprocal form breaks down there; cos ÷ sin gives the correct value.
Is cotangent the same as tan⁻¹?
No. cot θ = 1 ÷ tan θ is the reciprocal of tangent. tan−1(x), or arctan, is the inverse function that returns an angle: tan−1(1) = 45°, while cot 45° = 1 and cot 60° ≈ 0.5774.
When is cotangent negative?
Cotangent has the same sign as tangent: positive in quadrants I and III, negative in quadrants II and IV. For example cot 120° ≈ −0.5774 and cot 135° = −1.
What is the period of cotangent?
180°, or π radians. Adding 180° gives the same value: cot 225° = cot 45° = 1.
How do you calculate cot on a calculator or in Excel?
Most calculators have no cot key, so work out 1 ÷ tan θ. In Excel use =COT(RADIANS(60)) or =1/TAN(RADIANS(60)), both about 0.5774. In code use 1 / Math.tan(x) in JavaScript or 1 / math.tan(x) in Python, with x in radians; at 90° these give about 6.12 × 10−17 instead of 0, so cos(x) / sin(x) is the safer formula.
What is cotangent used for?
It turns up wherever you divide the horizontal side by the vertical one: the run of a roof for each unit of rise, the length of a shadow (shadow = height × cot of the sun’s elevation), and in calculus, where the derivative of cot θ is −csc2θ and the integral of cot θ is ln|sin θ| + C.
Is the Cotangent Calculator free?
Yes. It is completely free, needs no sign-up, and can be used as many times as you like.
Try our Cotangent Calculator to find cot θ for any angle in degrees or radians instantly.