Lecture 2 - cont. Basic Probability

We start at [[handout01-ProbBasics-350F24.pdf#page=4]]:

(a) P(A)=1P(A)=.96
P(B)=1P(B)=.67

(b) AB are the set of submissions with both types of errors.

(c)

Use the diagram to get that it would be impossible to get P(AB) so far. Namely, we could have A totally within B:
Drawing canvas

This would make P(AB)=P(A)=.14. That would be the maximum, as A,B could be disjoint:

Drawing canvas
Then $P(A \cap B) = .0$ clearly.

Thus we have, with the current information that 0P(AB).14.

(d) AB represents getting either a syntax error or a logic error (just any error for this case).

(e) P(AB)=P(A)+P(B)P(AB) (since we don't want to count the intersection bit twice). As a result then since P(AB)[0,.14] then we have:

P(AB)=.14+.33P(AB)=.47P(AB)[.33,.47]

This is the same addition rule we derived separately.
(f) If we are given the P(AB)=.05 then we can use our formula to get:

P(AB)=.14+.33.05=.47.05=.42

(g) P(AB)=1P(AB)=1.42=.58.

(h) P(AB)=P(AB)P(A)=.42.14=.28.

Contingency Table

We can make a contingency table for this situation:

Syntax Errors B No Syntax Errors B
Logic Errors A .14
No Logic Errors A
.33 1.0

With the supposition that P(AB)=.05:

Syntax Errors B No Syntax Errors B
Logic Errors A .05 .09 .14
No Logic Errors A .28 .58 .86
.33 .67 1.0
The columns will add up to the bottom number, and the rows add to the last column.

(f) P(AB)=.14+.33.05=.42 as we found before.
(g) P(AB)=.58
(h) P(AB)=.28

A 3 Example

(a)


(b) The .07 probability seen in the diagram refers to ABC which is a purely minor defect.