Take the 2-minute tour ×
Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

Let S be the set $\{0!, 1!, 2!, \ldots\}$. Is it possible to construct any positive integer using only addition, subtraction and multiplication, and using any element in S at most once? For example:

$$ 3 = 2! + 1!$$ $$ 4 = 3! - 2! = 2! + 1! + 0!$$ $$ 146 = 4!\cdot3! + 2!$$

etc. My gut instinct says that this isn't true, but I can't see why. Something like 8076 doesn't have an obvious solution, but maybe you can get it by subtraction a huge factorial from the product of two smaller factorials or something. Or maybe there's a way of finding sets of factorials that add/subtract/multiply to 1, in which case any number can be constructed this way. I've tried finding something but haven't had much luck.

EDIT: Oops, positive integer, not positive number.

share|improve this question
1  
Do you mean positive integer? Any positive even integer can be written as the sum of $2!$s, and any positive odd integer is $1!$ plus some nonnegative even integer. –  user17794 Jul 23 '12 at 19:31
2  
@TimDuff: "and using any element in $S$ at most once"; so you can only use 2! at most once. –  Arturo Magidin Jul 23 '12 at 19:32
1  
Do you allow the use of parens? –  ncmathsadist Jul 23 '12 at 19:40
1  
Note, since $0!=1!$, it isn't technically a "set" if you mean you can use $0!$ and $1!$. Just a minor language nit. –  Thomas Andrews Jul 23 '12 at 19:42
2  
@EricStucky No, he explicitly uses 0! and 1! in one of his examples, so he clearly means something like, "Express every natural number in terms of the sequence 0!,1!,...,k!,... with each term used at most once." –  Thomas Andrews Jul 23 '12 at 20:07
show 4 more comments

3 Answers 3

up vote 17 down vote accepted

Let me assume you're only allowed to use $0! = 1!$ once. In that case, all factorials past $4!$ are divisible by $24$, so working $\bmod 24$ the only numbers you're allowed to use are $1, 2, 6$, each at most once, and I am reasonably certain you cannot get any numbers congruent to $10 \bmod 24$ this way.

Edit: If you want to use both $0!$ and $1$, then all factorials past $5!$ are divisible by $120$, so working $\bmod 120$ the only numbers you're allowed to use are $1, 1, 2, 6, 24$. This time I am reasonably certain you cannot get any numbers congruent to $57 \bmod 120$. Just kidding! Every conjugacy class $\bmod 120$ is reachable.

Okay, working $\bmod 720$ the only numbers you're allowed to use are $1, 1, 2, 6, 24, 120$...

share|improve this answer
1  
for example $10=4!-2!*(3!+1!)$. But I'm not sure whether we were allowed to use parentheses –  Tigran Hakobyan Jul 23 '12 at 20:16
4  
1+6+2*(24+1)=57 –  Colin McQuillan Jul 23 '12 at 21:43
6  
@mjqxxxx: I just ran a (hopefully) exhaustive search, and it seems there's no way to obtain the numbers 352, 356, 364 or 368 modulo 720 from 1, 1, 2, 6, 24 and 120 using addition, multiplication and negation. –  Ilmari Karonen Jul 23 '12 at 22:34
2  
I got the same result [352,356,364,368] with this code: hpaste.org/72038 –  Colin McQuillan Jul 23 '12 at 23:07
1  
@Belgi: well, it suffices to get the first $60$. You can get $0$ through $19$ without using $24$, so by reusing all of those representations you can get $0$ through $43$ by using $24$. Then I checked $44$ through $60$... –  Qiaochu Yuan Jul 23 '12 at 23:48
show 10 more comments

Relaxing your restriction using each factorial at most once, you may find the following helpful. For every positive integer $n$ there is a positive integer $k$ and $k$ positive integers $\{c_1, \dots, c_k \}$ such that $n$ has a unique representation in the factorial basis, \begin{align} n = \sum_{l = 1}^{k} c_{l} \ l!. \end{align}

share|improve this answer
6  
He wants to use each number at most once –  Thomas Andrews Jul 23 '12 at 20:18
add comment

The numbers you can construct are of the form $\sum_{j=0}^nc_jj!$ with $c_j\in\{-1,\,0,\,+1\}$. Imagine you want to construct a number smaller than $4165$. Since $7!-\sum_{j=0}^6j!=4166$, you can only use the numbers $k!$ with $0\leq k\leq 6$. That's $7$ numbers. Using your formula you can construct $3^7=2187$ numbers this way. Sadly, $2187<4165$ so the answer is no.

share|improve this answer
    
I like this line of thought, but you can also multiply factorials together, so there'll be more than 2187 combinations. –  Hovercouch Feb 28 at 18:13
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.