# Thread: i want help in founding equation in my problem

1. ## i want help in founding equation in my problem

i have a problem of :
if i have x chairs and y persons and i want to make each person sit on a chair but there is no person next to him
eg:
x = 4 , y = 2
if '|' means a chair sitting on it a person
and '.' means chair with no one sitting on it

so solution is : |.|. or .|.|
so solutions is 2 method

i want a formula or a way if i have x and y i can get number of methods

another example
Code:
x = 16 , y = 6
|.|.|.|.|.|.....
|.|.|.|.|..|....
|.|.|.|.|...|...
|.|.|.|.|....|..
|.|.|.|.|.....|.
|.|.|.|..|.|....
|.|.|.|..|..|...
|.|.|.|..|...|..
|.|.|.|..|....|.
|.|.|.|...|.|...
|.|.|.|...|..|..
|.|.|.|...|...|.
|.|.|.|....|.|..
|.|.|.|....|..|.
|.|.|.|.....|.|.
|.|.|..|.|.|....
|.|.|..|.|..|...
|.|.|..|.|...|..
|.|.|..|.|....|.
|.|.|..|..|.|...
|.|.|..|..|..|..
|.|.|..|..|...|.
|.|.|..|...|.|..
|.|.|..|...|..|.
|.|.|..|....|.|.
|.|.|...|.|.|...
|.|.|...|.|..|..
|.|.|...|.|...|.
|.|.|...|..|.|..
|.|.|...|..|..|.
|.|.|...|...|.|.
|.|.|....|.|.|..
|.|.|....|.|..|.
|.|.|....|..|.|.
|.|.|.....|.|.|.
|.|..|.|.|.|....
|.|..|.|.|..|...
|.|..|.|.|...|..
|.|..|.|.|....|.
|.|..|.|..|.|...
|.|..|.|..|..|..
|.|..|.|..|...|.
|.|..|.|...|.|..
|.|..|.|...|..|.
|.|..|.|....|.|.
|.|..|..|.|.|...
|.|..|..|.|..|..
|.|..|..|.|...|.
|.|..|..|..|.|..
|.|..|..|..|..|.
|.|..|..|...|.|.
|.|..|...|.|.|..
|.|..|...|.|..|.
|.|..|...|..|.|.
|.|..|....|.|.|.
|.|...|.|.|.|...
|.|...|.|.|..|..
|.|...|.|.|...|.
|.|...|.|..|.|..
|.|...|.|..|..|.
|.|...|.|...|.|.
|.|...|..|.|.|..
|.|...|..|.|..|.
|.|...|..|..|.|.
|.|...|...|.|.|.
|.|....|.|.|.|..
|.|....|.|.|..|.
|.|....|.|..|.|.
|.|....|..|.|.|.
|.|.....|.|.|.|.
|..|.|.|.|.|....
|..|.|.|.|..|...
|..|.|.|.|...|..
|..|.|.|.|....|.
|..|.|.|..|.|...
|..|.|.|..|..|..
|..|.|.|..|...|.
|..|.|.|...|.|..
|..|.|.|...|..|.
|..|.|.|....|.|.
|..|.|..|.|.|...
|..|.|..|.|..|..
|..|.|..|.|...|.
|..|.|..|..|.|..
|..|.|..|..|..|.
|..|.|..|...|.|.
|..|.|...|.|.|..
|..|.|...|.|..|.
|..|.|...|..|.|.
|..|.|....|.|.|.
|..|..|.|.|.|...
|..|..|.|.|..|..
|..|..|.|.|...|.
|..|..|.|..|.|..
|..|..|.|..|..|.
|..|..|.|...|.|.
|..|..|..|.|.|..
|..|..|..|.|..|.
|..|..|..|..|.|.
|..|..|...|.|.|.
|..|...|.|.|.|..
|..|...|.|.|..|.
|..|...|.|..|.|.
|..|...|..|.|.|.
|..|....|.|.|.|.
|...|.|.|.|.|...
|...|.|.|.|..|..
|...|.|.|.|...|.
|...|.|.|..|.|..
|...|.|.|..|..|.
|...|.|.|...|.|.
|...|.|..|.|.|..
|...|.|..|.|..|.
|...|.|..|..|.|.
|...|.|...|.|.|.
|...|..|.|.|.|..
|...|..|.|.|..|.
|...|..|.|..|.|.
|...|..|..|.|.|.
|...|...|.|.|.|.
|....|.|.|.|.|..
|....|.|.|.|..|.
|....|.|.|..|.|.
|....|.|..|.|.|.
|....|..|.|.|.|.
|.....|.|.|.|.|.
.|.|.|.|.|.|....
.|.|.|.|.|..|...
.|.|.|.|.|...|..
.|.|.|.|.|....|.
.|.|.|.|.|.....|
.|.|.|.|..|.|...
.|.|.|.|..|..|..
.|.|.|.|..|...|.
.|.|.|.|..|....|
.|.|.|.|...|.|..
.|.|.|.|...|..|.
.|.|.|.|...|...|
.|.|.|.|....|.|.
.|.|.|.|....|..|
.|.|.|.|.....|.|
.|.|.|..|.|.|...
.|.|.|..|.|..|..
.|.|.|..|.|...|.
.|.|.|..|.|....|
.|.|.|..|..|.|..
.|.|.|..|..|..|.
.|.|.|..|..|...|
.|.|.|..|...|.|.
.|.|.|..|...|..|
.|.|.|..|....|.|
.|.|.|...|.|.|..
.|.|.|...|.|..|.
.|.|.|...|.|...|
.|.|.|...|..|.|.
.|.|.|...|..|..|
.|.|.|...|...|.|
.|.|.|....|.|.|.
.|.|.|....|.|..|
.|.|.|....|..|.|
.|.|.|.....|.|.|
.|.|..|.|.|.|...
.|.|..|.|.|..|..
.|.|..|.|.|...|.
.|.|..|.|.|....|
.|.|..|.|..|.|..
.|.|..|.|..|..|.
.|.|..|.|..|...|
.|.|..|.|...|.|.
.|.|..|.|...|..|
.|.|..|.|....|.|
.|.|..|..|.|.|..
.|.|..|..|.|..|.
.|.|..|..|.|...|
.|.|..|..|..|.|.
.|.|..|..|..|..|
.|.|..|..|...|.|
.|.|..|...|.|.|.
.|.|..|...|.|..|
.|.|..|...|..|.|
.|.|..|....|.|.|
.|.|...|.|.|.|..
.|.|...|.|.|..|.
.|.|...|.|.|...|
.|.|...|.|..|.|.
.|.|...|.|..|..|
.|.|...|.|...|.|
.|.|...|..|.|.|.
.|.|...|..|.|..|
.|.|...|..|..|.|
.|.|...|...|.|.|
.|.|....|.|.|.|.
.|.|....|.|.|..|
.|.|....|.|..|.|
.|.|....|..|.|.|
.|.|.....|.|.|.|
.|..|.|.|.|.|...
.|..|.|.|.|..|..
.|..|.|.|.|...|.
.|..|.|.|.|....|
.|..|.|.|..|.|..
.|..|.|.|..|..|.
.|..|.|.|..|...|
.|..|.|.|...|.|.
.|..|.|.|...|..|
.|..|.|.|....|.|
.|..|.|..|.|.|..
.|..|.|..|.|..|.
.|..|.|..|.|...|
.|..|.|..|..|.|.
.|..|.|..|..|..|
.|..|.|..|...|.|
.|..|.|...|.|.|.
.|..|.|...|.|..|
.|..|.|...|..|.|
.|..|.|....|.|.|
.|..|..|.|.|.|..
.|..|..|.|.|..|.
.|..|..|.|.|...|
.|..|..|.|..|.|.
.|..|..|.|..|..|
.|..|..|.|...|.|
.|..|..|..|.|.|.
.|..|..|..|.|..|
.|..|..|..|..|.|
.|..|..|...|.|.|
.|..|...|.|.|.|.
.|..|...|.|.|..|
.|..|...|.|..|.|
.|..|...|..|.|.|
.|..|....|.|.|.|
.|...|.|.|.|.|..
.|...|.|.|.|..|.
.|...|.|.|.|...|
.|...|.|.|..|.|.
.|...|.|.|..|..|
.|...|.|.|...|.|
.|...|.|..|.|.|.
.|...|.|..|.|..|
.|...|.|..|..|.|
.|...|.|...|.|.|
.|...|..|.|.|.|.
.|...|..|.|.|..|
.|...|..|.|..|.|
.|...|..|..|.|.|
.|...|...|.|.|.|
.|....|.|.|.|.|.
.|....|.|.|.|..|
.|....|.|.|..|.|
.|....|.|..|.|.|
.|....|..|.|.|.|
.|.....|.|.|.|.|
..|.|.|.|.|.|...
..|.|.|.|.|..|..
..|.|.|.|.|...|.
..|.|.|.|.|....|
..|.|.|.|..|.|..
..|.|.|.|..|..|.
..|.|.|.|..|...|
..|.|.|.|...|.|.
..|.|.|.|...|..|
..|.|.|.|....|.|
..|.|.|..|.|.|..
..|.|.|..|.|..|.
..|.|.|..|.|...|
..|.|.|..|..|.|.
..|.|.|..|..|..|
..|.|.|..|...|.|
..|.|.|...|.|.|.
..|.|.|...|.|..|
..|.|.|...|..|.|
..|.|.|....|.|.|
..|.|..|.|.|.|..
..|.|..|.|.|..|.
..|.|..|.|.|...|
..|.|..|.|..|.|.
..|.|..|.|..|..|
..|.|..|.|...|.|
..|.|..|..|.|.|.
..|.|..|..|.|..|
..|.|..|..|..|.|
..|.|..|...|.|.|
..|.|...|.|.|.|.
..|.|...|.|.|..|
..|.|...|.|..|.|
..|.|...|..|.|.|
..|.|....|.|.|.|
..|..|.|.|.|.|..
..|..|.|.|.|..|.
..|..|.|.|.|...|
..|..|.|.|..|.|.
..|..|.|.|..|..|
..|..|.|.|...|.|
..|..|.|..|.|.|.
..|..|.|..|.|..|
..|..|.|..|..|.|
..|..|.|...|.|.|
..|..|..|.|.|.|.
..|..|..|.|.|..|
..|..|..|.|..|.|
..|..|..|..|.|.|
..|..|...|.|.|.|
..|...|.|.|.|.|.
..|...|.|.|.|..|
..|...|.|.|..|.|
..|...|.|..|.|.|
..|...|..|.|.|.|
..|....|.|.|.|.|
...|.|.|.|.|.|..
...|.|.|.|.|..|.
...|.|.|.|.|...|
...|.|.|.|..|.|.
...|.|.|.|..|..|
...|.|.|.|...|.|
...|.|.|..|.|.|.
...|.|.|..|.|..|
...|.|.|..|..|.|
...|.|.|...|.|.|
...|.|..|.|.|.|.
...|.|..|.|.|..|
...|.|..|.|..|.|
...|.|..|..|.|.|
...|.|...|.|.|.|
...|..|.|.|.|.|.
...|..|.|.|.|..|
...|..|.|.|..|.|
...|..|.|..|.|.|
...|..|..|.|.|.|
...|...|.|.|.|.|
....|.|.|.|.|.|.
....|.|.|.|.|..|
....|.|.|.|..|.|
....|.|.|..|.|.|
....|.|..|.|.|.|
....|..|.|.|.|.|
.....|.|.|.|.|.|

