Ah, I somehow had overlooked that part of the puzzle. Thanks,
-- Raul On Mon, Jan 10, 2022 at 6:29 PM 'Mike Day' via Programming <programm...@jsoftware.com> wrote: > > Perhaps we’re not talking about the same thing. I was using this bit of the > problem description: > “By finding pairs of scanners that both see at least 12 of the same beacons, > you can assemble the entire map....” > > So for each scanner I found its inter-beacon distances, which are independent > of those pesky rotations. I considered those pairs of scanners evidently > with at least twelve beacons in common by examining these distances. As I > said before, the appropriate rotation matrix arises by solving R =round (%.A) > x B for matching sets of coords A and B, (after applying an arbitrary offset > to set one matching pair of points in A&B each to (0,0,0)). At least the > approach worked! > > But day 23 part 2 is still my bug-bear. I’d managed to achieve a 1000-fold > speed increase for part 1 so allowing a blind & crude approach to find a > solution when it had previously got stuck in cpu mud, but as I feared there > are too many degrees of freedom in part 2. > > 2022 calling, > Cheers, > Mike > > > > Sent from my iPad > > > On 10 Jan 2022, at 19:33, Raul Miller <rauldmil...@gmail.com> wrote: > > > > On Mon, Jan 10, 2022 at 1:17 PM 'Michael Day' via Programming > > <programm...@jsoftware.com> wrote: > >> You mentioned looking for 67 or 68 of the same beacon distances. My > >> criterion was >: 66, iirc, since 12 matching distinct points would have > >> 66 = 11.12%2 pairs of non-zero distances. > > > > Actually, I was looking for at least 34 matching distances. (I was > > comparing distances, between points, not differences between > > coordinate values.) > > > > I am curious about how you picked 12 here, also. > > > > My implementation was looking for more than that because I was looking > > for the largest number of distances in common between any two > > scanners, and when I looked at all of the scanners, the distance > > commonalities I saw were 68 67 18 17 16 6 5 4 3 2 1 0 > > > > So I coded mine as requiring more than half of the largest visible > > value (which actually, I guess, wound up being 35). > > > > Testing it out, 6 (or, more than 5) works just as well. But I am > > curious how you decided on 12. > > > > Thanks, > > > > -- > > Raul > > ---------------------------------------------------------------------- > > For information about J forums see http://www.jsoftware.com/forums.htm > ---------------------------------------------------------------------- > For information about J forums see http://www.jsoftware.com/forums.htm ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm