|
|
A114345
|
|
Sequence of primes based on the powers of the golden mean; see formula section for description.
|
|
1
|
|
|
2, 3, 7, 11, 17, 47, 61, 97, 173, 367, 1367, 10631, 13781, 15919, 1008001, 2584403, 4232351, 5459719, 334525987, 11779122851, 13808301271, 116757956759, 2968189088940281, 32797072183910341, 5972846330691787903, 283950392369947419799, 2969782506626449546163
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
0,1
|
|
LINKS
|
|
|
FORMULA
|
Let p(n) = floor(phi^(n/log(n))), g(n) = p(n) if (p(n) mod 2) = 0, otherwise g(n) = 0, and f(n) = f(n-1) + g(n) with f(1) = 2, f(2) = 3. Define b(n) as f(n) if f(n) is prime, then a(n) is the list of b(n) with duplicates removed.
|
|
MATHEMATICA
|
p[n_]:= Floor[GoldenRatio^(n/Log[n])];
g[n_]:= g[n]= If[Mod[p[n], 2]==0, p[n], 0];
f[n_]:= f[n]= If[n<3, n+1, f[n-1] +g[n]];
DeleteDuplicates[Table[If[PrimeQ[f[n]], f[n], {}], {n, 1000}]]//Flatten
|
|
PROG
|
(SageMath)
def p(n): return floor(golden_ratio^(n/log(n)))
def g(n): return p(n) if (p(n)%2)==0 else 0
@CachedFunction
def f(n): return n+1 if (n<3) else f(n-1) + g(n)
def b(n): return f(n) if is_prime(f(n)) else {}
set([f(n) for n in range(1, 1001) if is_prime(f(n))]) # G. C. Greubel, Aug 09 2023
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn,less
|
|
AUTHOR
|
|
|
EXTENSIONS
|
|
|
STATUS
|
approved
|
|
|
|