Calculating the expectancy
The distance between two numbers will be set as $ | i - j | $ . I pick two numbers without replacement from $ 0,1,2, dots ,n $ let $ X $ be the distance between the numbers. What is the expectancy of $ X $ ?
there are $ {n+1 choose 2} $ options. so $ {n+1 choose 2} = frac{n(n+1)}{2} $ and the probability will be $$ P{X = i} = frac{2(n+1-i)}{n(n+1)}$$
Then the expectancy $$ E[X] = sum_{i=1}^n x_i cdot p(x_i) = sum_{i=1}^n x_i frac{2(n+1-i)}{n(n+1)} $$
I don't really know how to proceed from here?
probability probability-theory
add a comment |
The distance between two numbers will be set as $ | i - j | $ . I pick two numbers without replacement from $ 0,1,2, dots ,n $ let $ X $ be the distance between the numbers. What is the expectancy of $ X $ ?
there are $ {n+1 choose 2} $ options. so $ {n+1 choose 2} = frac{n(n+1)}{2} $ and the probability will be $$ P{X = i} = frac{2(n+1-i)}{n(n+1)}$$
Then the expectancy $$ E[X] = sum_{i=1}^n x_i cdot p(x_i) = sum_{i=1}^n x_i frac{2(n+1-i)}{n(n+1)} $$
I don't really know how to proceed from here?
probability probability-theory
1
I don't know why you are switching to $x_i cdot p(x_i)$. Your probability $P{X = i}$ is correct and the expectation is $E[X] = sum_{i = 1}^n i cdot P{X = i}$
– Lee David Chung Lin
Dec 2 at 12:12
I need to somehow get to this answer : $ frac{n+2}{3} $
– bm1125
Dec 2 at 13:07
You have to set $x_i=i$ and then apply the usual techniques to evaluate the sum.
– Ingix
Dec 2 at 13:53
add a comment |
The distance between two numbers will be set as $ | i - j | $ . I pick two numbers without replacement from $ 0,1,2, dots ,n $ let $ X $ be the distance between the numbers. What is the expectancy of $ X $ ?
there are $ {n+1 choose 2} $ options. so $ {n+1 choose 2} = frac{n(n+1)}{2} $ and the probability will be $$ P{X = i} = frac{2(n+1-i)}{n(n+1)}$$
Then the expectancy $$ E[X] = sum_{i=1}^n x_i cdot p(x_i) = sum_{i=1}^n x_i frac{2(n+1-i)}{n(n+1)} $$
I don't really know how to proceed from here?
probability probability-theory
The distance between two numbers will be set as $ | i - j | $ . I pick two numbers without replacement from $ 0,1,2, dots ,n $ let $ X $ be the distance between the numbers. What is the expectancy of $ X $ ?
there are $ {n+1 choose 2} $ options. so $ {n+1 choose 2} = frac{n(n+1)}{2} $ and the probability will be $$ P{X = i} = frac{2(n+1-i)}{n(n+1)}$$
Then the expectancy $$ E[X] = sum_{i=1}^n x_i cdot p(x_i) = sum_{i=1}^n x_i frac{2(n+1-i)}{n(n+1)} $$
I don't really know how to proceed from here?
probability probability-theory
probability probability-theory
edited Dec 2 at 12:30
Bernard
118k639112
118k639112
asked Dec 2 at 11:17
bm1125
60516
60516
1
I don't know why you are switching to $x_i cdot p(x_i)$. Your probability $P{X = i}$ is correct and the expectation is $E[X] = sum_{i = 1}^n i cdot P{X = i}$
– Lee David Chung Lin
Dec 2 at 12:12
I need to somehow get to this answer : $ frac{n+2}{3} $
– bm1125
Dec 2 at 13:07
You have to set $x_i=i$ and then apply the usual techniques to evaluate the sum.
– Ingix
Dec 2 at 13:53
add a comment |
1
I don't know why you are switching to $x_i cdot p(x_i)$. Your probability $P{X = i}$ is correct and the expectation is $E[X] = sum_{i = 1}^n i cdot P{X = i}$
– Lee David Chung Lin
Dec 2 at 12:12
I need to somehow get to this answer : $ frac{n+2}{3} $
– bm1125
Dec 2 at 13:07
You have to set $x_i=i$ and then apply the usual techniques to evaluate the sum.
– Ingix
Dec 2 at 13:53
1
1
I don't know why you are switching to $x_i cdot p(x_i)$. Your probability $P{X = i}$ is correct and the expectation is $E[X] = sum_{i = 1}^n i cdot P{X = i}$
– Lee David Chung Lin
Dec 2 at 12:12
I don't know why you are switching to $x_i cdot p(x_i)$. Your probability $P{X = i}$ is correct and the expectation is $E[X] = sum_{i = 1}^n i cdot P{X = i}$
– Lee David Chung Lin
Dec 2 at 12:12
I need to somehow get to this answer : $ frac{n+2}{3} $
– bm1125
Dec 2 at 13:07
I need to somehow get to this answer : $ frac{n+2}{3} $
– bm1125
Dec 2 at 13:07
You have to set $x_i=i$ and then apply the usual techniques to evaluate the sum.
– Ingix
Dec 2 at 13:53
You have to set $x_i=i$ and then apply the usual techniques to evaluate the sum.
– Ingix
Dec 2 at 13:53
add a comment |
1 Answer
1
active
oldest
votes
You are almost there.
$x_i = i$ in your formula for the expectation.
$$E[X]=sum_1^nfrac{2i(n+1-i)}{n(n+1)}$$
Then, use the identities:
$$sum_1^n i =frac{n(n+1)}{2}$$
and
$$sum_1^n i^2 =frac{n(n+1)(2n+1)}{6}$$
We get
$$E[X]=frac{2}{n(n+1)}(n+1)sum i -frac{2}{n(n+1)}sum i^2$$
$$E[X]=frac{2}{n}frac{n(n+1)}{2} - frac{2}{n(n+1)}frac{n(n+1)(2n+1)}{6}$$
Therefore
$$E[X]=n+1-frac{2n+1}{3}=frac{n+2}{3}$$
add a comment |
Your Answer
StackExchange.ifUsing("editor", function () {
return StackExchange.using("mathjaxEditing", function () {
StackExchange.MarkdownEditor.creationCallbacks.add(function (editor, postfix) {
StackExchange.mathjaxEditing.prepareWmdForMathJax(editor, postfix, [["$", "$"], ["\\(","\\)"]]);
});
});
}, "mathjax-editing");
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "69"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
noCode: true, onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f3022512%2fcalculating-the-expectancy%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
You are almost there.
$x_i = i$ in your formula for the expectation.
$$E[X]=sum_1^nfrac{2i(n+1-i)}{n(n+1)}$$
Then, use the identities:
$$sum_1^n i =frac{n(n+1)}{2}$$
and
$$sum_1^n i^2 =frac{n(n+1)(2n+1)}{6}$$
We get
$$E[X]=frac{2}{n(n+1)}(n+1)sum i -frac{2}{n(n+1)}sum i^2$$
$$E[X]=frac{2}{n}frac{n(n+1)}{2} - frac{2}{n(n+1)}frac{n(n+1)(2n+1)}{6}$$
Therefore
$$E[X]=n+1-frac{2n+1}{3}=frac{n+2}{3}$$
add a comment |
You are almost there.
$x_i = i$ in your formula for the expectation.
$$E[X]=sum_1^nfrac{2i(n+1-i)}{n(n+1)}$$
Then, use the identities:
$$sum_1^n i =frac{n(n+1)}{2}$$
and
$$sum_1^n i^2 =frac{n(n+1)(2n+1)}{6}$$
We get
$$E[X]=frac{2}{n(n+1)}(n+1)sum i -frac{2}{n(n+1)}sum i^2$$
$$E[X]=frac{2}{n}frac{n(n+1)}{2} - frac{2}{n(n+1)}frac{n(n+1)(2n+1)}{6}$$
Therefore
$$E[X]=n+1-frac{2n+1}{3}=frac{n+2}{3}$$
add a comment |
You are almost there.
$x_i = i$ in your formula for the expectation.
$$E[X]=sum_1^nfrac{2i(n+1-i)}{n(n+1)}$$
Then, use the identities:
$$sum_1^n i =frac{n(n+1)}{2}$$
and
$$sum_1^n i^2 =frac{n(n+1)(2n+1)}{6}$$
We get
$$E[X]=frac{2}{n(n+1)}(n+1)sum i -frac{2}{n(n+1)}sum i^2$$
$$E[X]=frac{2}{n}frac{n(n+1)}{2} - frac{2}{n(n+1)}frac{n(n+1)(2n+1)}{6}$$
Therefore
$$E[X]=n+1-frac{2n+1}{3}=frac{n+2}{3}$$
You are almost there.
$x_i = i$ in your formula for the expectation.
$$E[X]=sum_1^nfrac{2i(n+1-i)}{n(n+1)}$$
Then, use the identities:
$$sum_1^n i =frac{n(n+1)}{2}$$
and
$$sum_1^n i^2 =frac{n(n+1)(2n+1)}{6}$$
We get
$$E[X]=frac{2}{n(n+1)}(n+1)sum i -frac{2}{n(n+1)}sum i^2$$
$$E[X]=frac{2}{n}frac{n(n+1)}{2} - frac{2}{n(n+1)}frac{n(n+1)(2n+1)}{6}$$
Therefore
$$E[X]=n+1-frac{2n+1}{3}=frac{n+2}{3}$$
answered Dec 2 at 13:58
ip6
54839
54839
add a comment |
add a comment |
Thanks for contributing an answer to Mathematics Stack Exchange!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
Use MathJax to format equations. MathJax reference.
To learn more, see our tips on writing great answers.
Some of your past answers have not been well-received, and you're in danger of being blocked from answering.
Please pay close attention to the following guidance:
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f3022512%2fcalculating-the-expectancy%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
1
I don't know why you are switching to $x_i cdot p(x_i)$. Your probability $P{X = i}$ is correct and the expectation is $E[X] = sum_{i = 1}^n i cdot P{X = i}$
– Lee David Chung Lin
Dec 2 at 12:12
I need to somehow get to this answer : $ frac{n+2}{3} $
– bm1125
Dec 2 at 13:07
You have to set $x_i=i$ and then apply the usual techniques to evaluate the sum.
– Ingix
Dec 2 at 13:53