Find the number of positive integral solutions to x + 2 y + 3 z = 1 0 0 .
This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try
refreshing the page, (b) enabling javascript if it is disabled on your browser and,
finally, (c)
loading the
non-javascript version of this page
. We're sorry about the hassle.
Bonus question: prove that the number of solutions in positive integers to the equation x + 2 y + 3 z = N is given by
1 2 1 ( N 2 − 6 N + C N )
where
C N = ⎩ ⎪ ⎪ ⎪ ⎪ ⎪ ⎪ ⎪ ⎪ ⎨ ⎪ ⎪ ⎪ ⎪ ⎪ ⎪ ⎪ ⎪ ⎧ 1 2 5 8 9 8 5 when N ≡ 0 ( m o d 6 ) when N ≡ 1 ( m o d 6 ) when N ≡ 2 ( m o d 6 ) when N ≡ 3 ( m o d 6 ) when N ≡ 4 ( m o d 6 ) when N ≡ 5 ( m o d 6 )
I feel bad :(
I did the question but in the excitement I did calculation wrong. I multiplied 17 × 8 = 132
It is 136 :( :( :(
But this question is very good and alot intuitive. I like it
The code below returns the value of 784
1 2 3 4 5 6 7 8 9 10 |
|
Output: 784 solutions
Range constraints for x,y, and z easily shown to include minimum and maximum values for solutions to this equation.
Problem Loading...
Note Loading...
Set Loading...
Consider 3 z + 2 y + x = 1 0 0 . We note that for a fixed z and y , there is only one x . Therefore we only need to consider n ( z ) , the number of solutions of y for a fixed z . And n ( z ) is equal to the largest possible y for the fixed z . That is n ( z ) = max ( y ( z ) ) = 2 1 0 0 − 3 z − min ( x ) . Since the R H S = 1 0 0 is even, this implies that when z is odd, x is odd and when z is even, x is even.
Therefore, min ( x ) = { 1 2 when z is odd. when z is even. ⟹ n ( z ) = ⎩ ⎪ ⎨ ⎪ ⎧ 2 9 9 − 3 z 2 9 8 − 3 z when z is odd. when z is even.
Since z ∈ [ 1 , 3 2 ] the number of positive integer solutions to the equation is:
z = 1 ∑ 3 2 n ( z ) = k = 1 ∑ 1 6 ( 2 9 9 − 3 ( 2 k − 1 ) + 2 9 8 − 3 ( 2 k ) ) = k = 1 ∑ 1 6 ( 1 0 0 − 6 k ) = 1 6 0 0 − 2 6 ( 1 6 ) ( 1 7 ) = 7 8 4