• Support PF! Buy your school textbooks, materials and every day products Here!

Calculate the probability that a robot is in a certain location

  • Thread starter Gjmdp
  • Start date
  • #1
137
5

Homework Statement:

There is a 1x10 grid with 10 squares. A robot is located on 1 of this squares. It receives a reading (observation) o=5 from its left sensor,which means that the robot should be located on the 5th square starting from the left, location denoted by L(5,0). The probability that this is correct is 0.8, the probability that "it is unit more is 0.1 and that it is one unit less is 0.1". Calculate the probability that the robot is in location L(5,0) after observation o, this is, calculate p(L(5,0)|o)). We know that p(o |L(5,0))) = 0.6, p(o |L(4,0))) = 0.2, p(o |L(6,0))) = 0.2, and 0 for all other L

Relevant Equations:

Bayes Theorem
A similar question was asked on a final exam. I assume that p(L(5,0)|o)) is actually 0.8 since it says "the probability that this is correct is 0.8", but isn't it like too easy? Am I making any mistakes? We are given extra information that we don't have to use at all?
 

Answers and Replies

  • #2
StoneTemplePython
Science Advisor
Gold Member
2019 Award
1,158
564
What class is this for / is this a pen an paper exercise or a computational one?

The lack of formatting makes this very hard to read, though at a glance it feels like a hidden markov model setup.
 
  • #3
137
5
It is a paper exercise one. You are only intended to use bayesian probabily formulas. I am happy to clarify anything that might seem confusing.
 
  • #4
StoneTemplePython
Science Advisor
Gold Member
2019 Award
1,158
564
ok, so the 0.8 is the likelihood function. If you want to apply bayes you also need a prior distribution.

Equivalently, Bayes rule comes from conditional probability which says

##p\big(X=x\big \vert Y= y\big)\cdot p\big(Y=y\big) = p\big(X=x,Y=y\big) = p\big(Y=y\big \vert X=x\big)\cdot p\big(X=x\big) ##
- - - -
How can you take the information in your problem statement to fill out (most all) of the above equation? This is standard HW template stuff that people would ask for as part of an attempt at the solution and relevant equations...
 
  • #5
137
5
ok, so the 0.8 is the likelihood function. If you want to apply bayes you also need a prior distribution.

Equivalently, Bayes rule comes from conditional probability which says

##p\big(X=x\big \vert Y= y\big)\cdot p\big(Y=y\big) = p\big(X=x,Y=y\big) = p\big(Y=y\big \vert X=x\big)\cdot p\big(X=x\big) ##
- - - -
How can you take the information in your problem statement to fill out (most all) of the above equation? This is standard HW template stuff that people would ask for as part of an attempt at the solution and relevant equations...
I think I already made explicit my attempt. No, that formula (Bayes Rule) is not required to solve this problem. I dont have to fill it to solve the problem, as it is not necessary. As I already said, I think the problem is very simple, and I think that the solution for p(L(5,0)|o)) is 0.8, due to the description of the problem ("this [observation] is correct with probability 0.8"). However, I was just wondering if the problem could be that simple, given that extra information is provided.
 
  • #6
StoneTemplePython
Science Advisor
Gold Member
2019 Award
1,158
564
I think I already made explicit my attempt. No, that formula (Bayes Rule) is not required to solve this problem. I dont have to fill it to solve the problem, as it is not necessary. As I already said, I think the problem is very simple, and I think that the solution for p(L(5,0)|o)) is 0.8, due to the description of the problem ("this [observation] is correct with probability 0.8"). However, I was just wondering if the problem could be that simple, given that extra information is provided.
You problem statement doesn't seem to be that well worded. The fundamental issue, which you've now expanded on, remains and its that the problem statement says
this [observation] is correct with probability 0.8

I can't fix wording of questions -- that is something between you and your instructor. I can tell you that it looks like it is intended as a likelihood function. If the problem came up in a section where you are told to use Bayes theorem then your answer is quite likely to be marked wrong as you are not incorporating a prior distribution in your answer.

From what I've read so far I'm not remotely convinced you know what a likelihood function is, and in turn I'm not at all convinced you 'get' Bayes Theorem. A lot of math comes down to carefully reading and applying definitions. If you want to apply Bayes theorem to this problem, you can try it and actually attempt a correct answer. I can then plug gaps.

If not, then we may as well close the thread.
 
  • #7
137
5
You problem statement doesn't seem to be that well worded. The fundamental issue, which you've now expanded on, remains and its that the problem statement says
this [observation] is correct with probability 0.8

