What is a rectangle?
A rectangle is a quadrilateral with four right angles. Its opposite sides are parallel and equal, and its two diagonals have the same length and bisect each other. A square is a special rectangle whose four sides are equal. The calculator uses length and width for the two distinct side measurements.
Rectangle formulas
How to calculate a rectangle’s area
Measure one side as the length and the adjacent side as the width, then multiply: A = L × W. For a 12 cm by 5 cm rectangle, A = 12 × 5 = 60 cm². Area is measured in square units because both dimensions are lengths.
How to find the perimeter
A rectangle has two sides of length L and two sides of width W. Add them to get P = L + W + L + W, which simplifies to P = 2(L + W). For sides 12 cm and 5 cm, P = 2(12 + 5) = 34 cm.
How to find a diagonal
A diagonal connects opposite corners. It forms a right triangle with the length and width as its legs, so the Pythagorean theorem gives d² = L² + W² and therefore d = √(L² + W²). For a 12-by-5 rectangle, d = √(144 + 25) = √169 = 13.
Worked example: a 12 cm by 5 cm rectangle
Area: A = 12 × 5 = 60 cm².
Perimeter: P = 2(12 + 5) = 34 cm.
Diagonal: d = √(12² + 5²) = √169 = 13 cm.
The diagonal check is exact, so the 5–12–13 right-triangle relationship confirms the dimensions.
Solving for missing sides
If area A and perimeter P are known, then L + W = P/2 and LW = A. Thus L and W solve t² − (P/2)t + A = 0. Real positive sides exist only when P² ≥ 16A, which is equivalent to the fact that among rectangles with a fixed perimeter, the square has the greatest area. If the diagonal d and one side s are known, the other side is √(d² − s²); this requires d > s.
Rectangle and square: what is the difference?
Every square is a rectangle because it has four right angles, but a rectangle does not need four equal sides. When L = W, the area becomes A = L², the perimeter becomes P = 4L, and the diagonal is d = L√2. The calculator identifies equal side lengths as a square while retaining the same general formulas.
Common mistakes
- Using perimeter units for area: perimeter is in units such as cm, while area is in cm².
- Adding the length and width without doubling the sum when finding perimeter.
- Adding side lengths instead of using the square-root formula for a diagonal.
- Mixing units; convert all lengths to the same unit before calculating.
- Entering an area-perimeter pair that cannot describe real positive sides.
Frequently asked questions
What is the formula for the area of a rectangle?
Multiply its length by its width: A = L × W. Use square units for the result.
How do you calculate a rectangle’s perimeter?
Use P = 2(L + W), or add all four sides. The result is in the same length unit as the sides.
How do I find the diagonal?
Use the Pythagorean theorem: d = √(L² + W²).
Can I find the side lengths from area and perimeter?
Yes. The sides have sum P/2 and product A. The calculator solves the resulting quadratic and checks that the values are real and positive.
Can a rectangle also be a square?
Yes. A square is a rectangle with equal length and width.
Does the diagonal divide a rectangle into equal parts?
It divides the rectangle into two congruent right triangles, each with half the rectangle’s area.