# Easy Rectangle

talzamir
Posers and Puzzles 10 Mar '14 20:17
1. talzamir
Art, not a Toil
10 Mar '14 20:17
This is trivial enough, but I'll probably use it in a high school someday.

A rectangle has circumference length of p. The diagonal has length d. What is the area of the rectangle?
2. joe shmo
Strange Egg
11 Mar '14 21:233 edits
Originally posted by talzamir
This is trivial enough, but I'll probably use it in a high school someday.

A rectangle has circumference length of p. The diagonal has length d. What is the area of the rectangle?
I don't know if I did this the hard way, because it didn't seem obvious to me...

Let the sides of the rectangle be x, and y respectively.

Perimeter = P = 2*x + 2*y ....eq (1)

from the Pythagorean theorem

d² = x² + y² ...eq(2)

from eq(1)

y = 1/2*P - x ...eq(1)'

from eq(2)

y = Sqrt ( d² - x² )

Set eq(1)' = eq(2)

1/2*P - x = Sqrt ( d² - x² )

solve for x in terms of d, and P by completing the square

x = Sqrt(d²/2 - 1/16*P² ) + P/4 ...eq(3)

Sub eq(3) into eq(1)'

y = 1/2*P - [Sqrt(d²/2 - 1/16*P² ) + P/4]

= 1/4*P - Sqrt(d²/2 - 1/16*P² )

then Area = A = x*y

= (P/4 + Sqrt(d²/2 - 1/16*P² ))(P/4 - Sqrt(d²/2 - 1/16*P² ))

which is of the form (a + b)(a - b) = a² - b² : giving after simplification

A = P²/8 - d²/2 ***
3. 11 Mar '14 22:462 edits
Originally posted by joe shmo
Let the sides of the rectangle be x, and y respectively.

Perimeter = P = 2*x + 2*y ....eq (1)

from the Pythagorean theorem

d² = x² + y² ...eq(2)
What you did works well.

Starting with what I have quoted above there is a neat trick which avoids needing to complete the square.

If you square both sides of eq(1) you get something that involves a multiple of x² + y² (which is d² ) and a multiple of xy (which is the area we want).

Then rearrange to get your result.
4. joe shmo
Strange Egg
11 Mar '14 23:14
Originally posted by Diapason
What you did works well.

Starting with what I have quoted above there is a neat trick which avoids needing to complete the square.

If you square both sides of eq(1) you get something that involves a multiple of x² + y² (which is d² ) and a multiple of xy (which is the area we want).

Then rearrange to get your result.
Wish I would have saw that,...by far less work!
5. talzamir
Art, not a Toil
12 Mar '14 07:33
Nicely done. And the squaring trick is what I was thinking too. ๐

2x + 2y = p => x + y = p/2 => x^2 + 2xy + y^2 = p^2/4

x^2 + y^2 = d^2

combine for p^2/4 + 2xy = d^2 => xy = d^2/2 - p^2/8 = A
6. sonhouse
Fast and Curious
21 Mar '14 11:422 edits
Originally posted by talzamir
Nicely done. And the squaring trick is what I was thinking too. ๐

2x + 2y = p => x + y = p/2 => x^2 + 2xy + y^2 = p^2/4

x^2 + y^2 = d^2

combine for p^2/4 + 2xy = d^2 => xy = d^2/2 - p^2/8 = A
It's funny, the first numbers I chose showed me something about rectangles:

I chose d=10 and p=20 where A = zero๐

which makes sense๐

It also means you can get negative numbers: D=10 and P=22, A = minus 60.5)

How can you fix it so that doesn't happen?

Exploding ink?๐
7. joe shmo
Strange Egg
21 Mar '14 22:121 edit
Originally posted by sonhouse
It's funny, the first numbers I chose showed me something about rectangles:

I chose d=10 and p=20 where A = zero๐

which makes sense๐

It also means you can get negative numbers: D=10 and P=22, A = minus 60.5)

How can you fix it so that doesn't happen?

Exploding ink?๐
You happened to pick your variables outside of the domain of the equation.

In order for the equation to give valid results ( that is results that are physical ) the area of the rectangle must be strictly greater than zero. For if it were equal to zero, you don't have a rectangle.

So;

A > 0

P²/8 - d²/2 > 0

P²/8 > d²/2

P² > 4*d²

P > 2*d (this is the domain of the equation), which say that all perimeters must be greater than twice the diagonal.

You picked a perimeter that was exactly equal to twice the diagonal, which is out of the equations domain. See?
8. sonhouse
Fast and Curious
22 Mar '14 01:29
Originally posted by joe shmo
You happened to pick your variables outside of the domain of the equation.

In order for the equation to give valid results ( that is results that are physical ) the area of the rectangle must be strictly greater than zero. For if it were equal to zero, you don't have a rectangle.

So;

A > 0

P²/8 - d²/2 > 0

P²/8 > d²/2

P² > 4*d²

P > 2*d ...[text shortened]... imeter that was exactly equal to twice the diagonal, which is out of the equations domain. See?
I knew that, just pulling your chain๐