Individual Assignment

Download as pdf or txt
Download as pdf or txt
You are on page 1of 9

FACULTY OF SCIENCE COMPUTER AND MATHEMATICS

CS230

APPLIED PROBABILITY AND STATISTICS


STA416

CSC584

Individual Assignment

Lecturer Name: DR. FAIZ BIN ZULKIFLI

Name Student ID

MOHAMAD AMIRUL AMIN BIN MOHD NAZLI 2022800956


QUESTION 1

a) Arranging 11 Persons with 3 Always Together

We treat the three persons as a single unit, reducing the problem to arranging 9 units (8
individuals + 1 group of 3).

1. Arrange the 9 units: 9! ways.

2. Arrange the 3 persons within their group: 3! ways.

Total number of ways: 9! × 3!

Calculating:

9! = 362880

3! = 6

9! ×3! = 362880 × 6

= 2177280

So, there are 2,177,280 ways to arrange the 11 persons with the 3 persons always together.

b) Selecting 4 Children with at Least 3 Boys


We have 6 boys and 4 girls. We need to select 4 children such that at least 3 are boys.
Given:

Boys = 6

Girls = 4

Formula used:

At least one boy = total selection - no boy selection

nCr = n! / [r! (n - r)!]

Where n = total possible number

r = required selection number

Calculation:

Total number of children = 6 + 4 = 10

Total number of selections


10C4 = (7x8×9×10) / (4×3×2)
= 210

No boy selection

4C4 = 1

At least one boy = 210 - 1 = 209

There are 209 ways to select at least one boy.

c) Probability Questions

Given: 𝑃𝑃(𝐴𝐴)=0.28P(A)=0.28 𝑃𝑃(𝐵𝐵)=0.45P(B)=0.45 𝑃𝑃(𝐴𝐴∩𝐵𝐵) =0.21

i) Find 𝑃𝑃(𝐴𝐴∪𝐵𝐵) P(A∪B):

𝑃𝑃(𝐴𝐴∪𝐵𝐵) =𝑃𝑃(𝐴𝐴)+𝑃𝑃(𝐵𝐵)−𝑃𝑃(𝐴𝐴∩𝐵𝐵)

Calculating: 𝑃𝑃(𝐴𝐴∪𝐵𝐵) =0.28+0.45−0.21=0.52

ii) Find 𝑃𝑃(𝐴𝐴′∩𝐵𝐵′) P(A′∩B′):

Using the complement rule:

𝑃𝑃(𝐴𝐴′) =1−𝑃𝑃(𝐴𝐴)=1−0.28=0.72

𝑃𝑃(𝐵𝐵′) =1−𝑃𝑃(𝐵𝐵)=1−0.45=0.55

Using De Morgan's Law: 𝑃𝑃(𝐴𝐴′∩𝐵𝐵′) =1−𝑃𝑃(𝐴𝐴∪𝐵𝐵)

Calculating: 𝑃𝑃(𝐴𝐴′∩𝐵𝐵′) = 1−0.52=0.48

iii) Are 𝐴𝐴′ and 𝐵𝐵′ independent events?

Two events 𝐴𝐴 and 𝐵𝐵 are independent if: 𝑃𝑃(𝐴𝐴∩𝐵𝐵) =𝑃𝑃(𝐴𝐴)⋅𝑃𝑃(𝐵𝐵)

For 𝐴𝐴′ and 𝐵𝐵′:

𝑃𝑃(𝐴𝐴′∩𝐵𝐵′) = 0.48

𝑃𝑃(𝐴𝐴′) ×𝑃𝑃(𝐵𝐵′) = 0.72×0.55 = 0.396

Since 0.48 ≠ 0.3960, 𝐴𝐴′=0.396, 𝐴𝐴′ and 𝐵𝐵′ are not independent events.
d) Vaccination and Chicken Pox

i. Tree Diagram:

ii. Probability that a baby is not infected by chicken pox:

