Problem 180

A place to air possible concerns or difficulties in understanding ProjectEuler problems. This forum is not meant to publish solutions. This forum is NOT meant to discuss solution methods or giving hints how a problem can be solved.
Forum rules
As your posts will be visible to the general public you are requested to be thoughtful in not posting anything that might explicitly give away how to solve a particular problem.

This forum is NOT meant to discuss solution methods for a problem.

In particular don't post any code fragments or results.

Don't start begging others to give partial answers to problems

Don't ask for hints how to solve a problem

Don't start a new topic for a problem if there already exists one


See also the topics:
Don't post any spoilers
Comments, questions and clarifications about PE problems.
User avatar
ed_r
Posts: 1009
Joined: Sun Jul 29, 2007 10:57 am

P180 clarification

Post by ed_r »

Does n have to be a positive integer?

For example, is this a valid solution: x=[frac]1,2[/frac], y=[frac]1,3[/frac], z=[frac]1,5[/frac], n=-1 ?

 
!647 = &8FDF4C
Robert_Gerbicz
Posts: 26
Joined: Sat Oct 13, 2007 2:44 pm

Re: P180 clarification

Post by Robert_Gerbicz »

Yes, n can be negative value!

And don't forget the crazy problem statement: "the sum of all distinct s(x,y,z)" so if another triplet gives you the same s(x,y,z)=x+y+z value
then add only once.
User avatar
ed_r
Posts: 1009
Joined: Sun Jul 29, 2007 10:57 am

Re: P180 clarification

Post by ed_r »

*Groan* ... and here's me hoping I wouldn't have to treat the n<0 cases specially.

Summing all those s values for n<0 is going to be a challenge ... :?

Out of interest, dev team, what "Raymond score" did you tentatively assign to this one?
!647 = &8FDF4C
User avatar
hk
Administrator
Posts: 12832
Joined: Sun Mar 26, 2006 10:34 am
Location: Haren, Netherlands

Re: P180 clarification

Post by hk »

ed_r wrote: Out of interest, dev team, what "Raymond score" did you tentatively assign to this one?
very tentatively: 5

to clarify:
1,2,3: easy
4,5,6: medium
7,8.9: hard
Image
War ruins the life and health of untold numbers of innocent children.
User avatar
ed_r
Posts: 1009
Joined: Sun Jul 29, 2007 10:57 am

Re: P180 clarification

Post by ed_r »

Holy **** ! I'm doing something wrong, obviously. Will look again this evening when I've more time.
!647 = &8FDF4C
User avatar
arif
Posts: 111
Joined: Tue Oct 09, 2007 4:35 am
Location: Lahore, Pakistan

Re: P180 clarification

Post by arif »

Who is Raymond?
The i-th root of i = 4.810477381
User avatar
daniel.is.fischer
Posts: 2400
Joined: Sun Sep 02, 2007 11:15 pm
Location: Bremen, Germany

Re: P180 clarification

Post by daniel.is.fischer »

Raymond is rayfil, he had the idea to give the problems an estimated difficuty score, so we can better judge which problem to publish when. However, the solvers don't always conform to our estimate :)
Il faut respecter la montagne -- c'est pourquoi les gypa&egrave;tes sont l&agrave;.
User avatar
stijn263
Posts: 1505
Joined: Sat Sep 15, 2007 11:57 pm
Location: Netherlands

Re: P180 clarification

Post by stijn263 »

What about adding a poll to every (new) problems' forum asking solvers how difficult they'd rate the problem?

That should give developers a better understanding of what subjects are percieved to be difficult by the average PE user :)
User avatar
Oakenshield
Posts: 8
Joined: Sat Feb 16, 2008 10:11 pm
Location: Lyon, France
Contact:

Re: P180 clarification

Post by Oakenshield »

Hi everyone,

I thought that I had solved this difficult and beautiful problem but it's not the case ! I was a bit disappointed and surpressed because my analyze is based on some powerful theorem... :)

I've made a lot of checks, I can't see what's wrong, I'm sure of my answer... I've found that with k=10 (and not 35), the solution would be 12519... Is this correct ? Can anyone give me a suggestion to find my error(s) ?

