All about flooble | fun stuff | Get a free chatterbox | Free JavaScript | Avatars
 perplexus dot info

 Shifted regions (Posted on 2019-02-27)
A circle is centered at the origin with a radius of 5. Two lines are drawn that divide the circle into four regions, the first is the line y=-1, and the other is x=-3. Find the area of the largest region.

 No Solution Yet Submitted by Danish Ahmed Khan No Rating

Comments: ( Back to comment list | You must be logged in to post comments.)
 solution - math and computer | Comment 3 of 4 |
I finally fixed the trig. in my original posting and finished the puzzle as I had started it, and all the work is documented in that post. Bottom line:

A=41.645

I wrote two codes: One to produce the analytic solution I give, and a second using a simulation to check the result. They agree.

Perhaps where Charlie went wrong was approximating half sections using triangles.

Analytic Solution

rabbit-3:~ lord\$ sec

region area =    41.6451340

rabbit-3:~ lord\$ more sec.f

program sec

implicit none

real pi,as1,as3,area,R,a2,a4,

1 t1,t2,a,b,areatot,ang1,ang2

pi = 3.14159

R=5

areatot=pi*25

a=1

b=3

t1=2*acos(a/R)

t2=2*acos(b/R)

as1 = (1/4.)*R**2*(pi-t1+sin(t1))

as3 = (1/4.)*R**2*(pi-t2+sin(t2))

a2 = (1/4.)*areatot

a4 = 3

area = as1 + a2 + as3 + a4

print*,' region area = ',area

end

Simulation Solution

rabbit-3:~ lord\$ sector

41.6415939

41.6478386

41.6486015

41.6469307

41.6471672

41.6396904

41.6485176

41.6417007

41.6469078

41.6474457

ave    41.6456413

rabbit-3:~ lord\$ more sector.f

program sector

implicit none

integer iseed,i,j,totc,tots

real xx,yy,areac,areas,r2,ave

ave=0

do j=1,10

iseed=time8()

call srand(iseed)

totc=0

tots=0

do i=1,10**8

1               xx=10*rand()-5

yy=10*rand()-5

r2=xx**2+yy**2

if(r2.gt.25)go to 1

totc=totc+1

if(xx.ge.-3..and.yy.ge.-1.)tots=tots+1

enddo

areac=3.14159*25

areas=(1.*tots/totc)*areac

print*,areas

ave=ave+areas

enddo

ave=ave/10

print*,'ave ',ave

end

Edited on February 28, 2019, 11:40 am
 Posted by Steven Lord on 2019-02-28 11:20:57

Please log in:
 Login: Password: Remember me: Sign up! | Forgot password

 Search: Search body:
Forums (0)
Newest Problems
Random Problem
FAQ | About This Site
Site Statistics
New Comments (5)
Unsolved Problems
Top Rated Problems
This month's top
Most Commented On

Chatterbox:
Copyright © 2002 - 2020 by Animus Pactum Consulting. All rights reserved. Privacy Information