cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A254671 Numbers that can be represented as x*y + x + y, where x >= y > 1.

Original entry on oeis.org

8, 11, 14, 15, 17, 19, 20, 23, 24, 26, 27, 29, 31, 32, 34, 35, 38, 39, 41, 43, 44, 47, 48, 49, 50, 51, 53, 54, 55, 56, 59, 62, 63, 64, 65, 67, 68, 69, 71, 74, 75, 76, 77, 79, 80, 83, 84, 86, 87, 89, 90, 91, 92, 94, 95, 97, 98, 99, 101, 103, 104, 107, 109, 110, 111, 113
Offset: 1

Views

Author

Alex Ratushnyak, Feb 04 2015

Keywords

Comments

Apparently 8 and the elements of A061743. - R. J. Mathar, Feb 19 2015
This is true. For proof, see link.
As x*y + x + y = (x + 1)*(y + 1) - 1 where x >= y > 1 we have k = a(n) is in the sequence if and only if k + 1 is an odd composite or k + 1 is an even number with more than 4 divisors. - David A. Corneth, Oct 15 2024

Examples

			14 = 2*4 + 2 + 4.
15 = 3*3 + 3 + 3.
There is no way to express 16 in this form, so it is not in the sequence.
		

Crossrefs

Cf. A071904, A254636 is the complement.

Programs

  • Maple
    filter:= proc(n) local t;
      if n::odd then numtheory:-tau(n+1) > 4 else not isprime(n+1) fi
    end proc:
    select(filter, [$1..200]); # Robert Israel, Nov 14 2024
  • Mathematica
    sol[t_] := Solve[x >= y > 1 && x y + x + y == t, {x, y}, Integers];
    Select[Range[200], sol[#] != {}&] (* Jean-François Alcover, Jul 28 2020 *)
  • Python
    def aupto(limit):
        cands = range(2, limit//3+1)
        nums = [x*y+x+y for i, y in enumerate(cands) for x in cands[i:]]
        return sorted(set(k for k in nums if k <= limit))
    print(aupto(113)) # Michael S. Branicky, Aug 11 2021
    
  • Python
    from sympy import primepi
    def A254671(n):
        def f(x): return int(n+(x>=7)+primepi(x+1)+primepi(x+1>>1))
        m, k = n, f(n)
        while m != k: m, k = k, f(k)
        return m # Chai Wah Wu, Oct 14 2024