# Math Help - Permutations.

1. ## Permutations.

Hello

This is my first post.

The question I'm working on is, 'All the digits of a number are different, the first digit is not zero, and the sum of the digits is 36. There are N x 7! such numbers. What is the value of N?'

I think I have figured out that 1,9,2,8,3,7,6 gives me 7! Then there is 3,7,4,6,2,8,1,5, which gives me 8!. I can add and factor to get 9 x 7!. Now I need to include the zero. That gives me both 8 and 9 digit numbers but the zero can't be in the first place. I haven't studied permutations and am not sure how to proceed. I think I would do 8! and 9! respectively and subtract something but I can't get my head around that difference.

If someone could point me in the right direction it would be very much apprecaited.

Thank you.

2. ## Re: Permutations.

Originally Posted by Furyan
'All the digits of a number are different, the first digit is not zero, and the sum of the digits is 36.
I need some clarification.
The digits $9876510$ add up to 36.
There are $6\cdot 6!$ arrangements of those digits that do not start with 0.
Is that what you are working on?

3. ## Re: Permutations.

Plato, thank you very much for taking the time to reply. It's very helpful. Yes that is what I am working on. I thought that perhaps I had not yet found all the combinations of different digits with a sum of 36, but the zero was bothering me more, thank you for the pointer. I will check I haven't missed any other combinations. May I ask, is the number of arrangements of n different digits, when one of the digits cannot be in one place, (n-1) (n-1)!?

4. ## Re: Permutations.

Originally Posted by Furyan
May I ask, is the number of arrangements of n different digits, when one of the digits cannot be in one place, (n-1) (n-1)!?
The longest string is $876543210$ and there are $8\cdot8!~$ rearrangements which do not have a leading zero.

5. ## Re: Permutations.

Plato, thank you for very much for all your help. Am I right in thinking that 9876510, from your previous post, is the shortest string?

6. ## Re: Permutations.

Originally Posted by Furyan
Plato, thank you for very much for all your help. Am I right in thinking that 9876510, from your previous post, is the shortest string?
No you are not.
The string $987651$ also works.

7. ## Re: Permutations.

I see. I am extremely grateful your help. I will check with you once I think I have found the value of N.

Thank you

8. ## Re: Permutations.

Hello Plato

Thanks to you I was able to finish the problem.
I certainly had missed a few combinations and should have given it more thought before posting originally!

I got:

87654321
9876321
9875421
9865431
9765432
987651
987642
987543

8! + (4)(7!) + (3)(6!)

876543210
98763210
98754210
98654310
97654320
9876510
9876420
9875430

(8)8! + (28)(7!) + (18)(6!)

Arrangements:

(9)8! + (32)(7!) + (21)(6!)

7![(9)(8) +32 +3]

7!(107)

N = 107

Thanks again for your help.