![]() |
![]() |
#1 |
Mar 2010
1101112 Posts |
![]()
Playing around with number sequences, I started factoring factorial subtractions - n!-(n-1)!-(n-2)!-...-1!. It's clear there's a pattern in the numbers but my algebra is too rusty to figure it out. For n>=11 it's 3^2*11*m. Anyone have a simplified formula?
|
![]() |
![]() |
![]() |
#2 |
"Robert Gerbicz"
Oct 2005
Hungary
2×7×103 Posts |
![]() |
![]() |
![]() |
![]() |
#3 |
Basketry That Evening!
"Bunslow the Bold"
Jun 2011
40<A<43 -89<O<-88
3×29×83 Posts |
![]()
a(n) = n! - (n-1)! - ...
a(n+1) = (n+1)! - n! - (n-1)! - ... = a(n) + (n+1)! - 2*n! = a(n) + n!*[(n+1) - 2] = a(n) + (n-1)*n! a(n) = a(n-1) + (n-2)*(n-1)! = (n-2)*(n-1)! + (n-3)*(n-2)! + a(n-2) = ... a(1) = 1! = 1 a(2) = 2! - 1! = 1 a(2) = a(1) + 0*1! = 1 + 0 = 1, good a(3) = 3! - 2! - 1! = 6 - 2 - 1 = 3 a(3) = 1*2! + 0*1! + a(1) = 2 + 0 + 1 = 3, good => a(n) = 1 + a(n) = 1 + ... n! + (n-1)! + ... = Last fiddled with by Dubslow on 2012-11-20 at 21:36 |
![]() |
![]() |
![]() |
#4 | |
"Forget I exist"
Jul 2009
Dumbassville
26·131 Posts |
![]() Quote:
a(3) = 3!-2!-1! = 3 a(4) = 4!-3!-2!-1! = 15 the lime is the same, the sign on 3! has opposite indicating a change from 1 to -1 (-1)-1=-2 the coefficient I give the other change is the addition of 4! , n=4 so n!-2*(n-1)! is the difference: Code:
a=[1];for(x=1,100,a=concat(a,a[#a]+(#a+1)!-2*eval(#a)!));a Last fiddled with by science_man_88 on 2012-11-20 at 22:04 |
|
![]() |
![]() |
![]() |
#5 |
Basketry That Evening!
"Bunslow the Bold"
Jun 2011
40<A<43 -89<O<-88
160658 Posts |
![]()
Of course it is, and that's what I did. n! - 2*(n-1)! = (n-1)!*(n - 2). (If you don't believe me, distribute the latter multiplication.)
Of course, the sum I reduced it to is basically no simpler than the sum of factorials at the bottom of the post. If you can sum that, then you'll have a simple formula. PS @OP, what do you mean by m? n! ? |
![]() |
![]() |
![]() |
#6 | |
"Forget I exist"
Jul 2009
Dumbassville
838410 Posts |
![]() Quote:
Last fiddled with by science_man_88 on 2012-11-20 at 22:19 |
|
![]() |
![]() |
![]() |
#7 | |
Basketry That Evening!
"Bunslow the Bold"
Jun 2011
40<A<43 -89<O<-88
3·29·83 Posts |
![]() Quote:
Then a(n) = n! - F(n-1), so finding a formula for F would produce an easy formula for a. Of course, as I showed by reducing a(n) to a simpler series, that manner is no more promising than finding a formula for F itself. In shorter words, finding a simple formula for both F and a is, AFAICT, essentially equivalent. That's what I was trying to say in my previous post. |
|
![]() |
![]() |
![]() |
#8 | |
"Forget I exist"
Jul 2009
Dumbassville
26×131 Posts |
![]() Quote:
|
|
![]() |
![]() |
![]() |
#9 | |
Basketry That Evening!
"Bunslow the Bold"
Jun 2011
40<A<43 -89<O<-88
3×29×83 Posts |
![]() Quote:
PS: Sums of factorials. (Hardly a simple form.) Last fiddled with by Dubslow on 2012-11-20 at 23:15 |
|
![]() |
![]() |
![]() |
#10 | |
"Forget I exist"
Jul 2009
Dumbassville
203008 Posts |
![]() Quote:
|
|
![]() |
![]() |
![]() |
#11 |
Romulan Interpreter
Jun 2011
Thailand
220708 Posts |
![]()
He means the decomposition of a_n into factors, last factor (prime or composite) being m. He claims after n>11, all have 3^2*11 as a common factor, which is totally true, because all factorials bigger then 10 contain 9 and 11, and the sum S=1!+2!+....+10! is divisible by 9 and 11, so their sum/difference with S is too.
(edit limit) 1. because 1!+2!=3 is divisible by 3, all a(n), n>=3, will be divisible by 3 2. because 1!+2!+3!+4!+5!=152=9*17 is divisible by 3^2, all a(n), n>=6, will be divisible by 3^2 (all factorials bigger or equal with 6 contain 3^2) 3. because 1!+2!+...+10! is divisible by 3^2*11, all a(n), n>=11, will be divisible by 3^2*11 (all factorials bigger or equal with 11 contain 3^2*11) This probably happens an infinite number of times, but it is difficult to spot due to the rapid growth of a(n) series. The necessary condition is that the factorial sum s(n) to have factors lower then n, and the probability of this is higher, as n is higher. The next value where it is happening would look something like: 4. because 1!+2!+...+xxxxxx! is divisible by 3^2*11*yyy, with yyy<xxxxxx+1, then all a(n) for n>xxxxxx, will be divisible by 3^2*11*yyy (all factorials bigger then xxxxxx contain 3^2*11*yyy) (tip: you don't need to factor the sums, only to TF them with primes under n, which is very fast, and you don't need to do it sequentially, just pick a very big xxxxxx, like the binary search, and if lucky, come down by halving n. I tested s(20000) and it has not other smaller factors except 9 and 11) This only in case I don't miss some theoretic trick which forbids the factorial sums s(n) to have factors smaller than n. Last fiddled with by Batalov on 2012-11-21 at 04:33 Reason: (merged) |
![]() |
![]() |