I can't fix wording of questions -- that is something between you and your instructor. I can tell you that it looks like it is intended as a likelihood function. If the problem came up in a section where you are told to use Bayes theorem then your answer is quite likely to be marked wrong as you are not incorporating a prior distribution in your answer.

From what I've read so far I'm not remotely convinced you know what a likelihood function is, and in turn I'm not at all convinced you 'get' Bayes Theorem. A lot of math comes down to carefully reading and applying definitions. If you want to apply Bayes theorem to this problem, you can try it and actually attempt a correct answer. I can then plug gaps.

If not, then we may as well close the thread.
I just asked if my attemp was correct, that is if the probability that the observation is correct (0.8) is p(L(5,0)|o)). I know perfectly what the bayes theorem is and when it should be applied. It was my question whether in this case bayes theorem was innecesary as the problem statement already provided the answer. There is no need to be rude anyway, nor to assume that I dont know most of the mathematics that is required to solve the problem. I just asked whether my guess was correct. The bayes rule that you provided on past replies is unnecesary in this case. We are expected to know bayesian and conditional probability, which does not mean that we need to use its formula explicitly. Thank you for assuming that I don't "get" Bayes formula, but I do :)
 
  • #8
phinds
Science Advisor
Insights Author
Gold Member
2019 Award
16,184
6,192
I know perfectly what the bayes theorem is and when it should be applied.
Your posts did not make that at all clear and your taking umbrage at having that fact pointed out is not helpful. Here on PF, someone's trying to help you by pointing out apparent or perceived flaws in your logic should not be taken personally. @StoneTemplePython was not being snippy towards YOU, he was pointing out the apparent flaws in your logic.
 
  • Like
Likes StoneTemplePython
  • #9
137
5
Your posts did not make that at all clear and your taking umbrage at having that fact pointed out is not helpful. Here on PF, someone's trying to help you by pointing out apparent or perceived flaws in your logic should not be taken personally. @StoneTemplePython was not being snippy towards YOU, he was pointing out the apparent flaws in your logic.
I'm sorry about that, my mistake then. Could you tell me what those flaws in my logic are, and how my posts didnt make clear that I don't know what the bayes theorem is? Thank you
 
  • Like
Likes phinds
  • #10
StoneTemplePython
Science Advisor
Gold Member
2019 Award
1,158
564
Your posts did not make that at all clear and your taking umbrage at having that fact pointed out is not helpful. Here on PF, someone's trying to help you by pointing out apparent or perceived flaws in your logic should not be taken personally. @StoneTemplePython was not being snippy towards YOU, he was pointing out the apparent flaws in your logic.
It reminds me a lot of this problem to be honest:
https://www.physicsforums.com/threads/specific-question-re-bayesian-statistics-analysis.957394/

For what it's worth, I 'learned' bayes formula originally in a stats class, but I didn't 'get' it until much later. There's a lot of depth buried in something that formally is simple.
 
  • #11
phinds
Science Advisor
Insights Author
Gold Member
2019 Award
16,184
6,192
I'm sorry about that, my mistake then. Could you tell me what those flaws in my logic are, and how my posts didnt make clear that I don't know what the bayes theorem is? Thank you
I think you didn't mean that double negative in your last sentence there since what you asked me to comment on is how your posts show you DID know it :smile:

Anyway, your continued persistence that you don't NEED Bayesian Analysis for this problem is what convince me of it (it being that you DIDN'T know it, or know it well), and I assume stonetemplepythone as well. I agree w/ him that the problem wording is poor and your assumption would not seem so far off were it not for the fact that you stated that for the problem Bayesian Analysis was the "relevant equation"
 
  • #12
137
5
I think you didn't mean that double negative in your last sentence there since what you asked me to comment on is how your posts show you DID know it :smile:

Anyway, your continued persistence that you don't NEED Bayesian Analysis for this problem is what convince me of it (it being that you DIDN'T know it, or know it well), and I assume stonetemplepythone as well. I agree w/ him that the problem wording is poor and your assumption would not seem so far off were it not for the fact that you stated that for the problem Bayesian Analysis was the "relevant equation"
I just asked if my guess was correct, this is, whether the answer was actually 0.8, so that Bayes formula is not required. The fact that you haven't answered whether that is actually right or wrong, instead questioning whether I know Bayesian probability, makes me wonder whether there was time spent in reviewing my guess. The wording was already fixed. Thank you :)
 

Related Threads on Calculate the probability that a robot is in a certain location

Replies
0
Views
2K
Replies
2
Views
1K
  • Last Post
Replies
6
Views
2K
Replies
1
Views
2K
Replies
0
Views
1K
  • Last Post
Replies
7
Views
1K
Replies
6
Views
943
Replies
4
Views
2K
Top