Svoboda | Graniru | BBC Russia | Golosameriki | Facebook
login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A369355 The smallest number such that n or more positive numbers k exist such that a(n) - k = sopfr(a(n) + k), where sopfr(m) is the sum of the primes dividing m, with repetition. 8
7, 38, 88, 348, 636, 1032, 3828, 3900, 10632, 16428, 16428, 16428, 44652, 533868, 533868, 533868, 533868, 1182432, 5218548, 7741068, 7741068, 7741068, 33764268, 43777068, 67398582, 70249668, 180911982, 180911982, 180911982, 387668532, 387668532, 387668532 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,1
COMMENTS
From David A. Corneth, Feb 13 2024, Feb 15 2024: (Start)
k may not be 0. Else a(1) = 2, a(2) = 7.
The essence of the program I put is rewriting a(n) - k = sopfr(a(n) + k) as
a(n) + k - 2k = sopfr(a(n) + k) so
a(n) + k - sopfr(a(n) + k) = 2*k.
If you like, substitute m = a(n) + k.
To then search 1 <= m <= 2*precprime(u) and keep track of frequencies values m - sopfr(m) where that outcome is even as the outcome equals 2*k.
Then find frequencies of a(n) via m - k = a(n). (End)
LINKS
EXAMPLE
a(1) = 7 as 7 is the smallest number to have one number (k = 1) such that 7 - 1 = 6 = sopfr(7 + 1) = sopfr(8) = 6.
a(2) = 38 as 38 is the smallest number to have two numbers (k = 25, 26) such that 38 - 25 = 13 = sopfr(38 + 25) = sopfr(63) = 13, and 38 - 26 = 12 = sopfr(38 + 26) = sopfr(64) = 12.
a(3) = 88 as 88 is the smallest number to have three numbers (k = 65, 68, 74) such that 88 - 65 = 23 = sopfr(88 + 65) = sopfr(153) = 23, 88 - 68 = 20 = sopfr(88 + 68) = sopfr(156) = 20, and 88 - 74 = 14 = sopfr(88 + 74) = sopfr(162) = 14.
PROG
(Python)
from sympy import factorint
from functools import cache
from itertools import count, islice
@cache
def sopfr(n): return sum(p*e for p, e in factorint(n).items())
def f(n): return sum(1 for k in range(1, n-1) if n - k == sopfr(n + k))
def agen(): # generator of terms
adict, n = dict(), 1
for m in count(2):
v = f(m)
if v not in adict: adict[v] = m
for i in range(n, v+1): yield m; n += 1
print(list(islice(agen(), 12))) # Michael S. Branicky, Feb 11 2024
(PARI)
sopf(n) = {
my(f = factor(n));
sum(i = 1, #f~, f[i, 1]*f[i, 2])
}
upto(n) = {
my(v = vector(n), res = [], u = 2*precprime(n));
for(i = 2, u,
c = i-sopf(i);
if(c%2 == 0 && 1 <= i - c/2 && i - c/2 <= n && c > 0,
v[i - c/2]++
);
);
for(i = 1, #v,
if(v[i] > #res,
res = concat(res, vector(v[i] - #res));
);
if(v[i] > 0 && res[v[i]] == 0,
res[v[i]] = i
);
);
res
} \\ David A. Corneth, Feb 13 2024
CROSSREFS
Sequence in context: A003352 A346278 A165495 * A034858 A249354 A249021
KEYWORD
nonn
AUTHOR
Scott R. Shannon, Jan 25 2024
EXTENSIONS
a(18) from Michael S. Branicky, Feb 13 2024
a(19)-a(24), a(26) from Chai Wah Wu, Feb 13 2024
a(25) from David A. Corneth, Feb 13 2024
a(27)-a(32) from Chai Wah Wu, Feb 14 2024
STATUS
approved

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

License Agreements, Terms of Use, Privacy Policy. .

Last modified September 9 12:04 EDT 2024. Contains 375764 sequences. (Running on oeis4.)