Number of positive integer solutions for given equation

In summary, the conversation discusses how to find the number of triplets of positive integers that satisfy a given equation, with different scenarios for even and odd values of n. The solution involves using combinatorics and understanding partitions and compositions.
  • #1
songoku
2,365
347

Homework Statement


Let n be an odd integer ≥ 5. Find the number of triplets (x, y, z) of positive integers which satisfy the equation
x + y + 2z = n

Homework Equations


Do not know

The Attempt at a Solution


Let n = 2k + 1, k ≥ 2

x + y + 2z = n
2z = 2k + 1 - (x + y) ≤ 2k + 1 - 2 (because x + y ≥ 2)
2z ≤ 2k - 1
Then stuck

The answer is (n - 1)(n - 3)/4

Thanks
 
Physics news on Phys.org
  • #2
Sometimes these are easiest to look at with a few examples.
If n = 5, then (1,2,1) and (2,1,1) are your only choices.
If n = 7, you have more. For z = 1, you have (1,4,1), (2,3,1),(3,2,1),(4,1,1) and for z=2 you have (1,2,2),(2,1,2).
What I see is that for any z, of which you are limited in choices, you will have an appropriate number of choices for (x+y)=n-2z.

So how many options for z?
For each of those options how many choices for y do you have? Once z and y and defined, you have only one choice for x.
 
  • Like
Likes songoku
  • #3
RUber said:
Sometimes these are easiest to look at with a few examples.
If n = 5, then (1,2,1) and (2,1,1) are your only choices.
If n = 7, you have more. For z = 1, you have (1,4,1), (2,3,1),(3,2,1),(4,1,1) and for z=2 you have (1,2,2),(2,1,2).
What I see is that for any z, of which you are limited in choices, you will have an appropriate number of choices for (x+y)=n-2z.

So how many options for z?
For each of those options how many choices for y do you have? Once z and y and defined, you have only one choice for x.

I think I get it. Thanks
 
  • #4
This is a combinatorics question, not really a pre-calculus question.

Throughout, order matters and duplicates are allowed.

How many ways are there to write n as the sum of k nonnegative integers? Answer: (n+k-1) choose (k-1). Why? Place n 1s and k-1 separators.

How many ways are there to write n as the sum of k positive integers? Answer: (n-1) choose (k-1). Why? Write n-k as the sum of k nonnegative integers and then add 1 to each of them.

Assume that n is even. How many ways are there to write n as the sum of k even positive integers? Answer: (n/2 - 1) choose (k-1). Why? Write n/2 as the sum of k positive integers and then multiply each of them by 2.

Assume that n is odd. How many ways are there to write n as the sum of k positive integers where the last is even and exactly one of the others is odd? (k-1) (((n-1)/2) choose (k-1))
Why? Write n+1 as the sum of k positive even integers and then subtract 1 from one of the first k-1.

To answer your question, let k=3.
 
  • Like
Likes songoku
  • #5
Prof B said:
This is a combinatorics question, not really a pre-calculus question.
It's also homework from 6 years ago!
 
  • #6
Correction: Partitions into k positive integers where order matters are actually called k-compositions. I don't know what name is given to partitions into k natural numbers where order matters.
 

FAQ: Number of positive integer solutions for given equation

How do you determine the number of positive integer solutions for a given equation?

The number of positive integer solutions for a given equation can be determined by using a technique called "stars and bars." This involves representing the equation as a sum of positive integers and using a specific formula to calculate the number of possible combinations.

Can the number of positive integer solutions for a given equation be negative?

No, the number of positive integer solutions for a given equation cannot be negative. By definition, positive integers are whole numbers greater than zero, so the solutions will always be positive.

Is there a way to find the number of positive integer solutions without using the "stars and bars" technique?

Yes, in some cases, it may be possible to find the number of positive integer solutions for a given equation by using algebraic methods such as factoring or completing the square. However, these methods may not always work, and the "stars and bars" technique is a more reliable and efficient approach.

Are there any limitations to using the "stars and bars" technique to find the number of positive integer solutions?

Yes, the "stars and bars" technique can only be used for equations that involve adding a specific number of positive integers. It cannot be used for equations that involve multiplication, division, or exponentiation.

Can the number of positive integer solutions for a given equation be infinite?

No, the number of positive integer solutions for a given equation is always finite. Even if the equation has a large number of solutions, there will always be a finite number of possible combinations of positive integers that can satisfy the equation.

Back
Top