2. Here are some facts. If we have y persons then we must have at least 2y-1 chairs: i.e. $x\ge 2y-1$.
Here is an example: suppose we have five people and twelve chairs.
We will have five occupied chairs and seven empty chairs.
Consider the string $OOOOOEEEEEEE$, we need to know how many ways to arrange that string so no two O’s are consecutive.
That answer is $\dbinom{8}{5}=56$. Now that means we are considering the people as identical.

So here goes. If we have y people and x chairs, $x\ge 2y-1$, then the number of ways is $\dbinom{x-y+1}{y}$

3. i understand the 1st point but i don't understand how to get number of methods
what is meant by

So here goes. If we have y people and x chairs, , then the number of ways is

4. Originally Posted by mido22
i understand the 1st point but i don't understand how to get number of methods
what is meant by ( x - y + 1 )
?????????????????( y )
Let’s take your original example: $x=16~\&~y=6$.
And your model: $6~|’s~\&~16-6=10~*’s$
We want to arrange this string $||||||**********$ in such a way so that no two $|~|$ are together.
The ten *’s create eleven places to places to put the six |’s.
Choose six of the eleven, $\dbinom{16-6+1}{6}=\dbinom{11}{6}=\dfrac{11!}{(11-6)!(6!)}.$

Again that answer treats the people as identical. If you don’t want that then multiply by 6!.

