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.

A179435 For positive n with prime decomposition n = Product_{j=1..m} (p_j^k_j) define a_n = Sum_{j=1..m} (p_j*k_j) and b_n = Sum_{j=1..m} (p_j^k_j). This sequence gives those n for which a_n and b_n are both prime and unequal.

Original entry on oeis.org

40, 48, 54, 88, 108, 184, 250, 384, 424, 432, 448, 808, 864, 1048, 1216, 1384, 1528, 1575, 1680, 1792, 1864, 1890, 2104, 2184, 2457, 2925, 2944, 3080, 3120, 3328, 3510, 3696, 3712, 3915, 4125, 4158, 4288, 4504, 4744, 4950, 5224, 5488, 5632, 5928, 5940, 6240
Offset: 1

Views

Author

Bobby Browning and Rohan Hemasinha (rhemasin(AT)uwf.edu), Jan 07 2011

Keywords

Comments

Is the sequence infinite?
Odd terms in the sequence are: a(18) = 1575, a(25) = 2457, a(26) = 2925, a(34) = 3915, a(35) = 4125, a(47) = 6345, a(50) = 6669, ...

Examples

			a(1) = 40 = 2^3*5^1, with a = 11 and b = 13.
a(2) = 48 = 2^4*3^1, with a = 11 and b = 19.
Notice that a and b are both prime and not equal.
		

Programs

  • Maple
    a:= proc(n) option remember; local an, bn, k, l;
          for k from 1 +`if`(n=1, 0, a(n-1)) do
            l:= ifactors(k)[2];
            an:= add( i[1] * i[2], i=l);
            bn:= add( i[1] ^ i[2], i=l);
            if isprime(an) and isprime(bn) and an<>bn then break fi
          od; k
        end:
    seq(a(n), n=1..50);  # Alois P. Heinz, Jan 20 2011
  • Mathematica
    a[n_] := a[n] = Module[{an, bn, k, p, e}, For[k = 1 + If[n==1, 0, a[n-1]], True, k++, {p, e} = Transpose[FactorInteger[k]]; an = p.e; bn = Total[p^e]; If[PrimeQ[an] && PrimeQ[bn] && an != bn, Break[]]]; k];
    Array[a, 50] (* Jean-François Alcover, Nov 20 2020 *)

Extensions

More terms from Alois P. Heinz, Jan 20 2011