|
|
Re: Continous path on square grid
Posted:
Feb 1, 2013 10:29 AM
|
|
On Feb 1, 3:23 pm, Willem <wil...@turtle.stack.nl> wrote:
> Willem wrote: > ) clive tooth wrote: > > ) ) Let a P(n,s) be a continuous path, made of s straight sections, which > ) ) passes exactly once through each of n^2 points arranged in a square > ) ) array. > ) ) > ) ) So, here is a P(3,4)... > ) )http://www.flickr.com/photos/lhc_logs/8435448440/in/photostream > ) ) > ) ) I know of a P(4,6). But I cannot find a P(5,8). Any takers? > ) > ) IIRC, I figured out a way to get P(n,n*2-2) by beginning at P(4,6) in > ) such a way that adding a row and column required two extra lines. > ) > ) I can't remember exactly what that beginning sequence was though. > > Ah yes, now I remember. If you take the 3x3 solution you posted, the last > line can be extended upward, and then you can draw lines right and down, > adding a row and column to the top and right respectively. From there on > you can keep on spiraling outward. > > (Fixed width) > > 8-O-O-O-O-9 > | | > O 4-O-O-5 O > | | | | > O 1-O-O-2 O > | |\ /| | > O O O O O O > | | X | | > O O O # O O > | |/ | | > 7-3-O-O-6 10
Your line 34 passes through point 1.
I think you have overlooked the "... passes exactly once through each [point] ..." condition.
-- Clive
|
|