𝑃𝑃(Not Infected)=𝑃𝑃(Vaccinated)×𝑃𝑃(Not Infected∣Vaccinated)+𝑃𝑃(Not Vaccinated)×𝑃𝑃(Not Infecte


d∣Not Vaccinated)

Calculating:

𝑃𝑃 (Not Infected) = 0.55 × 0.85 + 0.45 × 0.45

= 0.4675 + 0.2025

= 0.67

So, the probability that a baby is not infected by chicken pox is 0.67.

iii. Given a baby is infected, probability it is not vaccinated:

We use Bayes' Theorem:

𝑃𝑃 (Not Vaccinated ∣ Infected) = (𝑃𝑃 (Infected ∣ Not Vaccinated) ×𝑃𝑃 (Not Vaccinated)) / 𝑃𝑃
(Infected)

First, calculate 𝑃𝑃 (Infected)P(Infected):

𝑃𝑃 (Infected)=𝑃𝑃 (Vaccinated)×𝑃𝑃 (Infected ∣ Vaccinated) +𝑃𝑃 (Not Vaccinated) ×𝑃𝑃 (Infected ∣


Not Vaccinated)

𝑃𝑃 (Infected) = 0.55 × 0.15 + 0.45 × 0.55


𝑃𝑃 (Infected) = 0.0825 + 0.2475 = 0.33

Now, calculate 𝑃𝑃 (Not Vaccinated ∣ Infected):

𝑃𝑃 (Not Vaccinated ∣ Infected) = 0.55 × 0.45 / 0.33

𝑃𝑃 (Not Vaccinated ∣ Infected) = 0.2475 / 0.33 ≈ 0.75

So, the probability that a baby is not vaccinated given that it is infected is 0.75.

QUESTION 2

a) Distinct Arrangements of 'ATTENDANCE' with Two T's Together

The word 'ATTENDANCE' consists of 10 letters with the following frequencies:

• A: 2

• T: 2

• E: 2

• N: 2

• D: 1

• C: 1

We need to find the number of distinct arrangements where the two T's are together.
Consider the two T's as a single unit or block. This reduces the problem to arranging 9 units:
(TT), A, A, E, E, N, N, D, C.

The total number of distinct arrangements of these 9 units is given by:

9!
2! ∗ 2! ∗ 2!

Where:

• 9! is the total number of permutations of 9 units.

• 2!, 2!, 2! account for the repeated letters A, E, and N respectively.

Calculating this:

9! = 362880

2! = 2

362880 362880
(2 × 2 × 2)
= 8
= 45360

Thus, the number of distinct arrangements where the two T’s are together is 45360.

b) Events A and B with Given Probabilities

Given:

5
• 𝑃𝑃(𝐴𝐴) =
12

7
• 𝑃𝑃(𝐴𝐴∣𝐵𝐵′) =
12

1
• 𝑃𝑃(𝐴𝐴∩𝐵𝐵) =
8

i) To find P(B):

Using the formula P (A ∩ B) = P(A|B) * P(B), we can rearrange to get:

P(B) = P (A ∩ B) / P(A|B)

However, we don't know P(A|B). Let's use the law of total probability:

P(A) = P(A|B) * P(B) + P(A|B') * P(B')

5/12 = P(A|B) * P(B) + 7/12 * (1 - P(B))

Solving this system of equations, we get:

7
P(B) =
24

ii) To find P(A|B):

Using the formula P(A|B) = P (A ∩ B) / P(B):

1
8
P(A|B) = 7
24

3
=
7

iii) To find P (A ∪ B):

Using the formula P (A ∪ B) = P(A) + P(B) - P(A ∩ B):

5 7 1
P (A ∪ B) = + −
12 24 8

19
=
24
c) Relationship between Blood Pressure and Heartbeat Abnormalities

i. Tree Diagram

Probabilities on the branches:

• 𝑃𝑃(𝐻𝐻) = 0.14

• 𝑃𝑃(𝐼𝐼∣𝐻𝐻) = 0.15

• 𝑃𝑃(𝑅𝑅∣𝐻𝐻) = 0.85

• 𝑃𝑃(𝐿𝐿) = 0.22

