How to Find the Value of X in a Triangle: Formulas and Tips

Feb 16, 2026

Miles Hale

Finding the value of x in a triangle is one of the most basic geometry tasks. But depending on how much information is missing, it can be a challenge – even more so if geometry isn’t your thing. If you’d rather focus on other subjects, that’s perfectly fine. You can just use a good AI homework generator, and it’ll do all the heavy lifting for you.

However, if you’d like to at least try solving for x in a triangle yourself, why not? We’ll walk you through it and give you helpful step-by-step guidelines and formulas, both for when x stands for a side and an angle. Hopefully, our tips will help you complete your geometry homework and avoid common mistakes.

What can x represent in a triangle: Side or angle?

Before you answer the question of how to solve for x in a triangle, you first need to clarify what x stands for. X is a variable that represents an unknown value, and it can stand for either a side or an angle.

So, which one is it? It depends on the wording of the problem. Or, if you have a visual representation, x is typically written near the unknown value you’re expected to find. If it’s a side, x will normally be outside the triangle, right next to the side in question.

In contrast, when x is written inside an angle symbol (like ∠x), it likely represents the angle, so that’s what you’ll have to focus on.

X as the side of a right triangle vs. other triangles

Let’s say you’ve established that x represents a side of a triangle in the problem you need to solve. In such cases, it stands for length. So, the question you need to answer is, “How long is the unknown side of the triangle?” To answer it, you also need to know if the triangle is right.

- Right triangles (triangles with a 90° angle). If you have a right triangle, and x represents one of the sides, it can stand for one of the two legs or the hypotenuse. A hypotenuse is the longest side of a right triangle; it’s opposite the 90° angle.

- Non-right triangles. If you’re less lucky and your triangle isn’t right, finding the value of one of its sides will most likely be harder. Non-right triangles often need the Law of Sines or Cosines, which is way more challenging than simple Pythagorean calculations. Luckily, though, you can always turn to Geometry AI Solver for help.

X as the angle of any triangle

Now, let’s say your x represents an angle of a triangle. In that case, it stands for degrees rather than length. So, your answer will have the ° symbol, for example, 60° or 74°. You’re calculating the measure of the angle, meaning how wide it is.

A thing you need to know is that the angles of every triangle add up to 180°. If you know the measure of the other two angles, you’re looking at a simple arithmetic problem: 180° - the measure of 1st angle - the measure of the 2nd angle = x. For example, 180° - 76° - 50° = 54°.

As you can see, if you had to simply calculate the measure of the third angle knowing the other two, it wouldn’t even be geometry. That’s why, when you need to find x, and x stands for an angle, it’s because the problem involves more than just subtracting from 180°. You might need other triangle rules if the angles aren’t all given.

How to find the side of a triangle

Right triangles: To find the value of x in a right triangle, all you need is to know the Pythagorean theorem: the square of the hypotenuse equals the sum of the squares of the other two sides, or c² = a² + b². In this formula, c stands for the hypotenuse, and a and b represent the two shorter sides of the triangle.

For example, if the side legs of a triangle are 3 and 4, you’ll need to do the following to find the hypotenuse: 3² + 4² = 9 + 16 = 25; √25 = 5

Non-right triangles: Things are a little trickier for non-right triangles – you’ll need to know how to use the Law of Sines and Law of Cosines.

The Law of Sines relates sides to their opposite angles: sin(A)/a = sin(B)/b = sin(C)/c. In this formula, a, b, and c stand for the sides of the triangle, and A, B, and C for the angles opposite them. It’s useful when you know one side and two angles.

In turn, the Law of Cosines connects all three sides with one angle: c² = a² + b² - 2 * a * b * cos(C). It’ll help if you know two sides and the included angle.

How to find the angle of a triangle

As you already know, nothing is easier than finding the angle of a triangle when the other two are known. However, when you only know one other angle and the sides, you’ll once again need the Laws of Sines and Cosines.

When you know two sides and one opposite angle: In such cases, use a variation of the Law of Sines: A = arcsin((a * sin(B)) / b), where A is the unknown angle.

When you know all three sides or two sides with the included angle:
  1. Start with this formula: cos(C) = (a² + b² - c²) / (2 * a * b), where a and b stand for the sides surrounding angle C, and c is the side opposite it. This equation will give you the cosine of the unknown angle.
  2. Once you have cosC, you’ll need to find the angle itself by applying the inverse cosine function: C = arccos((a² + b² - c²) / (2 * a * b)). This way, you’ll convert the cosine value into degrees to get the actual measure of angle C.

These formulas might look scary, but the task is absolutely doable with some practice. If such equations send you into full-on panic, wait till you see how hard college statistics is. High school-level geometry is nothing in comparison.

Common mistakes when solving for x in a triangle

You’re now well-equipped to find the value of x in a triangle, regardless of whether x represents a side or an angle. To help you further, we’ve also compiled a list of common mistakes that struggling geometry students often make when trying to do the same thing you are.

You can use it as a checklist, especially when something isn’t adding up, but you don’t understand what you’re doing wrong:

  • Mixing up sides and angles
  • Incorrect use of the Pythagorean theorem (such as trying to apply it in non-right triangles)
  • Misunderstanding geometry terms – sides, hypotenuse, inverse cosine, etc.
  • Using the wrong trigonometric functions, for example, sine instead of cosine
  • Ignoring units, such as forgetting to convert angles between degrees and radians when necessary.

Finally, the best tip you’ll ever receive for almost any geometry task is to never skip the diagram. A quick sketch will help you notice things you would’ve otherwise missed and avoid basic mistakes.

Frequently asked questions

How to Find the Value of X in a Triangle | Sides and Angles