View unanswered posts | View active topics It is currently Thu Oct 19, 2017 8:15 pm



← Back to the Calcudoku puzzle page




Reply to topic  [ 7 posts ] 
 5*5 difficult on 24th May 2016 
Author Message

Posted on: Tue May 24, 2016 8:21 pm




Posts: 15
Joined: Mon Jul 25, 2011 7:49 pm
Post 5*5 difficult on 24th May 2016
I think there's an error in this puzzle (http://www.calcudoku.org/en/2016-05-24/5/3).

I think the box c3*d3*c4*d4=60 could be a mistype for c3*d3*c4*d4=180, or,
d5~e5=3 could be a mistype for d5~e5=1. (Writing a~b to mean abs(a-b).)

Taking either, but not both, of these results in a soluble puzzle.

Of these two, the error d5~e5=1 seems the better, as it results in one solution, whereas
c3*d3*c4*d4=1 results in two feasible solutions:

53142
41523
24351
12435
35214

and

43152
51423
24531
12345
35214


Profile
User avatar

Posted on: Tue May 24, 2016 9:06 pm




Posts: 2192
Joined: Thu May 12, 2011 11:58 pm
Post Re: 5*5 difficult on 24th May 2016
randomfruit wrote:
I think there's an error in this puzzle (http://www.calcudoku.org/en/2016-05-24/5/3).

Both solutions you give are not solutions to the puzzle on the page though (?)

Edit: for reference, here is the puzzle:

Image


Profile

Posted on: Wed May 25, 2016 9:24 pm




Posts: 15
Joined: Mon Jul 25, 2011 7:49 pm
Post Re: 5*5 difficult on 24th May 2016
OK, now I've seen the solution, and I see that my solver had a bug. It did NOT produce any correct solution to the puzzle, but it did show some 'wrong' solutions when I removed a condition, leading to my comments before.

The solver is basically SQL:

select a1,a2, etc, b1, b2, etc, #there are 25 tables with names a1 thru e5,
from a1,a2, etc, b1, b2, etc, # each of which has one column with the same name as the table
where a1!=b1 and etc # and each of which contains the numbers 1..5
and a1!=a2 and etc # There are not-equal conditions to prevent duplicates
and a1+b1+a2=12 # and then the puzzle statement...
and (c1-d1-c2=0 or d1-c1-c2=0 or c2-c1-d1=0)
and e1*d2*e2=12
and b2*a3*b3=8
and c3*d3*c4*d4=60
and (e3/e4=5 or e4/e3=5)
and (a4-b4-a5=0 or b4-a4-a5=0 or a5-a4-b4=0)
and b5+c5=7
and abs(d5-e5)=3;

I was running this thru MySQL Workbench and their InnoDB engine.

I got outputs as described when I 'removed' a condition, i.e., commented-out
# and c3*d3*c4*d4=60

So my SQL code for the problem was wrong, and I found one mis-coded variable name in a condition like "and a1!=a2".
It was relatively easy to find using the enhanced windows editor "notepad++" (obtainable from fosshub.org) which put highlights into a source text showing every use of a variable when you double-click on it once.

My MySQL solver now finds a correct solution.


Profile
User avatar

Posted on: Thu May 26, 2016 8:55 am




Posts: 2192
Joined: Thu May 12, 2011 11:58 pm
Post Re: 5*5 difficult on 24th May 2016
randomfruit wrote:
OK, now I've seen the solution, and I see that my solver had a bug. It did NOT produce any correct solution to the puzzle, but it did show some 'wrong' solutions when I removed a condition, leading to my comments before.

Ah... so that's how you get all those points! [lol]

How long does it run on larger puzzles, say a 9x9?

Patrick


Profile

Posted on: Mon Jul 25, 2016 3:07 pm




Posts: 209
Joined: Sun May 22, 2016 2:17 pm
Post Re: 5*5 difficult on 24th May 2016
randomfruit wrote:
I think there's an error in this puzzle (http://www.calcudoku.org/en/2016-05-24/5/3).

I think the box c3*d3*c4*d4=60 could be a mistype for c3*d3*c4*d4=180, or,
d5~e5=3 could be a mistype for d5~e5=1. (Writing a~b to mean abs(a-b).)

Uhhh... what?

This link takes me to a puzzle with negative numbers (2 through -2). It still says the same date, just not the same puzzle. [confused]
And also, I still scored 3 points for it even though it was two months ago. [mellow]


Profile

Posted on: Mon Jul 25, 2016 3:17 pm




Posts: 209
Joined: Sun May 22, 2016 2:17 pm
Post Re: 5*5 difficult on 24th May 2016
marblevolcano wrote:
And also, I still scored 3 points for it even though it was two months ago. [mellow]

My mistake! That was today's puzzle, for subscribers only (I think) but somehow I still got points [scared]
Well, at least I now know how to get 5x5 difficult subscriber only puzzles. Thanks randomfruit :-)


Profile

Posted on: Mon Jul 25, 2016 11:22 pm




Posts: 218
Joined: Tue Mar 01, 2016 10:03 pm
Post Re: 5*5 difficult on 24th May 2016
marblevolcano wrote:
marblevolcano wrote:
And also, I still scored 3 points for it even though it was two months ago. [mellow]

My mistake! That was today's puzzle, for subscribers only (I think) but somehow I still got points [scared]
Well, at least I now know how to get 5x5 difficult subscriber only puzzles. Thanks randomfruit :-)


I also clicked on the link and it allowed me access to today's 5x5 difficult subscriber only puzzle. I earned an extra 3 points but I no longer have a star against my name indicating that I solved all today's puzzles.


Profile
Display posts from previous:  Sort by  
Reply to topic   [ 7 posts ] 

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
All forum contents © Patrick Min, and by the post authors.

Forum software phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Designed by STSoftware.