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!)
A059583 Each c(i) is "multiply" (*) or "divide" (/); a(n) is number of choices for c(1),..,c(n) so that the reduced fraction 1 c(1) 2 c(2) 3 c(3) 5 ... c(n) prime(n) is equal to (k*m+1)/m for a positive integer m and a nonnegative integer k. 1
1, 2, 4, 5, 6, 6, 6, 3, 5, 6, 7, 9, 8, 7, 7, 9, 6, 8, 6, 9, 6, 8, 9, 12, 11, 5, 9, 8, 7, 7, 11, 9, 11, 11, 9, 10 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,2
LINKS
Sean A. Irvine, Java program (github)
EXAMPLE
For n = 4 there are five possibilities: 1/2/3/5/7 = 1/210, 1/2*3/5*7 = 21/10, 1/2*3*5/7 = 15/14, 1/2*3*5*7 = 105/2, and 1*2/3*5*7 = 70/3. So a(4) = 5.
PROG
(Python)
from math import prod
from itertools import combinations
from sympy import prime, primerange
def a(n):
pset = set(primerange(2, prime(n)+1))
m, c = prod(pset), 1 # count 1/2/3/.../prime(n)
for r in range(1, len(pset)):
first = 1
for dens in combinations(pset, r):
den = prod(dens)
num = m//den
if dens[0] != first:
if den > num: break
first = dens[0]
if num%den == 1: c += 1
return c
print([a(n) for n in range(1, 21)]) # Michael S. Branicky, Sep 30 2022
CROSSREFS
Sequence in context: A123124 A166236 A291768 * A086370 A083788 A058317
KEYWORD
nonn,more
AUTHOR
Naohiro Nomoto, Feb 17 2001
EXTENSIONS
More terms from Sascha Kurz, Oct 16 2001
a(34)-a(36) from Sean A. Irvine, Sep 29 2022
Definition clarified by N. J. A. Sloane, Oct 01 2022
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 April 25 12:28 EDT 2024. Contains 371969 sequences. (Running on oeis4.)