# Pattern Recognition with basic probability

I am a college student and have Pattern Recognition as a course this semester and I am really struggling with it, reasons could be difference in teaching style of the instructor and different type of understanding when reading the text book [Duda and heart, pattern classification]. I just read chapter two and understood the concept explained in it, Bayes Decision Theory. Now I see the first problem, numerical that is and the question is:

Select optimal decision where,

P(x|w1) = N(2,0.5)
P(x|w2) = N(1.5,0.2)

p(w1)=2/3
p(w2)=1/3

lambda(cost of action matrix) =  1   2
3   4


I need help in two departments, firstly how to solve this and second how exactly do I tackle this subject. The idea of pattern recognition is pleasing but without understanding what to do it is frustrating.

-

In answer to your first question, I assume that the problem is that you want to decide whether $\omega_1$ or $\omega_2$ happened given an observation of $x$, and you want to decide this in such a way as to minimize the cost. Your total cost for deciding $\alpha_j$ is just $$R(\alpha_j|x)=\sum_{i=1}^2\lambda(\alpha_j|\omega_i)p(\omega_i|x).$$ I assume that you know how to compute $p(\omega_i|x)$ using Bayes rule, and I do not know how your $\lambda$ matrix is arranged, whether the decisions are in the rows or columns, so I'll let you do some work before continuing.

For your second question, let me preface my remarks by saying that I am not an academic, I am just a code monkey teetering on the brink of geezerdom, and one of the many mental infirmities bestowed by geezerdom is an irresistible urge to give advice that one knows will go unheeded.

First: Your best bet for figuring out how best to understand pattern recognition is to ask your professor or TA. They are best suited to this purpose, as they know the strengths and weaknesses of the prerequisite courses, and your strengths and weaknesses as well, and they know both much better than some random fool on the internet. Amazingly, your university probably mandates that both your TA and professor sets aside some time for just this purpose.

Note: Approaching your professor and blaming your lack of success on his/her teaching style is not likely to be a good strategy. Most professors are human, or nearly so, and are not likely to exhibit the desired amount of compassion if you blame your problems on them.

Second: Review your prerequisites, in this case probability, particularly conditional probability and Bayes rule. This means picking up your probability textbook and doing as many exercises as you can stand, doing at least enough so that the tedium outweighs the difficulty. In mathematics there are usually two reasons for difficulty, lack of facility with the prerequisites, and not paying enough attention to the details. In your case, I suspect both, but you cannot fix the second until you fix the first.

Third: Learn to use google. In about a minute I found this which contains a worked example much like your problem.

-