|
|
A280871
|
|
Denominator of the mediant of prime(n) / prime(n+1) and prime(n+2) / prime(n+3).
|
|
2
|
|
|
10, 8, 5, 7, 8, 5, 6, 9, 11, 12, 10, 11, 12, 53, 57, 21, 22, 35, 15, 26, 14, 15, 19, 20, 26, 53, 55, 59, 61, 66, 45, 143, 145, 153, 157, 162, 28, 173, 177, 185, 187, 194, 98, 51, 211, 219, 226, 115, 117, 79, 245, 249, 257, 263, 267, 91, 92, 70, 41, 295, 302
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,1
|
|
COMMENTS
|
The mediant of two reduced proper fractions a/b and c/d is (a+c)/(b+d), the value of which is strictly between a/b and c/d.
|
|
LINKS
|
|
|
EXAMPLE
|
The mediant of 2/3 and 5/7 is 7/10.
|
|
MATHEMATICA
|
Map[Denominator[(#1 + #3)/(#2 + #4)] & @@ # &, Partition[Prime@ Range[64], 4, 1]] (* Michael De Vlieger, Oct 08 2021 *)
|
|
PROG
|
(PARI) vector(100, n, denominator((prime(n)+prime(n+2)) / (prime(n+1)+prime(n+3))))
(Python)
from math import gcd
from sympy import nextprime
def aupton(terms):
alst, p, q, r, s = [], 2, 3, 5, 7
while len(alst) < terms:
alst.append((q+s)//gcd(p+r, q+s))
p, q, r, s = q, r, s, nextprime(s)
return alst
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn,frac
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|