Puzzle 47

Post puzzles for others to solve here.

Puzzle 47

Postby P.O. » Mon Jul 25, 2022 7:03 am

from the Patterns Game, SER 9.2 not easy but manageable, i think.
Code: Select all
1 . .   . . 2   4 6 .
. 7 .   6 3 .   . . .
. . .   4 . .   . . .
. 8 1   . . .   . . .
. 5 .   . . 7   . . .
4 . .   . 2 .   8 7 .
8 . .   . . 4   . . .
2 . .   . . 1   . 3 .
. . .   . . .   . . 9

1....246..7.63.......4......81.......5...7...4...2.87.8....4...2....1.3.........9

basics:
Hidden Text: Show
Code: Select all
( n1r3c5   n2r5c3   n2r3c2   n4r2c3   n7r4c1 )
intersection:
((((7 0) (3 7 3) (3 5 7 9)) ((7 0) (3 9 3) (3 5 7 8))))
QUINTE BOX: ((7 7 9) (1 2 5 6 7)) ((7 8 9) (1 2 5)) ((7 9 9) (1 2 5 6 7)) ((8 7 9) (5 6 7)) ((9 7 9) (1 2 5 6 7))
(((8 9 9) (4 5 6 7 8)) ((9 8 9) (1 2 4 5 8)))

after basics:
Code: Select all
1      39     3589   5789   5789   2      4      6      358             
59     7      4      6      3      589    1259   12589  1258           
3569   2      35689  4      1      589    3579   589    3578           
7      8      1      359    4569   3569   23569  2459   23456           
369    5      2      1389   4689   7      1369   149    1346           
4      369    369    1359   2      3569   8      7      1356           
8      1369   35679  23579  5679   4      12567  125    12567           
2      469    5679   5789   56789  1      567    3      48             
356    1346   3567   23578  5678   3568   12567  48     9     
P.O.
 
Posts: 1763
Joined: 07 June 2021

Re: Puzzle 47

Postby yzfwsf » Mon Jul 25, 2022 5:24 pm

Code: Select all
Single:  => r2c3=4. r4c1=7,r3c2=2, r5c3=2,r3c5=1
Locked Candidates 1 (Pointing): 7 in b2 => r1c9<>7
Hidden Pair: 48 in r8c9,r9c8 => r8c9<>567,r9c8<>125
Finned Jellyfish:9r1678\c2345 fr6c6 => b5p1245<>9
ALS Continuous Nice Loop: (5=369)r6c236 - r6c4 = r46c6 - (9=85)r23c6 => r6c49<>3,r49c6<>5,r6c9<>6,r1c45,r9c6<>8
Whip[9]: Start From 3r7c2 causes 9 to disappear in Box 2 => r7c2<>3
3r7c2- r1c2(3=9) - 9c1(r23=r5) - r6c2(9=6) - r8c2(6=4) - 4r9(c2=c8) - r5c8(4=1) - 1r6(c9=c4) - 9r6(c4=c6) - 9b2(p69=.)
Whip[6]: Start From 3r4c4 causes 6 to disappear in Column 2 => r4c4<>3
3r4c4- 3r7(c4=c3) - 3r6(c3=c2) - r1c2(3=9) - r2c1(9=5) - r9c1(5=6) - 6c2(r789=.)
LC+Single to the end
yzfwsf
 
Posts: 921
Joined: 16 April 2019

Re: Puzzle 47

Postby DEFISE » Tue Jul 26, 2022 9:20 am

Single(s): 4r2c3, 7r4c1, 2r3c2, 2r5c3, 1r3c5
Box/Line: 7r3b3 => -7r1c9
Hidden pairs: 48b9p68 => -5r8c9 -6r8c9 -7r8c9 -1r9c8 -2r9c8 -5r9c8
whip[10]: b4n9{r6c2 r5c1}- r2c1{n9 n5}- r2c6{n5 n8}- r3c6{n8 n5}- r1n5{c4 c9}- r6n5{c9 c4}- r4c4{n5 n3}- c6n3{r4 r9}- c1n3{r9 r3}- r1n3{c2 .} => -9r6c6
Jellyfish in rows: 9r1678c2345 => -9r3c3 -9r4c4 -9r4c5 -9r5c4 -9r5c5
whip[7]: r7n3{c2 c4}- r4c4{n3 n5}- r6n5{c4 c9}- r6n1{c9 c4}- b5n9{r6c4 r4c6}- c6n3{r4 r6}- b4n3{r6c2 .} => -3r9c1
whip[8]: c1n3{r5 r3}- r1c2{n3 n9}- r6n9{c2 c4}- r6n1{c4 c9}- r5c8{n1 n4}- r9n4{c8 c2}- r8c2{n4 n6}- c1n6{r9 .} => -9r5c1
Sigles & Box/Lines to the end.
DEFISE
 
Posts: 284
Joined: 16 April 2020
Location: France

Re: Puzzle 47

Postby P.O. » Wed Jul 27, 2022 9:11 am

