POV-Ray : Newsgroups : povray.general : bisecting circles - maths help please Server Time
16 Nov 2024 09:21:32 EST (-0500)
  bisecting circles - maths help please (Message 1 to 5 of 5)  
From: Tom Melly
Subject: bisecting circles - maths help please
Date: 2 Feb 2004 07:11:38
Message: <401e3e7a$1@news.povray.org>
See: http://www.uk.ccl.com/tom/bi_circ.gif for accompanying illustration.

Given a circle of radius r1 with a centre at <0,0,0>, how do I calculate the
radius (r2) and vertical displacement (h2) of a second circle, such that the two
circles bisect each other at y=0 with a particular height (h1) of the second
circle at its apex?

Hopefully the attached link will clear up any ambiguities in what I'm asking.

(I have to admit that the question has become slightly academic, since I've
accomplished roughly what I needed with two identical circles, and some scaling
of y on the second circle)

-- 
#macro A(V,B,C,R)#while(B-256)#if(V-128/B>=0)sphere{0,.5translate<C-4R-1,9>
pigment{rgb<1-C/8R/2C/8>}}#local V=V-128/B;#end#local B=B*2;#local C=C+1;#
end#end A(234,1,0,2)A(85,1,0,1)A(81,1,0,0)light_source{-5 1}//Tom Melly


Post a reply to this message

From: andrel
Subject: Re: bisecting circles - maths help please
Date: 2 Feb 2004 07:55:33
Message: <401E4880.1000800@hotmail.com>
I think your problem reduces to finding a circel through
three points <-r1,0> <r1,0> and <0,h1>
The standard way to solve that is taking two lines
through the middle of the lines and perpendicular to those
lines. In your case it is even more simple, just solve
where one of the lines cuts the y-axis:

<-r1/2,h1/2>+ c*<-h1,r1>=<0,h2>

this will give

c=1/2*r1/h1

and therefore

h2=-1/2*(h1-r1*r1/h1)

andrel

Tom Melly wrote:

> See: http://www.uk.ccl.com/tom/bi_circ.gif for accompanying illustration.
> 
> Given a circle of radius r1 with a centre at <0,0,0>, how do I calculate the
> radius (r2) and vertical displacement (h2) of a second circle, such that the two
> circles bisect each other at y=0 with a particular height (h1) of the second
> circle at its apex?
> 
> Hopefully the attached link will clear up any ambiguities in what I'm asking.
> 
> (I have to admit that the question has become slightly academic, since I've
> accomplished roughly what I needed with two identical circles, and some scaling
> of y on the second circle)
>


Post a reply to this message

From: andrel
Subject: Re: bisecting circles - maths help please
Date: 2 Feb 2004 08:09:08
Message: <401E4BAF.90203@hotmail.com>
another way to solve this:
for the 2nd circle with an origin an <0,-h2> to go through
<r1,0> ir must have a radius r2 of sqrt(r1^2+h2^2) and also
because it must go through <0,h1> of h1+h2
solving
r2^2 + h2^2 = (h1+h2)^2
will give you the answer.

andrel

Tom Melly wrote:

> See: http://www.uk.ccl.com/tom/bi_circ.gif for accompanying illustration.
> 
> Given a circle of radius r1 with a centre at <0,0,0>, how do I calculate the
> radius (r2) and vertical displacement (h2) of a second circle, such that the two
> circles bisect each other at y=0 with a particular height (h1) of the second
> circle at its apex?
> 
> Hopefully the attached link will clear up any ambiguities in what I'm asking.
> 
> (I have to admit that the question has become slightly academic, since I've
> accomplished roughly what I needed with two identical circles, and some scaling
> of y on the second circle)
>


Post a reply to this message

From: Phil Cook
Subject: Re: bisecting circles - maths help please
Date: 2 Feb 2004 12:29:19
Message: <opr2q6v1b8p4ukzs@news.povray.org>
On Mon, 2 Feb 2004 12:11:37 -0000, Tom Melly <tom### [at] tomandlucouk> wrote:

> See: http://www.uk.ccl.com/tom/bi_circ.gif for accompanying illustration.
>
> Given a circle of radius r1 with a centre at <0,0,0>, how do I calculate 
> the
> radius (r2) and vertical displacement (h2) of a second circle, such that 
> the two
> circles bisect each other at y=0 with a particular height (h1) of the 
> second
> circle at its apex?
>
> Hopefully the attached link will clear up any ambiguities in what I'm 
> asking.
>
> (I have to admit that the question has become slightly academic, since 
> I've
> accomplished roughly what I needed with two identical circles, and some 
> scaling
> of y on the second circle)
>

<code>
//All the Math

#declare x1=0;
#declare y1=-r1;
#declare x2=-h1;
#declare y2=0;
#declare x3=0;
#declare y3=-r1;

#declare ma=(y2-y1)/(x2-x1);
#declare mb=(y3-y2)/(x3-x2);

#declare myx=((ma*mb*(y1-y3))+(mb*(x1+x2))-(ma*(x2+x3)))/(2*(mb-ma));

#declare NewRadius=(h1)+myx;

</code>

Is the way I found to do it; finds the centre of the new circle from three 
points. You might want to check my math though:)

--
Phil

-- 
All thoughts and comments are my own unless otherwise stated and I am 
happy to be proven wrong.


Post a reply to this message

From: Slime
Subject: Re: bisecting circles - maths help please
Date: 2 Feb 2004 13:28:23
Message: <401e96c7$1@news.povray.org>
If you alter the drawing you provided slightly, the solution becomes
evident. Draw r1 horizontally from the origin to the right. Then draw r2
from the center of the larger circle to the same point (the right-hand
intersection of the larger circle with the x-axis). You can then see a right
triangle, and you can deduce that

r1^2 + h2^2 = r2^2

In addition, you can plainly see that h1 + h2 = r2.

You can use these two equations to solve first for h1 and then for r2.

 - Slime
 [ http://www.slimeland.com/ ]


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.