rjamil wrote:However, don't know how pjb and yourself are doing.
there's no point in discussing with you if you don't remember anything from the previous posts.
rjamil wrote:However, don't know how pjb and yourself are doing.
Between them r4c2 and r9c4 include all patterns of 4, so patterns of 2 which include both cells can be deleted.
P.O. wrote:Between them r4c2 and r9c4 include all patterns of 4, so patterns of 2 which include both cells can be deleted.
this should be understood as follows:
there are n templates for 4, p of them have cell r4c2, q have cell r9c4 and r have both cells with p+q+r = n and r < n
so any template for a value other than 4 that has these two cells is invalid because the template for 4 of the solution has either r4c2 or r9c4 or both
initialization:
#VT: (5 10 5 6 6 9 34 12 6)
Cells: nil nil nil nil nil nil nil nil nil
Candidates: nil nil nil (58) nil nil (61) nil nil -> r7c4<>4 r7c7<>7
2 13 4 378 137 178 5 689 69
7 5 38 6 9 4 238 28 1
6 9 138 358 2 158 348 48 7
8 12467 126 9 1457 1567 27 2567 3
49 2467 5 3478 347 678 1 26789 269
3 167 169 578 157 2 789 56789 4
5 234 239 27 6 79 249 1 8
49 246 269 1 8 3 2479 2479 5
1 8 7 245 45 59 6 3 29
141 candidates.
1: (2 4) 21 instances
#VT: (5 6 5 6 6 9 34 12 6)
Cells: nil nil nil nil nil nil nil nil nil
Candidates: nil (57 61) nil nil nil nil nil nil nil -> r7c3<>2 r7c7<>2
2: (4 9) 13 instances
#VT: (5 6 5 5 6 9 34 12 5)
Cells: nil nil nil nil nil nil nil nil nil
Candidates: nil nil nil (65) nil nil nil nil nil -> r8c2<>4
2 13 4 378 137 178 5 689 69
7 5 38 6 9 4 238 28 1
6 9 138 358 2 158 348 48 7
8 12467 126 9 1457 1567 27 2567 3
49 2467 5 3478 347 678 1 26789 269
3 167 169 578 157 2 789 56789 4
5 234 39 27 6 79 49 1 8
49 26 269 1 8 3 2479 2479 5
1 8 7 245 45 59 6 3 29
138 candidates.
4s at r9c45 only ones in row/column => -4 r7c4.
7s at r8c78 only ones in row/column => -7 r7c7.
Naked quads of 1378 at r1c2456 => -8 r1c8
8s at r1c46 only ones in row/column => -8 r3c46.
Between them r4c2 and r9c4 include all patterns of 4, so patterns of 2 which include both cells can be deleted. As a result, no pattern of 2 includes r7c3, r8c8 so 2 can be deleted from r7c3, r8c8
Between them r7c7 and r9c4 include all patterns of 4, so patterns of 2 which include both cells can be deleted. As a result, no pattern of 2 includes r7c7 so 2 can be deleted from r7c7
Between them r5c1 and r7c7 include all patterns of 9, so patterns of 4 which include both cells can be deleted. As a result, no pattern of 4 includes r8c2 so 4 can be deleted from r8c2
here is the complete resolution using POM for this puzzle in pjb solver, his method finds r8c8<>2 in addition to the eliminations that the combinations (2 4) and (4 9) find:
P.O. wrote:after having retrieved the possible templates or after having made the combinations it is possible to test their validity in the context of the current possible templates:
- a possible template for a value is valid if it is compatible with at least one possible template for each of the other values
- an instance of a combination of size n for values V(i) of (1 2 3 4 5 6 7 8 9) is valid if it is compatible with at least one of the possible templates of each of the values (1 2 3 4 5 6 7 8 9) - V(i)
(5 10 5 6 6 9 34 12 6) #VT before checking the templates validity
(5 5 5 5 6 9 24 12 5) #VT after checking the templates validity
#10: ((1 17 23 34 38 51 58 66 81) (1 17 23 30 45 51 61 65 76) (1 17 23 30 45 51 56 70 76)
(1 17 23 29 45 51 61 66 76) (1 17 23 29 45 51 57 70 76) (1 16 23 35 38 51 58 66 81)
(1 16 23 30 45 51 56 71 76) (1 16 23 30 44 51 58 65 81) (1 16 23 29 45 51 57 71 76)
(1 16 23 29 44 51 58 66 81))
#5: ((1 17 23 34 38 51 58 66 81) (1 17 23 30 45 51 56 70 76) (1 16 23 35 38 51 58 66 81)
(1 16 23 30 44 51 58 65 81) (1 16 23 29 44 51 58 66 81))
((1 17 23 30 45 51 61 65 76) (1 17 23 29 45 51 61 66 76) (1 17 23 29 45 51 57 70 76)
(1 16 23 30 45 51 56 71 76) (1 16 23 29 45 51 57 71 76))
((5 16 21 36 40 46 56 69 80) (5 12 25 36 40 46 56 69 80) (4 16 21 36 41 46 56 69 80)
(4 12 25 36 41 46 56 69 80) (2 16 22 36 41 46 57 69 80))
((3 15 26 32 38 54 61 64 76) (3 15 26 32 37 54 61 65 76) (3 15 26 32 37 54 56 70 76)
(3 15 26 29 41 54 61 64 76) (3 15 26 29 40 54 61 64 77) (3 15 25 32 37 54 56 71 76))
P.O. wrote:i have the same number of VT and the same eliminations as you when i don't check the validity of the templates and combinations, and the size 2 combinations don't solve the puzzle
it's when i eliminate the templates that i find invalid that i reduce the number of VT and solve the puzzle with two size 2 combinations
P.O. wrote:what i do is simple, i have all possible templates for each value in a list
((VT for 1) (VT for 2) (...))
and i loop on this list as long as i find templates to eliminated
and the reason why a template for a value is eliminated is that it is incompatible, i.e. overlaps, with all the templates of another value