thank you for your answers.
Code: Select all
5r6c469 => r6c9 <> 36
 r6c4=5 - r6n1{c4 c9}
 r6c6=5 - 89r23c6 - r1n9{c45 c23} - c1n9{r23 r5} - r6n9{c23 c4} - r6n1{c4 c9}
 r6c9=5

9r235c1 => r4c45 r5c45 <> 9
 r2c1=9 - r1n9{c23 c45} - c6n9{r23 r46}
 r3c1=9 - r1n9{c23 c45} - c6n9{r23 r46}
 r5c1=9 - r6n9{c23 c46}
 
3r359c1 => r6c9 <> 1
 r3c1=3 - r1c2{n3 n9} - c1n9{r2 r5} - c1n6{r5 r9} - r8c2{n69 n4} - r9n4{c2 c8} - r5c8{n49 n1}
 r5c1=3 - r6n3{c23 c46} - r4c4{n3 n5} - r6n5{c46 c9}
 r9c1=3 - r7n3{c23 c4}  - r4c4{n3 n5} - r6n5{c46 c9}
 
( n5r6c9  n1r6c4 )
intersections:
((((9 0) (4 6 5) (3 5 6 9)) ((9 0) (6 6 5) (3 6 9)))
 (((9 0) (1 4 2) (5 7 8 9)) ((9 0) (1 5 2) (5 7 8 9)))
 
ste.

hi yzfwsf, just a remark, i don't think the chains you call whips are whips, a whip never starts with its target, your chains seem to follow this logic: pick a candidate, set it true, apply your theory, if you find a contradiction eliminate that candidate.
P.O.
 
Posts: 1763
Joined: 07 June 2021

Re: Puzzle 47

Postby yzfwsf » Wed Jul 27, 2022 4:24 pm

hi P.O.
I'm not sure if they are whips, but I did write the code with the logic you said. Pick a target, then BFS looks for a series of consecutive (lk,rk) nodes to find contradictions. Unlike ordinary dynamic chain, it has linear continuity.
yzfwsf
 
Posts: 921
Joined: 16 April 2019

Re: Puzzle 47

Postby denis_berthier » Wed Jul 27, 2022 5:02 pm

.
All the examples I 've seen called whips by yzfsfw are whips, with just a notational change.
However, explanations such as "Start From 3r7c2 causes 9 to disappear in Box 2" are misleading. Something like "Supposing 3r7c2 would cause 9 to disappear in Box 2" would be better (though it still evokes the inferential view of chains).
denis_berthier
2010 Supporter
 
Posts: 4238
Joined: 19 June 2007
Location: Paris

Re: Puzzle 47

Postby P.O. » Wed Jul 27, 2022 5:44 pm

hi yzfwsf,
your chains are powerful as they make use of all the previous links to find the next one, i do the same. Looking for contradiction is certainly the royal road to solve a sudoku as in each candidate cell there is one to eight possibilities to start a contradiction chain; i have some reservations with contradiction but of course it's just a personal preference, i would put them like this: you break the sudoku rules and you say you win.

hi Denis, from PBCS3 5.2.1.3
Code: Select all
Definition: in a resolution state RS, given a candidate Z (which will be the target), a zt-whip (in short a whip) of length n (n ≥ 1) built on Z is a regular chain (L1, R1, L2, R2, …. Ln) [notice there is no Rn] associated with a sequence (V1, … Vn) of CSPVariables, such that:
   – Z does not belong to {L1, R1, L2, R2, …. Ln};
   – L1 is linked to Z;
   – for any 1 ≤ k < n, Rk is the only candidate for Vk compatible with Z and with all the previous right-linking candidates (i.e. with Z and with all the Ri, 1 ≤ i < k);
   – Z is not a label for Vn;
   – Vn has no candidate compatible with Z and with all the previous right-linking candidates (but Vn has more than one candidate – this is a non-degeneracy condition).
P.O.
 
Posts: 1763
Joined: 07 June 2021

Re: Puzzle 47

Postby yzfwsf » Wed Jul 27, 2022 6:00 pm

I use I use the following data structure to find whips.Sometimes the number of nodes searched will reach 50000+. In order to improve the search speed, I now try to limit the number of nodes and not allow the same rlc to appear in each layer, but the cost is that very few whips cannot be found.
Code: Select all
Type WhipNode
    candidates(80) As Long =Any           'RC
    Nrcb(1 To 9, 0 To 26) As Long = Any      'nr,nc,nb
    llc As Short                              'left Vertice of adjacency Matrix
    rlc As Short                              'right Vertice of adjacency Matrix
    lvl As Byte                             
    kind As Byte                              '0 RN,1 CN,2 BN,3 RC
    parent As WhipNode Ptr
    Declare Constructor()
    Declare Constructor(As puzzle Ptr, As Long)
    Declare Constructor(As WhipNode Ptr, As WhipNode Ptr, As Long, As Long)
End Type
yzfwsf
 
Posts: 921
Joined: 16 April 2019

Re: Puzzle 47

Postby P.O. » Wed Jul 27, 2022 6:26 pm

i certainly understand this predicament, sometimes the amount of links to consider is just not manageable, my algorithm seem lost in a maze with no way out.
P.O.
 
Posts: 1763
Joined: 07 June 2021


Return to Puzzles