0,2

Let m be the largest number such that n >= m(m+1). If n is even, a(n) = n - m; otherwise a(n) = n + m + 1.

a(A005408(n)) > 0; a(A005843(n)) <= 0. [Reinhard Zumkeller, Oct 12 2011]

Reinhard Zumkeller, Table of n, a(n) for n = 0..10000

Index entries for sequences that are permutations of the natural numbers

(Haskell)

a127367 n | even n = n - m + 1

| otherwise = n + m

where m = length $ takeWhile (<= n) a002378_list

-- Reinhard Zumkeller, Oct 12 2011

Cf. A127366, A002378, A000194.

Cf. A002378 (oblong numbers).

Sequence in context: A262211 A094512 A182650 * A054084 A296069 A058683

Adjacent sequences: A127364 A127365 A127366 * A127368 A127369 A127370

nonn

Franklin T. Adams-Watters, Jan 11 2007

approved