# square incribed in cricle

• Feb 5th 2009, 08:00 AM
square inscribed in circle
I have a problem here that I haven't been able to solve.
You're given a circle with radius r and a square is inscribed on it.
The center of the circle is at the origin and the edges of the square do not lie on coordinate axis. Given co-ordinates (x1,y1), tell whether the co-ordinates lie on any side of the square.
I hope my question is clear.
• Feb 5th 2009, 08:20 AM
I see you are a newbie very warm Welcome to the Forum :)

Hint: There can be infinite squares in a circle
• Feb 5th 2009, 08:52 AM
star_tenshi
Quote:

I have a problem here that I haven't been able to solve.
You're given a circle with radius r and a square is inscribed on it.
The center of the circle is at the origin and the edges of the square do not lie on coordinate axis. Given co-ordinates (x1,y1), tell whether the co-ordinates lie on any side of the square.
I hope my question is clear.

This is my interpretation of your question:
http://fc78.deviantart.com/fs40/f/20...e101d61f3b.jpg
since we know that it is a square inscribed in a circle centered at the origin, then $\theta = 45 degrees = \frac{\pi}{4}$. Thus x & y can be calculated:
$x = r \cdot cos\theta = r \cdot cos\frac{\pi}{4}$

$y = r \cdot sin\theta = r \cdot sin\frac{\pi}{4}$
$\Rightarrow x = y$

So any coordinate with either the x or y coordinates equation to $r \cdot cos\frac{\pi}{4}$ or $r \cdot sin\frac{\pi}{4}$ would lie on the edges of the square.

Hope it helps!
• Feb 5th 2009, 08:56 AM
star_tenshi
Please excuse my previous post. I looked at ADARSH's post and realized my mistake. There are infinitely many squares inscribed in a circle. I was just looking at a particular case.
• Feb 5th 2009, 09:35 AM
Soroban

I don't know what you're asking, but I'll take a guess.

Quote:

You're given a circle with radius r and a square is inscribed on it.
The center of the circle is at the origin.
Given co-ordinates (x1,y1) of one vertex, locate the other vertices.

Code:

                Y                 |               * * *           *    |    * P         * - - - + - - - o(x1,y1)       *|      |    * |*         |      |  r*  |       * |      | * θ  | *   - - * | - - - + - - - | * - - X       * |      O|      | *         |      |      |       *|      |      | *         * - - - + - - - *           *    |    *               * * *                 |

The coordinates of the one vertex is: . $P(x_1,y_1)$

$\text{Let }r\, = \,\text{distance }OP.$
$\text{Let }\theta \,=\,\angle POX,\,\text{ where }\tan\theta \,=\,\frac{y_1}{x_1}$

Then $P$ has coordinates: . $\left(r\cos\theta,\:r\sin\theta\right)$

The four vertices are: . $\bigg[r\cos\!\left(\theta + \frac{\pi}{2}n\right),\: r\sin\!\left(\theta + \frac{\pi}{2}n\right)\bigg]\;\text{ for }n = 0,1,2,3$

• Feb 5th 2009, 01:44 PM
Thanks for the replies. I tried to use it to solve the problem but unfortunately it didn't work out.
I'll try to tell the question here.

There is a circular island of radius r (centered at origin). The owner wants to build a square tower inscribed on it. Given two points E1 (x1,y1) and E2 (x2,y2) for entrance and exit, is it possible to build a tower such that the two points (E1 and E2) lie on the tower's foundation ?

Hopefully, it made more sense this time around.
• Feb 6th 2009, 02:30 AM
From your reply it seems either you are hesitating to give complete question or question is wrong(Worried)

If its first case - Dont worry we are not gonna spoon feed you(Shake)

• Feb 6th 2009, 04:57 AM
I just rephrased the question. I removed the unnecessary parts. If you guys are still having trouble understanding it, I'll post the original one.
• Feb 6th 2009, 06:21 AM
The square will have diameter 2r
So
$\sqrt{2r^2}= \text{side of square}$

Now ther can be infinite such squares(after rotating)
Locus of all such squares is a circle of radius equal to half the side of square ie; $\frac{r}{\sqrt{2}}$
• Feb 6th 2009, 07:17 AM
I'm not sure how to apply that.

I'll give an example.
r = 2
(x1,y1) = 1,1
(x2,y2) = 1,-1

You get this by taking the vertices of the square as A(2,0), B(0,2), C(-2,0), D(0,-2). The points (1,1) and (1,-1) lie on lines AB and AD respectively.
• Feb 6th 2009, 07:34 AM
earboth
Quote:

I'm not sure how to apply that.

I'll give an example.
r = 2
(x1,y1) = 1,1
(x2,y2) = 1,-1

You get this by taking the vertices of the square as A(2,0), B(0,2), C(-2,0), D(0,-2). The points (1,1) and (1,-1) lie on lines AB and AD respectively.

I've attached a sketch.

You easily can determine the area where the points $E_1$ and $E_2$ must be located so that the condition is satisfied.
• Feb 6th 2009, 02:36 PM
I'm sorry but I still didn't get it. How do you get the area where E1 and E2 must be located ?
• Feb 6th 2009, 11:31 PM
-(Wait)Since you didn't specify the real values of points to be checked we took it as (x,y)

- Since the square could be rotated we rotated it and hence(as in earboth's figure) every point of that area got included

-the mid point of a square inscribed in a circle is the point nearest to it

-Joining the midpoints of a particular side of a rotating square square we get a cicle of radius $\frac{r}{\sqrt{2}}$

- All points in the area between these two circles can be called E1 and E2
ie; $r^2 \ge x^2 +y^2 \ge \frac{r^2}{2}$

Every (x,y) satisfying above is your answer (except those for which either is 0)
• Feb 7th 2009, 05:51 AM
{"found_math": true, "script_math_tex": 0, "script_math_asciimath": 0, "math_annotations": 0, "math_alttext": 0, "mathml": 0, "mathjax_tag": 0, "mathjax_inline_tex": 0, "mathjax_display_tex": 0, "mathjax_asciimath": 1, "img_math": 0, "codecogs_latex": 18, "wp_latex": 0, "mimetex.cgi": 0, "/images/math/codecogs": 0, "mathtex.cgi": 0, "katex": 0, "math-container": 0, "wp-katex-eq": 0, "align": 0, "equation": 0, "x-ck12": 0, "texerror": 0, "url": "http://mathhelpforum.com/geometry/71953-square-incribed-cricle-print.html", "fetch_time": 1508487588000000000, "content_mime_type": "text/html", "warc_filename": "crawl-data/CC-MAIN-2017-43/segments/1508187823839.40/warc/CC-MAIN-20171020063725-20171020083725-00714.warc.gz", "warc_record_offset": 222301249, "warc_record_length": 5385, "token_count": 1700, "char_count": 5404, "score": 4.1875, "int_score": 4, "crawl": "CC-MAIN-2017-43", "snapshot_type": "longest", "language": "en", "language_score": 0.9139564633369446, "file_path": "/sailhome/yjruan/project/latent-lm/data/processed/finemath-4plus/finemath-4plus/train-00045-of-00064.parquet"}