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.

A261079 Sum of index differences between prime factors of n, summed over all unordered pairs of primes present (with multiplicity) in the prime factorization of n.

Original entry on oeis.org

0, 0, 0, 0, 0, 1, 0, 0, 0, 2, 0, 2, 0, 3, 1, 0, 0, 2, 0, 4, 2, 4, 0, 3, 0, 5, 0, 6, 0, 4, 0, 0, 3, 6, 1, 4, 0, 7, 4, 6, 0, 6, 0, 8, 2, 8, 0, 4, 0, 4, 5, 10, 0, 3, 2, 9, 6, 9, 0, 7, 0, 10, 4, 0, 3, 8, 0, 12, 7, 6, 0, 6, 0, 11, 2, 14, 1, 10, 0, 8, 0, 12, 0, 10, 4, 13, 8, 12, 0, 6, 2, 16, 9, 14, 5, 5, 0, 6, 6, 8, 0, 12, 0, 15, 4, 15, 0, 6, 0, 8, 10, 12, 0, 14, 6, 18, 8, 16, 3, 10
Offset: 1

Views

Author

Antti Karttunen, Sep 23 2015

Keywords

Examples

			For n = 1 the prime factorization is empty, thus there is nothing to sum, so a(1) = 0.
For n = 6 = 2*3 = prime(1) * prime(2), a(6) = 1 because the (absolute value of) difference between prime indices of 2 and 3 is 1.
For n = 10 = 2*5 = prime(1) * prime(3), a(10) = 2 because the difference between prime indices of 2 and 5 is 2.
For n = 12 = 2*2*3 = prime(1) * prime(1) * prime(2), a(12) = 2 because the difference between prime indices of 2 and 3 is 1, and the pair (2,3) occurs twice as one can pick either one of the two 2's present in the prime factorization to be a pair of a single 3. Note that the index difference between 2 and 2 is 0, thus the pair (2,2) of prime divisors does not contribute to the sum.
For n = 36 = 2*2*3*3, a(36) = 4 because the index difference between 2 and 3 is 1, and the prime factor pair (2,3) occurs 2^2 = four times in total. As the index difference is zero between 2 and 2 as well as between 3 and 3, the pairs (2,2) and (3,3) do not contribute to the sum.
		

Crossrefs

Cf. A000720.
Cf. A000961 (positions of zeros), A006094 (positions of ones).
Cf. also A260737.
A055396 gives minimum prime index, maximum A061395.
A112798 list prime indices, length A001222, sum A056239.
A304818 adds up partial sums of reversed prime indices, row sums of A359361.
A318283 adds up partial sums of prime indices, row sums of A358136.

Programs

  • Mathematica
    Table[Function[p, Total@ Map[Function[b, Times @@ {First@ Differences@ PrimePi@ b, Count[Subsets[p, {2}], c_ /; SameQ[c, b]]}], Subsets[Union@ p, {2}]]][Flatten@ Replace[FactorInteger@ n, {p_, e_} :> ConstantArray[p, e], 2]], {n, 120}] (* Michael De Vlieger, Mar 08 2017 *)

Formula

a(n) = A304818(n) - A318283(n). - Gus Wiseman, Jan 09 2023
a(n) = 2*A304818(n) - A359362(n). - Gus Wiseman, Jan 09 2023

A261077 Semiprimes whose prime factors differ from each other in one bit position only.

Original entry on oeis.org

6, 21, 33, 35, 57, 65, 161, 185, 201, 323, 377, 393, 437, 473, 497, 713, 899, 1529, 1577, 1763, 1769, 1841, 1961, 2021, 2537, 3233, 3473, 3497, 3737, 4553, 4601, 4757, 5561, 5609, 5753, 6497, 7217, 7313, 9593, 9797, 10265, 10403, 10841, 10961, 11009, 12297, 14129, 15689, 17513, 18209, 19043, 19337, 21353, 22499, 23129, 23393, 26969, 27221, 27233, 29177
Offset: 1

Views

Author

Antti Karttunen, Sep 22 2015

Keywords

Examples

			21 = 3*7 is present because 3 in binary is "11" ("011" when extended with a leading zero) and 7 in binary is "111", and these differ only in the bit-position 2 (with indexing where the least significant bit is in the position 0).
33 = 3*11 is present because 3 in binary is "11" ("0011" when extended with two leading zeros) and 11 in binary is "1011", and these differ only in the bit-position 3.
		

Crossrefs

Cf. also A261073, A261080 (subsequences).
Subsequence of A261078.
Gives the positions of ones in A260737.

Programs

A261080 Semiprimes p*q for which p and q are successive primes and their binary representations differ from each other in one bit position only.

Original entry on oeis.org

6, 35, 323, 437, 899, 1763, 2021, 4757, 9797, 10403, 19043, 22499, 27221, 38021, 39203, 72899, 79523, 95477, 99221, 131753, 145157, 154433, 164009, 205193, 210677, 213443, 250997, 272483, 324899, 381923, 412163, 416021, 455621, 549077, 557993, 594437, 656099, 675683, 736163, 741317, 777923, 783221, 826277, 870473, 881717, 974153, 1022117, 1102499, 1127843, 1238753
Offset: 1

Views

Author

Antti Karttunen, Sep 23 2015

Keywords

Comments

Numbers n for which A260737(n) = A261079(n) = 1.

Examples

			6 is included as 6 = 2*3, 2 and 3 are successive primes, and 2 (in binary "10") and 3 (in binary "11") differ by only one bit from each other.
		

Crossrefs

Intersection of A006094 and A261077.

Programs

  • Mathematica
    brdQ[{a_,b_}]:=Module[{c=IntegerDigits[a,2],d=IntegerDigits[b,2]}, Length[ c] == Length[d]&&Count[Total/@Transpose[{c,d}],1]==1]; Times@@@ Select[ Partition[Prime[Range[200]],2,1],brdQ] (* Harvey P. Dale, Jan 29 2016 *)

Formula

a(n) = A205511(n) * A205302(n).
Showing 1-3 of 3 results.