in Combinatory
1,998 views
2 votes
2 votes
The number of ways to roll 5 six sided dice to get sum of 25 is ________.

_________________________________________________________

if solving with generating function, then why dividing by $\left ( 1-x \right )$ if equation is $\frac{x\left ( 1-x^{6} \right )}{\left ( 1-x \right )}$?
in Combinatory
by
2.0k views

4 Comments

no, there is some logic I forgotten now

like sometimes we use

$\left ( \frac{1}{1-x} \right )$

and sometime $\left ( \frac{(1-x^{someting})}{1-x} \right )$

I forgotten the logic now
0
0
edited by
  • The sum of infinite terms of a GP series S∞= a/(1-r) where |r|<1.
  • The formula applied to calculate sum of first n terms of a GP:
2
2
^ -1<r<1
0
0

2 Answers

4 votes
4 votes
Best answer

$[x^{25}] (x^1 + x^2 + x^3 + x^4 + x^5 + x^6)(x^1 + x^2 + x^3 + x^4 + x^5 + x^6)(x^1 + x^2 + x^3 + x^4 + x^5 + x^6)(x^1 + x^2 + x^3 + x^4 + x^5 + x^6)(x^1 + x^2 + x^3 + x^4 + x^5 + x^6)$

 

$[x^{25}] (x^1 + x^2 + x^3 + x^4 + x^5 + x^6)^5$

$[x^{25}] x^5(x^0 + x^1 + x^2 + x^3 + x^4 + x^5)^5$

$[x^{20}] (x^0 + x^1 + x^2 + x^3 + x^4 + x^5)^5$

$[x^{20}] (1 + x^1 + x^2 + x^3 + x^4 + x^5)^5$

$[x^{20}] \large  (\frac{1 - x^6}{1 -x })^5$

 

$[x^{20}] \large (1 - x^6)^5(1 -x )^{-5}$

$\sum_{r=0}^{5}\ ^5C_r(-x^6)^r \times \sum_{r=0}^{\infty }\ ^{4+r}C_r(x^r)$

$\Rightarrow  \Large\binom{5}{0} \binom{-5}{20} + (-1) \binom{5}{1} \binom{-5}{14} + \binom{5}{2}\binom{-5}{8} + (-1) \binom{5}{3}\binom{-5}{2}$

$\Rightarrow \binom{24}{20} - 5\binom{18}{14} + 10\binom{12}{8} - 10 \binom{6}{2}$

$\Rightarrow 10626 - 5(3060) + 4950 -150$

$\Rightarrow \large 126$

 

Note:

$\large (1+x^r)^n= \sum_{k=0}^{n} \binom n k (x)^{rk}$

$\large (1 - x)^{-n} = \sum_{k =0}^{n} \binom{n + k -1}{k} x^k$

edited by

4 Comments

what is meaning of $\binom{-5}{20}$
0
0

choosing 20 from -5. Seems impossible but works fine.

$\large \binom{-n}{k} = \binom{n + k - 1}{k}$

check https://youtu.be/ZyUb5UxBA9Q?t=318

1
1
yes I made mistake in 3rd term

thanks :)
0
0

@Mk Utkarsh

Chk it once,

will it be $\binom{24}{20}$ or $\binom{25}{20}$??

and $\binom{18}{14}$ or $\binom{19}{14}??$

0
0
2 votes
2 votes
$[x^{25}] (x^1 + x^2 + x^3 + x^4 + x^5 + x^6)(x^1 + x^2 + x^3 + x^4 + x^5 + x^6)(x^1 + x^2 + x^3 + x^4 + x^5 + x^6)(x^1 + x^2 + x^3 + x^4 + x^5 + x^6)(x^1 + x^2 + x^3 + x^4 + x^5 + x^6)$

 

$[x^{25}] (x^1 + x^2 + x^3 + x^4 + x^5 + x^6)^5$

$[x^{25}] x^5(x^0 + x^1 + x^2 + x^3 + x^4 + x^5)^5$

$[x^{20}] (x^0 + x^1 + x^2 + x^3 + x^4 + x^5)^5$

$[x^{20}] (1 + x^1 + x^2 + x^3 + x^4 + x^5)^5$

so now the equation is,

$x_1 + x_2 + x_3 + x_4 + x_5 = 20, (\  0  \leq x_1 \leq 5,0 \ \leq x_2 \leq 5,0  \leq x_3 \leq 5,0  \leq x_4 \leq 5, \ 0 \leq x_5 \leq 5  )$

Total possible solutions = $\large \binom{24}{4}$

Total valid solutions = total solutions - invalid solutions

So we'll try to calculate all invalid solutions,

let $x_1 \geq 6$

$x_1 + 6 + x_2 + x_3 + x_4 + x_5 = 20$

$x_1 + x_2 + x_3 + x_4 + x_5 = 20 - 6$

$x_1 + x_2 + x_3 + x_4 + x_5 = 14$

so number of invalid solutions where  $x_1 \geq 6$ = $\large \binom{18}{4}$

so the number of invalid solutions where any one of $x_i \geq 6 =$ $\large 5 \times \binom{18}{4} = $$15300$

Now we'll calculate the number of ways $x_1 \geq 6$ and $x_2 \geq 6$

$x_1 + 6 + x_2  + 6 + x_3 + x_4 + x_5 = 20$

$x_1 + x_2  + x_3 + x_4 + x_5 = 8$

so number of invalid solutions = $\large \binom{12}{4}$

but this was only when we put constrain on $x_1$ and $x_2$ but there can be $\binom{5}{2} = 10$ combinations.

So possible combinations = $10 \times \large \binom{12}{4} = 4950$

Now we'll calculate the number of ways $x_1 \geq 6$, $x_2 \geq 6$ and $x_3 \geq 6$,

$x_1 + 6 + x_2  + 6 + x_3 + 6 + x_4 + x_5 = 20$

$x_1 + x_2  + x_3 + x_4 + x_5 = 2$

similarly there are $\binom{5}{3} = 10$ combinations.

So possible combinations = $10 \times \large \binom{6}{4} = 150$

Now we cannot go further finding invalid solutions because 4 variable at once cannot $\geq 6$ all at once.

So total invalid solutions = $15300 - 4950 + 150 = 10500$

Total valid solutions = $\large \binom{24}{4} - $$13560 = \large \color{blue}{ 126}$
edited by

3 Comments

Questions solved using same concept

https://gateoverflow.in/265932/ace-book?show=266296#a266296

https://gateoverflow.in/266131/rosen?show=266248#a266248

Sorry i missed some words to explain it in more detail but if these two links above can help. Also comment down if i missed something or if there is any confusion.

0
0
check after this line I have done like this

$[x^{20}] (x^0 + x^1 + x^2 + x^3 + x^4 + x^5)^5$

$=\left [ x^{20} \right ]\left ( \frac{1-x^{6}}{1-x} \right )^{5}$

$\left ( 1-x^{6} \right )^{5}=1-5x^{6}+\frac{5.4}{2}.x^{12}-10x^{18}+....$

$\left ( 1-x\right )^{-5}=1+5x+15x^{2} +35x^{3}+....$

                      =$\frac{5.6.7......24}{20!}-5.\frac{5.6.7....18}{14!}+10.\frac{5.6.....10}{6!}-10.\frac{5.6}{2!}$

but it is coming -ve :(
0
0

srestha solved using gen functions

0
0

Related questions

1 vote
1 vote
2 answers
2
Quick search syntax
tags tag:apple
author user:martin
title title:apple
content content:apple
exclude -tag:apple
force match +apple
views views:100
score score:10
answers answers:2
is accepted isaccepted:true
is closed isclosed:true