Questions tagged [combinatorics]

Counting or enumerating elements in a set or other finite discrete structure.

Filter by
Sorted by
Tagged with
2
votes
1answer
53 views

Ordered combinations

I have a combinatorics question. Say you have two sequences: $$X_{1},X_{2},X_{3},\ldots,X_{N_{1}}$$ and $$Y_{1},Y_{2},Y_{3},\ldots,Y_{N_{2}}$$ How can i pair up elements from the $X$'s with ...
6
votes
2answers
741 views

Probability of independent events within a specified window

So I have an event that can occur on a daily basis with probabilty 1%. There is no dependence between days. Now I can calculate the probabality of the event occuring X times in Y days: ...
3
votes
2answers
870 views

Calculating possible combinations with restrictions

I have five additives that can be mixed into a chemical. Each one can be mixed in at a discrete percentage from 0.02% to 0.22% of the chemical (i.e. 0.02%, 0.03%, 0.04%,...0.22%). Each additive must ...
0
votes
3answers
2k views

Sampling with replacement

Suppose you have 40 different books (20 math books, 15 history books, and 5 geography books). Let M = math books, H = history books, G = geography books You pick 5 books at random, with replacement, ...
18
votes
2answers
69k views

Simplify sum of combinations with same n, all possible values of k

Is there a way to simplify this equation? $$\dbinom{8}{1} + \dbinom{8}{2} + \dbinom{8}{3} + \dbinom{8}{4} + \dbinom{8}{5} + \dbinom{8}{6} + \dbinom{8}{7} + \dbinom{8}{8}$$ Or more generally, $$\...
12
votes
4answers
11k views

Probability of finding a particular sequence of base pairs

Thinking about probability always makes me realize how bad I am at counting... Consider a sequence of $n$ base letters $A,\; T, \; C, \text{ and } G$, each equally likely to appear. What is the ...
9
votes
1answer
8k views

Simple combination/probability question based on string-length and possible-characters

Assuming "complete randomness" and given a string with a length of 20 characters where each character may be one of 62 possible characters: What are the total number of combinations possible? (...
13
votes
3answers
13k views

How to resample in R without repeating permutations?

In R, if I set.seed(), and then use the sample function to randomize a list, can I guarantee I won't generate the same permutation? ie... ...
10
votes
3answers
4k views

What is the probability of n people from a list of m people being in a random selection of x people from a list of y people?

If I am selecting 232 people from a pool of 363 people without replacement what is the probability of 2 of a list of 12 specific people being in that selection? This is a random draw for an ultra ...
1
vote
1answer
224 views

How many possibilities is there to choose 10 boxes of given size?

We have a collection of 40 boxes, each is one of four sizes (evenly distributed 10 of each): sizeA, sizeB, ...
2
votes
2answers
221 views

Finding expected minimum absolute difference $E(\min_{1 \leq i \leq m} |x - y_i|)$

I have faced a statistical problem in a computational biology question. I will explain it in statistical language. Let's say we have the results of rolling one red die, $x$, and $m$ black dice $y_1,\...
4
votes
2answers
175 views

Proof for a binomial equation

I'm trying to formally write out the problem: Light bulb color problem when I come up with the following equation $$\sum_{i=0}^{k-1}{C}_{2k-1}^{2k-1-i}{p}^{2k-1-i}{(1-p)}^{i}=\sum_{i=0}^{k-1}{C}_{2k}...
0
votes
0answers
117 views

What is the average expectation value of two specific objects in a queue?

I need some hand to solve this problem. Suppose a queue can be filled by three type objects (M, F and A). Depending on the number of each objects the line length can be different. We are looking ...
3
votes
1answer
11k views

Generating all possible unique combinations of dataset with two variables

I am fairly new to R and I have been reading all related topics but still I don't manage to solve my rather simple problem. I have a dataset with 5 cases for two variables (X,Y), for instance: ...
4
votes
2answers
694 views

Probability of at least one unique outcome

We have n actors. Each actor chooses from n*2 actions. How can I calculate the probability that at least one actor will choose a unique outcome? For example, say we have 5 pickup artists in a town ...
2
votes
2answers
601 views

The probability for two people to provide identical answers on survey questions

Here is the problem: A survey contains 7 binary questions (Yes/No responses). If two people are answering the survey, what is the probability for their answers on 4 or more of the questions to match? ...
6
votes
1answer
877 views

Random permutation of a vector with a fixed expected sample correlation to the original?

Suppose you have an $n$-vector $X$. For a fixed real number, $r$ between $-1$ and $1$, can one generate a random permutation of the integers $1,2,\ldots,n$, call it $i_1,i_2,\ldots,i_n$ such that the ...
24
votes
5answers
4k views

What is wrong with this “naive” shuffling algorithm?

This is a follow-up to a Stackoverflow question about shuffling an array randomly. There are established algorithms (such as the Knuth-Fisher-Yates Shuffle) that one should use to shuffle an array, ...
30
votes
3answers
10k views

Extending the birthday paradox to more than 2 people

In the traditional Birthday Paradox the question is "what are the chances that two or more people in a group of $n$ people share a birthday". I'm stuck on a problem which is an extension of this. ...
8
votes
2answers
9k views

How can I obtain some of all possible combinations in R?

Sometimes I want to do an exact test by examining all possible combinations of the data to build an empirical distribution against which I can test my observed differences between means. To find the ...

1
5 6 7 8
9