login
A147673
a(n) = a(n-2) + prime(n) + 8 for n>3, a(0..3) = (0,2,3,10): BRIDGE transform of the primes A000040.
2
0, 2, 3, 10, 18, 29, 39, 54, 66, 85, 103, 124, 148, 173, 199, 228, 260, 295, 329, 370, 408, 451, 495, 542, 592, 647, 701, 758, 816, 875, 937, 1010, 1076, 1155, 1223, 1312, 1382, 1477, 1553, 1652, 1734, 1839, 1923, 2038, 2124, 2243, 2331, 2462, 2562, 2697, 2799
OFFSET
0,2
COMMENTS
The BRIDGE transform of an increasing sequence is defined in A147672. The name comes from the puzzle "Crossing the bridge", cf. link, example and A147672.
LINKS
National Science Teachers Association, Quantum CyberTeaser Archive #B205, May/June 1997
EXAMPLE
a(4) = 18 = 3 +2 +7 +3 +3 is the time required to cross the bridge for a boy, his sister, his father and his mother if they require 2, 3, 5, 7 minutes, respectively, to cross the bridge individually (using the moves B + G, B, M + F, G, B + G).
MATHEMATICA
A147673[n_]:= A147673[n]= If[n<4, Fibonacci[n]*Fibonacci[n+2], A147673[n-2] +Prime[n] +8];
Table[A147673[n], {n, 0, 70}] (* G. C. Greubel, Dec 02 2025 *)
PROG
(PARI)
BRIDGE( a )={ local( s=vector(#a), t ); vector( #a, n, t=vecsort( vecextract( a, 2^n-1 )); t[n]+if( n>3, t[1]+2*t[2]+BRIDGE( vecextract( t, 2^(n-2)-1 ))[n-2], if(n==3, t[1]+t[2] ))) }
A147673 = BRIDGE( vector( 20, n, prime(n)))
(PARI)
a=[2, 3, 10]; for( n=4, 90, a=concat(a, a[n-2]+prime(n)+8)); a
(Magma)
A147673:= function(n)
if n le 3 then return Fibonacci(n)*Fibonacci(n+2);
else return $$(n-2) +NthPrime(n) +8;
end if;
end function;
[A147673(n): n in [0..70]]; // G. C. Greubel, Dec 02 2025
(SageMath)
def A147673(n):
if n<4: return (0, 2, 3, 10)[n]
else: return A147673(n-2) +nth_prime(n) +8
print([A147673(n) for n in range(71)]) # G. C. Greubel, Dec 02 2025
CROSSREFS
Cf. A147672.
Sequence in context: A339924 A333673 A070253 * A298345 A057507 A233895
KEYWORD
nonn
AUTHOR
M. F. Hasler, Nov 10 2008
STATUS
approved