A285426 Numbers n such that at least two consecutive elements of the n-th row of A237591 are in increasing order.
14, 20, 25, 27, 33, 34, 35, 39, 42, 43, 44, 49, 50, 52, 53, 54, 56, 60, 61, 62, 63, 64, 65, 68, 69, 72, 73, 74, 75, 76, 77, 81, 82, 83, 85, 86, 87, 88, 89, 90, 91, 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, 110, 111, 112, 113, 114, 115, 116, 117, 118, 119, 121, 122, 123, 124, 125, 126, 127, 128
Offset: 1
Keywords
Examples
14 is in the sequence because the elements of the 14th row of A237591 are 8, 3, 1, 2, and they are not in nonincreasing order (note that the last two element are in increasing order).
Programs
-
Python
import math from sympy import sqrt def T(n, k): return int(math.ceil((n + 1)/k - (k + 1)/2)) - int(math.ceil((n + 1)/(k + 1) - (k + 2)/2)) def isok(n): l = [T(n, k) for k in range(1, int(math.floor((sqrt(8*n + 1) - 1)/2)) + 1)] return any(l[i + 1] > l[i] for i in range(len(l) - 1)) print([n for n in range(1, 151) if isok(n)]) # Indranil Ghosh, Apr 20 2017
Comments