login
Square spiral of smallest distinct positive integers starting at 1 such that the four sums of each term with its four nearest neighbors are composite numbers.
3

%I #16 Apr 26 2021 21:33:11

%S 1,3,5,7,2,8,4,11,9,6,12,10,14,13,15,18,16,19,17,21,23,22,24,25,20,26,

%T 28,27,29,31,32,30,33,35,34,36,38,39,37,40,41,43,42,45,46,44,47,48,50,

%U 49,51,53,55,56,54,52,58,59,57,60,61,62,63,66,64,68,65,67,71,69,72,70,73,74,76,77,75

%N Square spiral of smallest distinct positive integers starting at 1 such that the four sums of each term with its four nearest neighbors are composite numbers.

%e The square spiral starts:

%e .

%e 38--36--34--35--33--30--32

%e | |

%e 39 16--18--15--13--14 31

%e | | | |

%e 37 19 2---7---5 10 29

%e | | | | | |

%e 40 17 8 1---3 12 27

%e | | | | |

%e 41 21 4--11---9---6 28

%e | | |

%e 43 23--22--24--25--20--26

%e |

%e 42--45--46--44--47--48--50..

%e .

%e a(2) = 3 as a(1) + 3 = 1 + 3 = 4, the smallest possible composite number.

%e a(3) = 5 as a(2) + 5 = 3 + 5 = 8. Note a(3) cannot be 2 or 4 as when these are added to 3 the result is a prime number.

%e a(4) = 7 as a(3) + 7 = 5 + 7 = 12, and a(1) + 7 = 1 + 7 = 8, both being composite.

%e a(9) = 9 as a(8) + 9 = 11 + 9 = 20, and a(2) + 9 = 3 + 9 = 12, both being composite.

%Y Cf. A338644 (sum to primes), A002808, A063826, A260643, A334742, A307834, A338221.

%K nonn

%O 1,2

%A _Eric Angelini_ and _Scott R. Shannon_, Apr 21 2021