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.

Showing 1-3 of 3 results.

A125237 Numbers n for which the absolute value of the abundance of both n and n^2 is a prime number.

Original entry on oeis.org

3, 9, 10, 18, 50, 100, 104, 121, 136, 289, 464, 576, 650, 900, 5041, 6962, 7225, 10201, 14400, 55225, 65025, 87025, 102152, 147456, 171698, 174050, 179776, 182329, 189225, 201601, 222784, 291848, 312481, 380689, 410881, 469225, 481636, 488601
Offset: 1

Views

Author

Jason G. Wurtzel, Nov 25 2006

Keywords

Examples

			n=3: The abundance of 3 is -2, the negative of a prime. n^2=9, the abundance of 9 is -5, the negative of a prime as well.
		

Crossrefs

Programs

  • Mathematica
    pQ[n_] := PrimeQ[DivisorSigma[1, n] - 2n]; Select[Range[10^4], pQ[#] && pQ[#^2] &] (* Amiram Eldar, Sep 24 2019 *)
  • PARI
    {for(n=1, 500000, if(isprime(abs(sigma(n)-2*n)) && isprime(abs(sigma(n^2)-2*n^2)), print1(n, ",")))} \\ Klaus Brockhaus, Nov 25 2006

Extensions

More terms from Klaus Brockhaus, Nov 25 2006

A124109 Numbers whose abundance (A033880) or deficiency (A033879) is a semiprime number.

Original entry on oeis.org

5, 7, 11, 12, 14, 15, 21, 23, 26, 27, 34, 35, 39, 40, 44, 47, 52, 55, 57, 58, 59, 63, 65, 68, 70, 72, 74, 75, 77, 80, 82, 83, 85, 88, 93, 98, 107, 110, 115, 116, 119, 122, 125, 129, 133, 143, 144, 152, 155, 160, 162, 164, 167, 169, 171, 178, 179, 183, 185, 187, 189
Offset: 1

Views

Author

Jonathan Vos Post, Nov 26 2006

Keywords

Comments

If p is prime, then the only divisors of p are 1 and p, so sigma(p) = p + 1 and abundance(p) = abs(sigma(p) - 2*p) = abs((p+1) - 2*p) = abs(1-p) = p-1. Hence this sequence includes all values of the sequence of the primes which are one more than semiprimes. This is identical to A005385 Safe primes p: (p-1)/2 is also prime [then (p-1)/2 is called a Sophie Germain prime: see A005384] since as Zak Seidov commented, this is identical to primes p such that p-1 is a semiprime]. But the current sequence also contains composites, such as a(4) = 12, a(5) = 14, a(6) = 15 and a(7) = 21. If k = p*q is a semiprime (with p and q distinct primes) then the only divisors of k are 1, p, q and p*q, so sigma(k) = 1 + p + q + p*q and abs(abundance(k)) = abs(1 + p + q + p*q - p*q) = abs(1 + p + q) and these are in the sequence if 1 + p + q is semiprime. Note that numbers can be in the sequence which are neither prime nor semiprime, starting with a(4) = 12 and a(10) = 27.

Examples

			a(1) = 5 because abs(sigma(5) - 2*5) = abs(6-10) = abs(-4) = 4 = 2^2 is semiprime.
a(2) = 7 because abs(sigma(7) - 2*7) = abs(8-14) = abs(-6) = 6 = 2 * 3 is semiprime.
a(3) = 11 because abs(sigma(11) - 2*11) = abs(12-22) = abs(-10) = 10 = 2 * 5 is semiprime.
a(4) = 12 because abs(sigma(12) - 2*12) = abs(28-24) = abs(-4) = 4 = 2^2 is semiprime.
a(5) = 14 because abs(sigma(14) - 2*14) = abs(24-28) = abs(+4) = 4 = 2^2 is semiprime.
a(6) = 15 because abs(sigma(15) - 2*15) = abs(24-30) = abs(-6) = 6 = 2 * 3 is semiprime.
a(7) = 21 because abs(sigma(21) - 2*21) = abs(32-42) = abs(-10) = 10 = 2 * 5 is semiprime.
a(8) = 23 because abs(sigma(23) - 2*23) = abs(24-46) = abs(-22) = 22 = 2 * 11 is semiprime.
		

Crossrefs

Programs

  • Mathematica
    semiPrimeQ[n_] := Plus @@ Last /@ FactorInteger@n == 2; Select[ Range@ 193, semiPrimeQ@Abs[DivisorSigma[1, # ] - 2# ] &] (* Robert G. Wilson v *)

Formula

Abs[sigma(a(n)) - 2*a(n)] is a semiprime, where sigma(k) = sum of divisors of k. {Abs[sigma(a(n)) - 2*a(n)]} is in A001358.

Extensions

More terms from Robert G. Wilson v, Nov 29 2006

A125249 Numbers n for which the absolute values of the abundances of n, n^2 and n^3 are all prime numbers.

Original entry on oeis.org

289, 201601, 222784, 638401, 868562, 910116, 4694048, 4950625, 8994001, 9054081, 19855936, 30085225, 32385152, 47623801, 55100929, 72182016, 78952178, 85099058, 86303522, 91910569, 104040000, 105678400, 111175936, 112530002, 128504896, 133702969, 193043236, 204404209, 216001809, 237961476
Offset: 1

Views

Author

Jason G. Wurtzel, Nov 26 2006

Keywords

Examples

			n=289; The abundance of 289 is -271, the abundance of 83521 (289^2) is -78301, the abundance of 24137569 (289^3) is -22628971 - all of which are negatives of primes.
		

Crossrefs

Programs

  • PARI
    {for(n=1,1000000,if(isprime(abs(sigma(n)-2*n))&&isprime(abs(sigma(n^2)-2*n^2))&&isprime(abs(sigma(n^3)-2*n^3)),print1(n,",")))}

Extensions

More terms from Stefan Steinerberger, May 29 2007
a(21)-a(24) from Donovan Johnson, Feb 19 2009
a(25)-a(30) from Jason G. Wurtzel, Sep 24 2014
Showing 1-3 of 3 results.