login
The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A321499 Numbers of the form (x - y)(x^2 - y^2) with x > y > 0. 4
3, 5, 7, 9, 11, 13, 15, 16, 17, 19, 21, 23, 24, 25, 27, 29, 31, 32, 33, 35, 37, 39, 40, 41, 43, 45, 47, 48, 49, 51, 53, 55, 56, 57, 59, 61, 63, 64, 65, 67, 69, 71, 72, 73, 75, 77, 79, 80, 81, 83, 85, 87, 88, 89, 91, 93, 95, 96, 97, 99, 101, 103, 104, 105, 107, 109, 111, 112, 113, 115 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,1

COMMENTS

Equivalently, numbers of the form (x - y)^2*(x + y) or d^2*(2m + d), for (x, y) = (m+d, m). This shows that this consists of all squares d^2 > 0 times all numbers of the same parity and larger than d. In particular, for d=1, all odd numbers > 1, and for d=2, 4*(even numbers > 2) = 8*(any number > 1). Larger d can't yield additional terms, neither odd nor even: The sequence consists exactly of all odd numbers > 2 and multiples of 8 larger than 8.

LINKS

Table of n, a(n) for n=1..70.

Index entries for linear recurrences with constant coefficients, signature (1,0,0,0,1,-1).

FORMULA

Asymptotic density is 5/8. Complement is A321501.

a(5k-2) = 8k for all k > 1, a(n) = floor((n+2)*4/5)*2 + 1 for all other n > 3.

a(n + 5) = a(n) + 8 for n > 3. - David A. Corneth, Nov 23 2018

O.g.f. 3*x+5*x^2+7*x^3 -x^4*(-9-2*x-2*x^2-2*x^3-x^4+8*x^5) / ( (x^4+x^3+x^2+x+1) *(x-1)^2 ). - R. J. Mathar, Nov 29 2018

EXAMPLE

a(1) = 3 = 1*3 = (2 - 1)*(2^2 - 1^2). Similarly any larger odd number 2k+1 = (k+1 - k)((k+1)^2 - k^2) is in this sequence.

a(8) = 16 = 2*8 = (3 - 1)*(3^2 - 1^2). Similarly, any larger multiple of 8, 8*(1 + k) = 2*(4k + 4) = (k+2 - k)((k+2)^2 - k^2) is in this sequence.

PROG

(PARI) is(n)={n&&fordiv(n, d, d^2*(d+2)>n && break; n%d^2&&next; bittest(n\d^2-d, 0)||return(1))} \\ This uses the definition. More efficient variant below.

(PARI) select( is_A321499(n)=if(bittest(n, 0), n>1, n%8, 0, n>8), [0..99]) \\ Defines the function is_A321499(). The select() command is just an illustration and check.

(PARI) A321499_list(M)=setunion(vector(M\2-1, k, 2*k+1), [2..M\8]*8) \\ list all terms up to M; more efficient than select() above.

(PARI) apply( A321499(n)=if(n<8, 2*n+1, n%5!=3, (n+2)*4\5*2+1, n\5*8+8), [1..30]) \\ Defines A321499(n). The apply() command provides a check & illustration.

CROSSREFS

See A321491 for numbers of the form (x+y)(x^2+y^2).

Cf. A321501 (complement).

See A321498 for numbers that have two representations of the form (x-y)(x^2-y^2).

Cf. A106505 (conjectured to be the sequence without the 3).

Sequence in context: A206545 A293703 A120890 * A134322 A186328 A063460

Adjacent sequences:  A321496 A321497 A321498 * A321500 A321501 A321502

KEYWORD

nonn,easy

AUTHOR

M. F. Hasler, Nov 22 2018

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 6 16:14 EDT 2020. Contains 333276 sequences. (Running on oeis4.)