# Greetings from The On-Line Encyclopedia of Integer Sequences! http://oeis.org/ Search: id:a117481 Showing 1-1 of 1 %I A117481 #23 Dec 17 2021 16:57:29 %S A117481 1,2,6,12,60,30,210,56,504,5040,55440,132,1716,182,2730,43680,742560, %T A117481 306,5814,380,7980,175560,4037880,552,13800,358800,9687600,271252800, %U A117481 7866331200,870,26970,992,32736,1113024,38955840,1402410240,51889178880 %N A117481 a(n) = n*(n-1)*(n-2)*(n-3)*...*(n-k) such that (n-k) is the largest prime smaller than n. %H A117481 Amiram Eldar, Table of n, a(n) for n = 1..10000 %F A117481 a(n) = Product_{k = prevprime(n)..n} k, for n>=3 with a(1)=1, a(2)=2 and where prevprime = A151799. - _Wesley Ivan Hurt_, Dec 12 2021 %e A117481 a(10) = 10*9*8*7 = 5040 because 7 is the largest prime smaller than 10. %t A117481 a[1] = 1; a[2] = 2; a[n_] := n!/(NextPrime[n, -1] - 1)!; Array[a, 30] (* _Amiram Eldar_, Feb 08 2021 *) %o A117481 (PARI) a(n) = if (n<=2, n, prod(k=0, n-precprime(n-1), n-k)); \\ _Michel Marcus_, Feb 09 2021 %Y A117481 Cf. A151799 (prevprime v.2), A286900 (sum of the numbers from n to nextprime(n)). %K A117481 nonn,look %O A117481 1,2 %A A117481 Luc Stevens (lms022(AT)yahoo.com), Apr 25 2006 %E A117481 Offset and a(36) corrected by _Amiram Eldar_, Feb 08 2021 # Content is available under The OEIS End-User License Agreement: http://oeis.org/LICENSE