eleven wrote:So this pattern is impossible
- Code: Select all
*-----------------------------------*
| . 123 . | . . 123 |
| 123 . . | 123 . . |
| . . 12 | . 12 . |
|------------------+----------------|
| 123 . . | . . 123 |
| . . . | . 12 . |
| . 123 . | 123 . . |
*-----------------------------------*
is that a "hard" pattern ? [Added: sure now, no]
If you mean hard in the sense of what's needed to prove it contradictory:
- it doesn't require T&E(3)
- it doesn't even require T&E(2), not even some T&E(Bp, 1), p>0
- it requires only T&E(1)
Indeed,
it can be proven contradictory using only whips[≤ 10]. So, not hard compared to the T&E(3) patterns, but not easy when considered as a T&E(1) pattern.
In CSP-Rules, this proof can be done by using function "solve-k-digit-pattern-string" with the string ".1...1...1..1.......1.1....1....1.......1.....1.1....." corresponding to the above pattern. This function supposes that all the cells in the pattern have exactly k digits 1, 2 ... k; but I've already shown how to do for the "incomplete" cells:
- Code: Select all
(bind ?*simulated-eliminations* (create$
(nrc-to-label 3 3 3)
(nrc-to-label 3 3 5 )
(nrc-to-label 3 5 5)
))
(solve-k-digit-pattern-string 3 ".1...1...1..1.......1.1....1....1.......1.....1.1.....")
(Some day, I may write a more general function solve-kl-digit-patterns.)
- Code: Select all
Resolution state after Singles and whips[1]:
+-------------------------------+-------------------------------+-------------------------------+
! 123456789 123 123456789 ! 123456789 123456789 123 ! 123456789 123456789 123456789 !
! 123 123456789 123456789 ! 123 123456789 123456789 ! 123456789 123456789 123456789 !
! 123456789 123456789 12 ! 123456789 12 123456789 ! 123456789 123456789 123456789 !
+-------------------------------+-------------------------------+-------------------------------+
! 123 123456789 123456789 ! 123456789 123456789 123 ! 123456789 123456789 123456789 !
! 123456789 123456789 123456789 ! 123456789 12 123456789 ! 123456789 123456789 123456789 !
! 123456789 123 123456789 ! 123 123456789 123456789 ! 123456789 123456789 123456789 !
+-------------------------------+-------------------------------+-------------------------------+
! 123456789 123456789 123456789 ! 123456789 123456789 123456789 ! 123456789 123456789 123456789 !
! 123456789 123456789 123456789 ! 123456789 123456789 123456789 ! 123456789 123456789 123456789 !
! 123456789 123456789 123456789 ! 123456789 123456789 123456789 ! 123456789 123456789 123456789 !
+-------------------------------+-------------------------------+-------------------------------+
660 candidates.
biv-chain[2]: r3c3{n1 n2} - r3c5{n2 n1} ==> r3c1≠1, r3c2≠1, r3c7≠1, r3c8≠1, r3c9≠1, r3c4≠1, r3c6≠1
biv-chain[2]: r3c3{n2 n1} - r3c5{n1 n2} ==> r3c1≠2, r3c2≠2, r3c7≠2, r3c8≠2, r3c9≠2, r3c4≠2, r3c6≠2
biv-chain[2]: r3c5{n1 n2} - r5c5{n2 n1} ==> r1c5≠1, r2c5≠1, r7c5≠1, r8c5≠1, r9c5≠1, r4c5≠1, r6c5≠1
biv-chain[2]: r3c5{n2 n1} - r5c5{n1 n2} ==> r1c5≠2, r2c5≠2, r7c5≠2, r8c5≠2, r9c5≠2, r4c5≠2, r6c5≠2
whip[3]: r3c3{n1 n2} - r1c2{n2 n3} - r2c1{n3 .} ==> r1c1≠1
whip[3]: r3c3{n2 n1} - r1c2{n1 n3} - r2c1{n3 .} ==> r1c1≠2
whip[3]: r3c3{n1 n2} - r1c2{n2 n3} - r2c1{n3 .} ==> r1c3≠1
whip[3]: r3c3{n2 n1} - r1c2{n1 n3} - r2c1{n3 .} ==> r1c3≠2
whip[3]: r3c5{n1 n2} - r1c6{n2 n3} - r2c4{n3 .} ==> r1c4≠1
whip[3]: r3c5{n2 n1} - r1c6{n1 n3} - r2c4{n3 .} ==> r1c4≠2
whip[3]: r3c3{n1 n2} - r1c2{n2 n3} - r2c1{n3 .} ==> r2c2≠1
whip[3]: r3c3{n2 n1} - r1c2{n1 n3} - r2c1{n3 .} ==> r2c2≠2
whip[3]: r3c3{n1 n2} - r1c2{n2 n3} - r2c1{n3 .} ==> r2c3≠1
whip[3]: r3c3{n2 n1} - r1c2{n1 n3} - r2c1{n3 .} ==> r2c3≠2
whip[3]: r3c5{n1 n2} - r1c6{n2 n3} - r2c4{n3 .} ==> r2c6≠1
whip[3]: r3c5{n2 n1} - r1c6{n1 n3} - r2c4{n3 .} ==> r2c6≠2
whip[3]: r5c5{n1 n2} - r4c6{n2 n3} - r6c4{n3 .} ==> r4c4≠1
whip[3]: r5c5{n2 n1} - r4c6{n1 n3} - r6c4{n3 .} ==> r4c4≠2
whip[3]: r5c5{n1 n2} - r4c6{n2 n3} - r6c4{n3 .} ==> r5c4≠1
whip[3]: r5c5{n2 n1} - r4c6{n1 n3} - r6c4{n3 .} ==> r5c4≠2
whip[3]: r5c5{n1 n2} - r4c6{n2 n3} - r6c4{n3 .} ==> r5c6≠1
whip[3]: r5c5{n1 n2} - r4c6{n2 n3} - r6c4{n3 .} ==> r6c6≠1
whip[3]: r5c5{n2 n1} - r4c6{n1 n3} - r6c4{n3 .} ==> r5c6≠2
whip[3]: r5c5{n2 n1} - r4c6{n1 n3} - r6c4{n3 .} ==> r6c6≠2
whip[10]: r5c5{n1 n2} - r3n2{c5 c3} - b1n1{r3c3 r1c2} - r2c1{n1 n3} - r4c1{n3 n2} - r6c2{n2 n3} - r6c4{n3 n1} - r2c4{n1 n2} - r1c6{n2 n3} - r4c6{n3 .} ==> r5c1≠1
whip[10]: r5c5{n2 n1} - r3n1{c5 c3} - b1n2{r3c3 r1c2} - r2c1{n2 n3} - r4c1{n3 n1} - r6c2{n1 n3} - r6c4{n3 n2} - r2c4{n2 n1} - r1c6{n1 n3} - r4c6{n3 .} ==> r5c1≠2
whip[10]: r5c5{n1 n2} - r3n2{c5 c3} - b1n1{r3c3 r2c1} - r1c2{n1 n3} - r6c2{n3 n2} - r4c1{n2 n3} - r4c6{n3 n1} - r1c6{n1 n2} - r2c4{n2 n3} - r6c4{n3 .} ==> r5c2≠1
whip[10]: r5c5{n2 n1} - r3n1{c5 c3} - b1n2{r3c3 r2c1} - r1c2{n2 n3} - r6c2{n3 n1} - r4c1{n1 n3} - r4c6{n3 n2} - r1c6{n2 n1} - r2c4{n1 n3} - r6c4{n3 .} ==> r5c2≠2
whip[10]: r3c3{n1 n2} - c5n2{r3 r5} - b5n1{r5c5 r6c4} - r4c6{n1 n3} - r4c1{n3 n2} - r6c2{n2 n3} - r1c2{n3 n1} - r1c6{n1 n2} - r2c4{n2 n3} - r2c1{n3 .} ==> r4c3≠1
whip[10]: r3c3{n1 n2} - c5n2{r3 r5} - b5n1{r5c5 r4c6} - r6c4{n1 n3} - r6c2{n3 n2} - r4c1{n2 n3} - r2c1{n3 n1} - r2c4{n1 n2} - r1c6{n2 n3} - r1c2{n3 .} ==> r6c3≠1
whip[10]: r3c3{n2 n1} - c5n1{r3 r5} - b5n2{r5c5 r6c4} - r4c6{n2 n3} - r4c1{n3 n1} - r6c2{n1 n3} - r1c2{n3 n2} - r1c6{n2 n1} - r2c4{n1 n3} - r2c1{n3 .} ==> r4c3≠2
whip[10]: r3c3{n2 n1} - c5n1{r3 r5} - b5n2{r5c5 r4c6} - r6c4{n2 n3} - r6c2{n3 n1} - r4c1{n1 n3} - r2c1{n3 n2} - r2c4{n2 n1} - r1c6{n1 n3} - r1c2{n3 .} ==> r6c3≠2
whip[10]: r3n1{c3 c5} - r5c5{n1 n2} - r3n2{c5 c3} - r2c1{n2 n3} - r2c4{n3 n2} - r1c6{n2 n3} - r4c6{n3 n1} - r4c1{n1 n2} - r6c2{n2 n3} - r6c4{n3 .} ==> r1c2≠1
t-whip[3]: r1c2{n3 n2} - r3c3{n2 n1} - r2c1{n1 .} ==> r3c2≠3, r3c1≠3, r2c3≠3, r2c2≠3, r1c3≠3, r1c1≠3
z-chain[4]: r3c5{n2 n1} - r1c6{n1 n3} - r1c2{n3 n2} - r3n2{c3 .} ==> r2c4≠2
z-chain[3]: r2c4{n3 n1} - r1c6{n1 n2} - r1c2{n2 .} ==> r1c5≠3, r1c4≠3
t-whip[3]: r2c4{n3 n1} - r3c5{n1 n2} - r1c6{n2 .} ==> r3c6≠3, r3c4≠3, r2c6≠3, r2c5≠3
whip[1]: r3n3{c9 .} ==> r1c7≠3, r1c8≠3, r1c9≠3, r2c7≠3, r2c8≠3, r2c9≠3
z-chain[4]: r5c5{n1 n2} - r6c4{n2 n3} - r2c4{n3 n1} - c5n1{r3 .} ==> r4c6≠1
z-chain[3]: r4c6{n3 n2} - r6c4{n2 n1} - r2c4{n1 .} ==> r5c4≠3, r4c4≠3
t-whip[3]: r4c6{n3 n2} - r5c5{n2 n1} - r6c4{n1 .} ==> r6c6≠3, r6c5≠3, r5c6≠3, r4c5≠3
whip[1]: c5n3{r9 .} ==> r7c4≠3, r7c6≠3, r8c4≠3, r8c6≠3, r9c4≠3, r9c6≠3
biv-chain[2]: b5n3{r6c4 r4c6} - r1n3{c6 c2} ==> r6c2≠3
biv-chain[2]: r2n3{c1 c4} - b5n3{r6c4 r4c6} ==> r4c1≠3
biv-chain[2]: r4c1{n2 n1} - r6c2{n1 n2} ==> r4c2≠2, r5c3≠2, r6c1≠2
biv-chain[2]: r6c2{n1 n2} - r4c1{n2 n1} ==> r4c2≠1, r5c3≠1, r6c1≠1
biv-chain[3]: c6n3{r4 r1} - r1c2{n3 n2} - b4n2{r6c2 r4c1} ==> r4c6≠2
singles ==> r4c6=3, r2c4=3, r1c2=3
biv-chain[2]: r6c4{n2 n1} - r6c2{n1 n2} ==> r6c7≠2, r6c8≠2, r6c9≠2
biv-chain[2]: r6c2{n1 n2} - r6c4{n2 n1} ==> r6c7≠1, r6c8≠1, r6c9≠1
biv-chain[2]: r2c1{n2 n1} - r4c1{n1 n2} ==> r7c1≠2, r8c1≠2, r9c1≠2
biv-chain[2]: r4c1{n1 n2} - r2c1{n2 n1} ==> r7c1≠1, r8c1≠1, r9c1≠1
biv-chain[3]: b4n2{r6c2 r4c1} - b1n2{r2c1 r3c3} - c5n2{r3 r5} ==> r6c4≠2
singles ==> r6c4=1, r5c5=2, r3c5=1, r1c6=2, r3c3=2, r2c1=1
PUZZLE 0 HAS NO SOLUTION : NO CANDIDATE FOR BN-CELL b4n1
[Edit]: There's a simpler proof if you allow Subsets, but it is NOT in T&E(1):
- Code: Select all
naked-pairs-in-a-column: c5{r3 r5}{n1 n2} ==> r9c5≠2, r9c5≠1, r8c5≠2, r8c5≠1, r7c5≠2, r7c5≠1, r6c5≠2, r6c5≠1, r4c5≠2, r4c5≠1, r2c5≠2, r2c5≠1, r1c5≠2, r1c5≠1
naked-pairs-in-a-row: r3{c3 c5}{n1 n2} ==> r3c9≠2, r3c9≠1, r3c8≠2, r3c8≠1, r3c7≠2, r3c7≠1, r3c6≠2, r3c6≠1, r3c4≠2, r3c4≠1, r3c2≠2, r3c2≠1, r3c1≠2, r3c1≠1
naked-triplets-in-a-block: b5{r4c6 r5c5 r6c4}{n3 n2 n1} ==> r6c6≠3, r6c6≠2, r6c6≠1, r6c5≠3, r5c6≠3, r5c6≠2, r5c6≠1, r5c4≠3, r5c4≠2, r5c4≠1, r4c5≠3, r4c4≠3, r4c4≠2, r4c4≠1
naked-triplets-in-a-block: b2{r1c6 r2c4 r3c5}{n2 n3 n1} ==> r3c6≠3, r3c4≠3, r2c6≠3, r2c6≠2, r2c6≠1, r2c5≠3, r1c5≠3, r1c4≠3, r1c4≠2, r1c4≠1
whip[1]: c5n3{r9 .} ==> r7c4≠3, r7c6≠3, r8c4≠3, r8c6≠3, r9c4≠3, r9c6≠3
naked-triplets-in-a-block: b1{r1c2 r2c1 r3c3}{n2 n3 n1} ==> r3c2≠3, r3c1≠3, r2c3≠3, r2c3≠2, r2c3≠1, r2c2≠3, r2c2≠2, r2c2≠1, r1c3≠3, r1c3≠2, r1c3≠1, r1c1≠3, r1c1≠2, r1c1≠1
whip[1]: r3n3{c9 .} ==> r1c7≠3, r1c8≠3, r1c9≠3, r2c7≠3, r2c8≠3, r2c9≠3
biv-chain[2]: b1n3{r2c1 r1c2} - c6n3{r1 r4} ==> r4c1≠3
biv-chain[2]: c4n3{r6 r2} - b1n3{r2c1 r1c2} ==> r6c2≠3
naked-pairs-in-a-block: b4{r4c1 r6c2}{n1 n2} ==> r6c3≠2, r6c3≠1, r6c1≠2, r6c1≠1, r5c3≠2, r5c3≠1, r5c2≠2, r5c2≠1, r5c1≠2, r5c1≠1, r4c3≠2, r4c3≠1, r4c2≠2, r4c2≠1
whip[6]: r1n3{c2 c6} - r2n3{c4 c1} - b1n1{r2c1 r3c3} - c5n1{r3 r5} - r4c6{n1 n2} - b4n2{r4c1 .} ==> r1c2≠2
biv-chain[3]: b4n2{r6c2 r4c1} - b1n2{r2c1 r3c3} - c5n2{r3 r5} ==> r6c4≠2
biv-chain[3]: b4n1{r4c1 r6c2} - r6c4{n1 n3} - r2n3{c4 c1} ==> r2c1≠1
biv-chain[3]: b4n2{r6c2 r4c1} - r2c1{n2 n3} - r1c2{n3 n1} ==> r6c2≠1
singles ==> r6c2=2, r4c1=1
biv-chain[3]: c5n2{r3 r5} - r4c6{n2 n3} - b2n3{r1c6 r2c4} ==> r2c4≠2
whip[1]: c4n2{r9 .} ==> r7c6≠2, r8c6≠2, r9c6≠2
naked-pairs-in-a-column: c4{r2 r6}{n1 n3} ==> r9c4≠1, r8c4≠1, r7c4≠1
whip[1]: b8n1{r9c6 .} ==> r1c6≠1
biv-chain[3]: r3c5{n2 n1} - r2c4{n1 n3} - r2c1{n3 n2} ==> r3c3≠2
singles ==> r3c3=1, r1c2=3, r1c6=2
PUZZLE 0 HAS NO SOLUTION : NO CANDIDATE FOR RN-CELL r3n2