Thanks a lot !
User avatar
daniel.is.fischer
Posts: 2400
Joined: Sun Sep 02, 2007 11:15 pm
Location: Bremen, Germany

Re: P180 clarification

Post by daniel.is.fischer »

Your value for k = 10 is correct. Can't say what your problem is without knowing what you do. Perhaps if you PMed me an outline of your approach, I could give a hint.
Il faut respecter la montagne -- c'est pourquoi les gypa&egrave;tes sont l&agrave;.
axelbrz
Posts: 51
Joined: Mon Sep 08, 2008 5:34 am

Problem 180

Post by axelbrz »

Hi, I have two questions:

1) if (a, b, c) is a golden triple of order k. (b, a, c) is a different golden triple, right? Or is it different?

Because fn(a, b, c) = fn(b, a, c) for all a, b, c, n,


2) Can n be zero or negative?

Thanks!
"think(O(n))+O(n) sometimes is better than think(O(1))+O(1)"

Image
User avatar
jaap
Posts: 588
Joined: Tue Mar 25, 2008 3:57 pm
Contact:

Re: Problem 180

Post by jaap »

1. Would the answer to the problem be any different?
2. Yes.
axelbrz
Posts: 51
Joined: Mon Sep 08, 2008 5:34 am

Re: Problem 180

Post by axelbrz »

Oh, sorry, you're right! s(x, y, z) = s(y, x, z) so it will be added once to t.

Thanks!
Last edited by axelbrz on Mon Nov 24, 2008 2:40 am, edited 1 time in total.
"think(O(n))+O(n) sometimes is better than think(O(1))+O(1)"

Image
User avatar
DNS
Posts: 30
Joined: Thu Oct 16, 2008 9:32 am
Location: Ukraine, Nikolaev

Re: Problem 180

Post by DNS »

I have no more ideas. Can somebody give me a hint?
For k=10 I obtain the set with 71 different s(x,y,z) varied from 2/5 to 20/9, with total 23113/280.
I found a Great theorem (mentioned above), look through positive and negative n.
Where could be a mistake?
2 x 2 = 4 = true
User avatar
daniel.is.fischer
Posts: 2400
Joined: Sun Sep 02, 2007 11:15 pm
Location: Bremen, Germany

Re: Problem 180

Post by daniel.is.fischer »

You are missing some values, there are 76 for k = 10. You could PM me your approach, maybe I can find a legitimate hint.
Il faut respecter la montagne -- c'est pourquoi les gypa&egrave;tes sont l&agrave;.
User avatar
DNS
Posts: 30
Joined: Thu Oct 16, 2008 9:32 am
Location: Ukraine, Nikolaev

Re: Problem 180

Post by DNS »

Thanks Daniel!
This hint was enough to locate a mistake.
2 x 2 = 4 = true
mantonetti
Posts: 3
Joined: Thu Jan 26, 2012 11:00 pm

Re: Problem 180

Post by mantonetti »

I'm stuck at 71 solutions for the case k=10 (with u+v=23393) but from previous posts I see there are 76 solutions.

Is there someone who can give me a hint please?
Image
Steve N
Posts: 12
Joined: Tue May 29, 2012 11:22 pm
Location: Cheshire, England

Re: Problem 180

Post by Steve N »

Well this is puzzling. I have some fast code that gives the right answer when k=10 (previous posters suggest that for k=10 there are 76 distinct values of s giving a final answer of 12519).

And yet for k=35 I am coming up short. I have been over my code backwards and forwards and can't think where it might be going wrong.

Would anyone be kind enough to offer a suggestion? What am I likely to be doing wrong?
Image
Steve N
Posts: 12
Joined: Tue May 29, 2012 11:22 pm
Location: Cheshire, England

Re: Problem 180

Post by Steve N »

Is anyone able to confirm the number of distinct s values for k=35? I am reluctant to post my own figure here...
Image
Steve N
Posts: 12
Joined: Tue May 29, 2012 11:22 pm
Location: Cheshire, England

Re: Problem 180

Post by Steve N »

Resolved the problem. Just needed to use "biginteger" in my fraction class instead of "long". I'm no programmer, so I'm still confused. Why didn't I get an overflow error if I was stretching my "long" variables too far?

Sorry to have bombarded this thread.
Image
Post Reply