• 𝑃𝑃(𝐼𝐼∣𝐿𝐿) = 0.05

• 𝑃𝑃(𝑅𝑅∣𝐿𝐿) = 0.95

• 𝑃𝑃(𝑁𝑁) = 0.64

• 𝑃𝑃(𝐼𝐼∣𝑁𝑁) = 0.02
• 𝑃𝑃(𝑅𝑅∣𝑁𝑁) = 0.98

ii) Probability of an Irregular Heartbeat

Using the law of total probability:

𝑃𝑃(𝐼𝐼) = 𝑃𝑃(𝐼𝐼∩𝐻𝐻) + 𝑃𝑃(𝐼𝐼∩𝐿𝐿) + 𝑃𝑃(𝐼𝐼∩𝑁𝑁)

Where:
𝑃𝑃(𝐼𝐼∩𝐻𝐻) = 𝑃𝑃(𝐻𝐻)⋅𝑃𝑃(𝐼𝐼∣𝐻𝐻)
𝑃𝑃(𝐼𝐼∩𝐿𝐿) = 𝑃𝑃(𝐿𝐿)⋅𝑃𝑃(𝐼𝐼∣𝐿𝐿)
𝑃𝑃(𝐼𝐼∩𝑁𝑁) = 𝑃𝑃(𝑁𝑁)⋅𝑃𝑃(𝐼𝐼∣𝑁𝑁)

Calculating each term:

𝑃𝑃(𝐼𝐼∩𝐻𝐻) = 0.14 × 0.15 = 0.021


𝑃𝑃(𝐼𝐼∩𝐿𝐿) = 0.22 × 0.05 = 0.011
𝑃𝑃(𝐼𝐼∩𝑁𝑁) = 0.64 × 0.02 = 0.0128

Summing these probabilities:

𝑃𝑃(𝐼𝐼) = 0.021 + 0.011 + 0.0128 = 0.0448

Therefore, the probability that a patient has an irregular heartbeat is:

𝑃𝑃(𝐼𝐼) = 0.0448

ii. Probability of High Blood Pressure given Regular Heartbeat

Using Bayes' theorem:

P(R∩H)
𝑃𝑃(𝐻𝐻∣𝑅𝑅) = P®

First, calculate 𝑃𝑃(𝑅𝑅):

𝑃𝑃(𝑅𝑅) = 𝑃𝑃(𝑅𝑅∩𝐻𝐻) + 𝑃𝑃(𝑅𝑅∩𝐿𝐿) + 𝑃𝑃(𝑅𝑅∩𝑁𝑁)

Where:
𝑃𝑃(𝑅𝑅∩𝐻𝐻) = 𝑃𝑃(𝐻𝐻)⋅𝑃𝑃(𝑅𝑅∣𝐻𝐻)
𝑃𝑃(𝑅𝑅∩𝐿𝐿) = 𝑃𝑃(𝐿𝐿)⋅𝑃𝑃(𝑅𝑅∣𝐿𝐿)
𝑃𝑃(𝑅𝑅∩𝑁𝑁) = 𝑃𝑃(𝑁𝑁)⋅𝑃𝑃(𝑅𝑅∣𝑁𝑁)

Calculating each term:


𝑃𝑃(𝑅𝑅∩𝐻𝐻) = 0.14 × 0.85 = 0.119
𝑃𝑃(𝑅𝑅∩𝐿𝐿) = 0.22 × 0.95 = 0.209
𝑃𝑃(𝑅𝑅∩𝑁𝑁) = 0.64 × 0.98 = 0.6272

Summing these probabilities:

𝑃𝑃(𝑅𝑅) = 0.119 + 0.209 + 0.6272 = 0.9552

Now, apply Bayes' theorem:

P(R∩H) 0.119
𝑃𝑃(𝐻𝐻∣𝑅𝑅) = P(R)
= ≈ 0.1246
0.9552

Therefore, the probability that a patient has high blood pressure given that they have a
regular heartbeat is:

𝑃𝑃(𝐻𝐻∣𝑅𝑅) ≈ 0.1246

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy