# Thread:

1. ## Probability of the next entry in a series of discrete trials.

Hi, all.

Suppose you have a series of events, all the same, which can result in X or ~X. The probability of each is unknown. As you watch the series go forward, every entry (to start) is X. So:

$S = \{X, X, X, X, X... \}$

At any point, however, it is possible that the pattern will cease, and that we will get a ~X. But let's say it hasn't happened yet.

Let's also say that the number of X's we have observed so far is $n$, such that the probability of this occurring is:

$P(S_n)=[P(X)]^n$

So, how do we determine P(X) ?

We could determine a confidence level, I think...

$[P(X)]^n>.05$

$P(X)>.05^{\frac{1}{n}}$

So, there's a 95% chance that $P(X)\in(.05^\frac{1}{n},1]$, yes? But how do we actually find P(X)?

Thanks!

2. We could use the confidence interval to find a minimum probability. Let's say that the error is given as $E$. So:

$E^{\frac{1}{n}}$ is the lower bound of $P(X)$ in the $1-E$ confidence level. Let's call Q(X) the probable expectation that the next entry in the sequence is X. So, $Q(X)\geq(1-E)E^{\frac{1}{n}}$. We can take the derivative with respect to $E$ to find the value of $E$ which maximizes $Q(X)$:

$\frac{d}{dE}(1-E)E^{\frac{1}{n}}=0$

$\frac{d}{dE}(E^{\frac{1}{n}}-E^{\frac{1}{n}+1})=0$

$\frac{1}{n}E^{\frac{1}{n}-1}-[\frac{1}{n}+1]E^{\frac{1}{n}})=0$

$\frac{1}{En}E^{\frac{1}{n}}-[\frac{1}{n}+1]E^{\frac{1}{n}})=0$

$[\frac{1}{En}-\frac{1}{n}-1]E^{\frac{1}{n}}=0$

$\frac{1}{En}-\frac{1}{n}-1=0$

$\frac{1}{En}=\frac{n+1}{n}$

$En=\frac{n}{n+1}$

$E=\frac{1}{n+1}$

Now, recall our $Q(X)$ relationship:

$Q(X)\geq(1-E)E^{\frac{1}{n}}$

And substitute for E:

$Q(X)\geq(1-\frac{1}{n+1})[\frac{1}{n+1}]^{\frac{1}{n}}$

$Q(X)\geq\frac{n}{(n+1)^{\frac{1}{n}}(n+1)}$

$Q(X)\geq\frac{n}{(n+1)^{\frac{n+1}{n}}}$

It seems like we should be able to do better than this, though.
{"extraction_info": {"found_math": true, "script_math_tex": 0, "script_math_asciimath": 0, "math_annotations": 0, "math_alttext": 0, "mathml": 0, "mathjax_tag": 0, "mathjax_inline_tex": 0, "mathjax_display_tex": 0, "mathjax_asciimath": 0, "img_math": 0, "codecogs_latex": 28, "wp_latex": 0, "mimetex.cgi": 0, "/images/math/codecogs": 0, "mathtex.cgi": 0}, "config": {"markdown_headings": true, "markdown_code": true, "boilerplate_config": {"ratio_threshold": 0.3, "absolute_threshold": 10, "end_threshold": 15, "enable": true}, "remove_buttons": true, "remove_image_figures": true, "remove_link_clusters": true, "table_config": {"min_rows": 2, "min_cols": 3, "format": "github"}, "remove_chinese": true, "remove_edit_buttons": true, "extract_latex": true}, "english_confidence": 0.956636905670166, "perplexity_flag": "head"}