5. sry plato but the answer for this example is 336 so How can i get this answer from 11 and 6

6. Originally Posted by mido22
but the answer for this example is 336 so How can i get this answer from 11 and 6
Well, how do you know that is the answer?

In a row of sixteen seats there are 462 ways to occupy six seats so that no two consecutive seats are occupied.

Perhaps I have not understood your question correctly.
Is the above reading correct?

EDIT: I found a mistake in your OP.

Originally Posted by mido22
i have a problem of :
if i have x chairs and y persons and i want to make each person sit on a chair but there is no person next to him
eg:
x = 4 , y = 2
if '|' means a chair sitting on it a person
and '.' means chair with no one sitting on it

so solution is : |.|. or .|.|
so solutions is 2 method
You missed one case, |..|. So there are three not two.

7. Originally Posted by Plato
Well, how do you know that is the answer?

In a row of sixteen seats there are 462 ways to occupy six seats so that no two consecutive seats are occupied.

Perhaps I have not understood your question correctly.
Is the above reading correct?
if we have 16 seat and 6 persons so we need now at least 12 seats not 11
for eg
OEOEOEOEOEOE
beause this row is a cycle in fact not a row so if we put them like that OEOEOEOEOEO the 1st one will be next to last one

8. i my 1st example i don't missed a case
they are two methods only
i have 4 chairs only
how it will be |..|. this will be 5 chairs not 4

