11102 - Moonshine

All about problems in Volume 111. If there is a thread about your problem, please use it. If not, create one with its number in the subject.

Moderator: Board moderators

jichen1234
New poster
Posts: 8
Joined: Fri May 20, 2005 5:53 pm

Post by jichen1234 »

Maybe we can discuss a simpler testcase

Input

Code: Select all

1 0 20 0 0 25
0 0 0 0 0 0
My output is

Code: Select all

3.45
This is a cone bottle with a 20-diameter circular base .
And the volume is about 301.760446

Can u tell me your output?

Erik
Learning poster
Posts: 67
Joined: Fri Jul 01, 2005 11:29 am
Location: Germany
Contact:

Post by Erik »

Hi,

my program outputs the wrong result 10 but that is because I consider it as an invalid testcase. A bottle should have rn>0.
Anyway, my algebra program tells the volume for s=3.45 is 119.8352061. I found s=5.1 to yield a volume of 301.7440301.

Maybe I make some fundamental error?

Cu, Erik

Erik
Learning poster
Posts: 67
Joined: Fri Jul 01, 2005 11:29 am
Location: Germany
Contact:

Post by Erik »

Hi,

I tested and found there are testcases with rn=0 in the input.
I have to take care of this.

Cu, Erik

Erik
Learning poster
Posts: 67
Joined: Fri Jul 01, 2005 11:29 am
Location: Germany
Contact:

Post by Erik »

Hi,

I now updated the program and it gives 5.10 as result. Anyway, still WA.

Cu, Erik :cry:

jichen1234
New poster
Posts: 8
Joined: Fri May 20, 2005 5:53 pm

Post by jichen1234 »

Erik wrote:Hi,

my program outputs the wrong result 10 but that is because I consider it as an invalid testcase. A bottle should have rn>0.
Anyway, my algebra program tells the volume for s=3.45 is 119.8352061. I found s=5.1 to yield a volume of 301.7440301.

Maybe I make some fundamental error?

Cu, Erik
mm, I think it's not accurate enough.
If s=5.11 instead of 5.10, what's the answer of the volume?

Erik
Learning poster
Posts: 67
Joined: Fri Jul 01, 2005 11:29 am
Location: Germany
Contact:

Post by Erik »

Hi,
If s=5.11 instead of 5.10, what's the answer of the volume?
This gives 303.1205174. So 5.10 is the correct answer I suppose.

Cu, Erik

jichen1234
New poster
Posts: 8
Joined: Fri May 20, 2005 5:53 pm

Post by jichen1234 »

How about the following testcase

Code: Select all

1 0 20 0 20 25
1 25 20 0 0 25
1 0 20 25 20 25
All are the same cylinder with 20-diameter base and 25 height filled with 1 deep water, which volume is 314.159265

I found s=1.67 and the volume is 314.159272

Erik
Learning poster
Posts: 67
Joined: Fri Jul 01, 2005 11:29 am
Location: Germany
Contact:

Post by Erik »

Hello,
I found s=1.67
Me to.

Could anyone who solved this task please give correct output for:

Code: Select all

0 10 20 5 5 25
1 10 20 5 5 25
2 10 20 5 5 25
3 10 20 5 5 25
4 10 20 5 5 25
5 10 20 5 5 25
6 10 20 5 5 25
7 10 20 5 5 25
8 10 20 5 5 25
9 10 20 5 5 25
10 10 20 5 5 25
11 10 20 5 5 25
12 10 20 5 5 25
13 10 20 5 5 25
14 10 20 5 5 25
15 10 20 5 5 25
16 10 20 5 5 25
17 10 20 5 5 25
18 10 20 5 5 25
19 10 20 5 5 25
20 10 20 5 5 25
21 10 20 5 5 25
22 10 20 5 5 25
23 10 20 5 5 25
24 10 20 5 5 25
25 10 20 5 5 25
0 0 0 0 0 0
Cu, Erik :)

mf
Guru
Posts: 1244
Joined: Mon Feb 28, 2005 4:51 am
Location: Zürich, Switzerland
Contact:

Post by mf »

My accepted program outputs this:

Code: Select all

0.00
2.85
4.41
5.69
6.82
7.85
8.79
9.69
10.59
11.50
12.46
13.44
14.35
15.17
15.92
16.59
17.18
17.69
18.11
18.43
18.65
18.83
19.03
19.26
19.53
20.00

Erik
Learning poster
Posts: 67
Joined: Fri Jul 01, 2005 11:29 am
Location: Germany
Contact:

Post by Erik »

Thanks mf!

I've got the same outputs, but still WA.
Maybe it's all about precision?

Here another set:

Code: Select all

0.0 0.5 47.634 0 11.54 0.6
0.1 0.5 47.634 0 11.54 0.6
0.2 0.5 47.634 0 11.54 0.6
0.3 0.5 47.634 0 11.54 0.6
0.4 0.5 47.634 0 11.54 0.6
0.5 0.5 47.634 0 11.54 0.6
0.51 0.5 47.634 0 11.54 0.6
0.52 0.5 47.634 0 11.54 0.6
0.55 0.5 47.634 0 11.54 0.6
0.58 0.5 47.634 0 11.54 0.6
0.59 0.5 47.634 0 11.54 0.6
0.595 0.5 47.634 0 11.54 0.6
0.598 0.5 47.634 0 11.54 0.6
0.599 0.5 47.634 0 11.54 0.6
0.5995 0.5 47.634 0 11.54 0.6
0.5999 0.5 47.634 0 11.54 0.6
0.59995 0.5 47.634 0 11.54 0.6
0.6 0.5 47.634 0 11.54 0.6
0 0 0 0 0 0
My Output:

Code: Select all

0.00
11.70
19.01
25.70
32.62
41.01
42.00
42.91
45.17
46.77
47.18
47.37
47.50
47.55
47.58
47.62
47.62
47.63
Cu, Erik :)

mf
Guru
Posts: 1244
Joined: Mon Feb 28, 2005 4:51 am
Location: Zürich, Switzerland
Contact:

Post by mf »

My output is the same as yours.

If you are really desperate, try to search for input/output data for this problem on Waterloo's site.

Erik
Learning poster
Posts: 67
Joined: Fri Jul 01, 2005 11:29 am
Location: Germany
Contact:

Post by Erik »

Hi,

I checked out input from Waterloo and my program gave same results.
That's really frustrating now.

Erik

Erik
Learning poster
Posts: 67
Joined: Fri Jul 01, 2005 11:29 am
Location: Germany
Contact:

Post by Erik »

Hi,

:P YIPPIE! :P

Finally I got AC. It turned out to be a problem in the calculation because to large intermediate values. I realized this in one instance but forgot there is another part it can occur.

Cu, Erik :)

Post Reply

Return to “Volume 111 (11100-11199)”