9. You have now posted a different question.
Your OP indicated that you were asking about a linear formation.
Now you seen to be asking about circular arrangements.
Even the model you gave is linear not circular.
Do you understand this question?

If the question is indeed about circular arrangements, then your first model is completely off. Given four chairs and two people there is only one way to seat them at a circular table with an empty chair between them.

10. Originally Posted by Plato
You have now posted a different question.
Your OP indicated that you were asking about a linear formation.
Now you seen to be asking about circular arrangements.
Even the model you gave is linear not circular.
Do you understand this question?

If the question is indeed about circular arrangements, then your first model is completely off. Given four chairs and two people there is only one way to seat them at a circular table with an empty chair between them.
i understand u but my question is linear not circular but u said that if we have x & y so x must be > = 2y-1 no it must be > = 2y
eg:
|.|.|. is right but |.|.| is wrong

11. Originally Posted by mido22
|.|.|. is right but |.|.| is wrong
Please explain why |.|.| is wrong.
That is seating three people in five chairs with an empty chair between them. In fact, there two empty chairs between the first and last.

12. Originally Posted by Plato
Please explain why |.|.| is wrong.
That is seating three people in five chairs with an empty chair between them. In fact, there two empty chairs between the first and last.
because it must be like .|.|.| or |.|.|. becaz i said before that the last one will be next to first one other meaning ( there must be an empty chair from both sides of each person except first "or" last one from one side only)

13. Originally Posted by mido22
because it must be like .|.|.| or |.|.|. becaz i said before that the last one will be next to first one other meaning ( there must be an empty chair from both sides of each person except first "or" last one from one side only)
Well then you never said exactly that.
Now with x chairs and y persons, indeed $x\ge 2y$.
Here is the count:
$\dbinom{x-y+1}{y}-\dbinom{x-y-1}{y-2}.$

14. Originally Posted by Plato
Well then you never said exactly that.
Now with x chairs and y persons, indeed $x\ge 2y$.
Here is the count:
$\dbinom{x-y+1}{y}-\dbinom{x-y-1}{y-2}.$
ok but i don't understand that shape u write formula in what is meant by that shape
(x-y+1) and under it there is y is it means division or multiply or ???

15. Originally Posted by mido22
ok but i don't understand that shape u write formula in what is meant by that shape (x-y+1) and under it there is y is it means division or multiply or ???
That is a completely standard notation used in counting problems.
It is the binomial coefficient.

$\dbinom{N}{k}=\dfrac{N!}{k!(N-k)!}$.
Please don't tell us that you do not know about factorials.

Page 1 of 2 12 Last