HW5_solution
pdf
keyboard_arrow_up
School
University of Texas *
*We aren’t endorsed by this school
Course
440
Subject
Industrial Engineering
Date
Jan 9, 2024
Type
Pages
12
Uploaded by surker21
CEE 373
Homework #5
Due date: October 6 at 5pm
Total: 100 points
1. (20 points) The following questions pertain to a probabilistic model for the ran-
dom variable,
X
, which represents the force acting on a structural column.
Suppose
X
is assumed to have a Normal (i.e., Gaussian) distribution, param-
eterized by a mean of
µ
X
= 15
.
0kips and a standard deviation of
σ
X
= 1
.
25
kips.
(a) Using the Standard Normal Table, find the probability that
X
will be be-
tween 14 and 16 kips.
(b) Using the Standard Normal Table, find the probability that
X
will be greater
18 kips.
(c) Suppose the steel manufacturer you are considering tells you they can fabri-
cate columns with the capacity to carry loads (or forces) within 95% of the
average forces acting on this column. What is the range in kips for the load
capacity for these columns?
(d) Now, suppose you need to design the column such that its probability of
failure, under random loading, is less than 5
×
10
−
3
. The load at which the
column fails is called its
buckling load
, or
x
fail
. Using the Standard Normal
Table, what is the minimum buckling load the column can have, and still
meet this design requirement?
Hint: You will want
P
(
X
≥
x
fail
) = 5
×
10
−
3
.
(e) (
Computer Needed.
) Confirm your answers for parts (a) - (d) using Python
(or your other favorite coding language). If you are using Python, you can
reference the functions introduced in lecture, which are also documented at
https://docs.scipy.org/doc/scipy/reference/generated/scipy.stats.
norm.html#scipy.stats.norm
.
Solution:
(a) First, express the problem in terms of the equivalent standard normal random
variable,
Z
. We have that
Z
=
X
−
µ
X
σ
X
and thus if
X
∈
[14
,
16] this is equivalent to
Z
being in the range
Z
∈
14
−
15
1
.
25
,
16
−
15
1
.
25
= [
−
0
.
8
,
0
.
8]
Page 1 of 12
CEE 373
Homework #5
The probability of this is
P
[
−
0
.
8
< Z
≤
0
.
8] =Φ(0
.
8)
−
Φ(
−
0
.
8)
=0
.
7881
−
0
.
2119
=0
.
5762
(b) Similarly, we have that the range
X
∈
[18
,
∞
) is equivalent in the standard
normal variable
Z
to
Z
∈
18
−
15
1
.
25
,
∞
= [2
.
4
,
∞
)
Consequently we have that
P
[2
.
4
< Z <
∞
) =Φ(
∞
)
−
Φ(2
.
4)
=1
−
0
.
9918
=0
.
0082
(c) The average force acting on this column is
µ
X
= 15
.
0 kips. The question asks
for loads within 95% of
µ
X
. Knowing that
X
is normally distributed, we know
that 95% of the probability falls within 2 standard deviations
σ
X
of the mean
for Normal distributions (because of the 68-95-99.7 rule). Therefore, the range
of loads the manufacturers’ columns can carry is
[
µ
X
−
2
σ
X
, µ
X
+ 2
σ
X
]
= [15
−
2(1
.
25)
,
15 + 2(1
.
25)]
= [12
.
5
kips,
17
.
5
kips
]
(d) First, look for the value of
z
such that
P
[
Z > z
] = 5
×
10
−
3
Equivalently,
P
[
Z
≤
z
] = 1
−
5
×
10
−
3
= 0
.
995
From the tables, this value is approximately
z
= 2
.
575.
The corresponding
value of
x
is then
x
=
µ
X
+
σ
X
z
= 15 + 1
.
25
×
2
.
575 = 18
.
21
Thus, we have that
P
[
X
≥
18
.
21] = 5
×
10
−
3
.
(e) The solution code can be found here:
https://colab.research.google.
com/drive/1fMi4hcGmK_Wa57fJCLkgoXrG5sRkURwf?usp=sharing
.
Page 2 of 12
CEE 373
Homework #5
2. (20 points) [
Computer needed.
] The annual precipitation,
R
, at a particular loca-
tion, has mean
µ
R
= 900
mm
and a standard deviation of
σ
R
= 300
mm
. You are
interested in how the distribution type you assume for
R
will impact predictions
for the probability of exceeding different precipitation levels.
(a) Plot the probability density function for
R
,
f
R
(
r
), assuming that
R
has:
1. A normal distribution
2. A lognormal distribution
3. A uniform distribution
Plot all three PDFs on one single figure to ease comparison of the three dis-
tributions. You will need to calculate the parameters for each distributions
and using plotting functions developed in previous homeworks.
Note: for the lognormal distribution, the
scipy.stats.lognormal
function
has strange input parameters, so please defer to defining your own pdf func-
tion as discussed in lecture.
(b) The exceedance probability is the probability associated with exceeding a
certain value of interest,
r
. Compute the
r
values with exceedance proba-
bilities of 0.5, 0.1, 0.01 and 0.001, using each of the four distribution types.
Provide documentation to explain how you computed these values, and then
summarize your results by completing this table:
Distribution
P
(
R > r
) = 0
.
5
P
(
R > r
) = 0
.
1
P
(
R > r
) = 0
.
01
P
(
R > r
) = 0
.
001
Normal
Lognormal
Uniform
(c) Now evaluate the sensitivity of the computed probability to the distribution
type assumed. For which of the three exceedance probabilities is the answer
most sensitive to the distribution type? Why do you think this is? (Refer
to features in your figure and your table when answering this question.)
Solution:
(a) The parameters for each distribution are calculated as follows.
Normal, same as what is given:
•
µ
R
= 900
•
σ
R
= 300
For the lognormal distribution, you need to calculate
µ
lnX
and
σ
lnX
using the
equations for
µ
X
and
σ
X
provided in our common distributions handout. The
resulting parameters for the lognormal distribution are:
Page 3 of 12
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
- Access to all documents
- Unlimited textbook solutions
- 24/7 expert homework help
CEE 373
Homework #5
•
σ
lnR
=
r
ln
(
σ
2
R
µ
2
R
+ 1
)
= 0.3246
•
µ
lnR
= ln(
µ
R
)
−
1
2
σ
2
lnR
= 6.7497
And for the uniform distribution, you need to calculate
a
and
b
using the
equations for
µ
X
and
σ
X
provided in our common distributions handout. The
resulting parameters for the uniform distribution are:
•
a
=
µ
R
−
σ
R
√
12
2
•
b
= 2
µ
R
−
a
A plot of all three distributions using these parameters is shown below:
(b) To calculate the exceedance probabilities, you can use the equations for the
CDF,
F
R
(
r
) for each distribution provided in the handout.
P
(
R > r
) =
1
−
F
R
(
r
). The resulting exceedance probabilities are:
Distribution
P
(
R > r
) = 0
.
5
P
(
R > r
) = 0
.
1
P
(
R > r
) = 0
.
01
P
(
R > r
) = 0
.
001
Normal
900
1284
.
5
1597
.
9
1827
.
1
Lognormal
853
.
8
1294
.
3
1816
.
8
2328
.
0
Uniform
900
1315
.
7
1409
.
2
1418
.
6
(c) As the probability of exceedance gets smaller, the choice of distribution type
has a greater impact.
The mean and standard deviation are good descriptors of the behavior of a
probability distribution near its central values.
The distributions thus give
similar results in this region (i.e., for a 0.5 probability of exceedance). But as
we consider outcomes in the
tails
of the distributions, the differences between
the distributions become much more pronounced, and the choice of distribution
model becomes much more significant.
Page 4 of 12
CEE 373
Homework #5
3. (20 points) You are installing active dampers in a new high-rise building, to limit
the deflections of the building during high winds. Your job is to select the number
of dampers to install in the building. The building’s damping system will fail if
at least half of its dampers fail.
Assume that all dampers have an identical probability of failure,
p
f
, in a wind-
storm and that the failure of one damper is independent of the failure of any
other one.
Hint: a damper has a binary outcome when exposed to high winds:
failure or no failure. This will help you select which distribution to use.
Note: To see what a damper is, visit this video:
https: // youtu. be/ 9FJ7oFtqxpQ?
si= y4dJzmLmbV9QeEJh
(a) If
p
f
= 0
.
1, would a two-damper system or a four-damper system be safer?
You can consider a safe system to be a system that has a lower probability
of failure.
(b) If
p
f
= 0
.
5, is the two-damper system or the four-damper system safer?
(c) (
Computer recommended.
) Now let’s imagine
p
f
= 0
.
5 still, but you are con-
sidering installing 20-dampers (this is a big high-rise). What is the probabil-
ity of failure of the system in this case? If you approximate this probability
of failure with the normal distribution, do you get a similar value?
(d) What assumptions did you make to calculate the probabilities of failure in
parts (a) - (c)?
Solution:
Note: if you used a different definition of ”at least” for this problem, we
will accept both interpretations (either greater than or greater than or equal to).
(a) We are looking for the probability of failure for a damper system. Each damper
can either fail or not fail (a single experiment of the Bernoulli Distribution).
The combined failures of all dampers is a Bernoulli sequence (multiple exper-
iments or dampers). We are interested in a certain number of dampers failing
in order for the system to fail.
In order for a two-damper system to fail, at least half of its dampers must fail
(e.g., 2 dampers). Therefore,
P
(
fail
) =
P
(
x
= 2). In this case, the parameters
for the binomial distribution are:
•
n
= 2 dampers
•
p
=
p
f
= 0
.
1
•
x
= 2 dampers
To calculate
P
(
fail
) for the two-damper system, we plug these parameters
into the binomial PDF:
p
X
(
x
= 2) =
2
2
p
2
(1
−
0
.
1)
2
−
2
= 0
.
01
Page 5 of 12
CEE 373
Homework #5
Therefore,
P
(
fail
) = (0
.
1)
2
= 0
.
01 for the two-damper system.
For the four-damper system, either 3 or 4 dampers failing will cause the system
to fail.
Therefore,
P
(
fail
) = P(x = 3 or x = 4).
The parameters for the
binomial distribution for 3 dampers failing are (
x
= 3,
n
= 4, and
p
= 0
.
1)
and for 4 dampers failing are (
x
= 4,
n
= 4, and
p
= 0
.
1).
Therefore, for the four damper system:
P
(
x
= 3 or
x
= 4) =
P
(
x
= 3) +
P
(
x
= 4) = 0
.
0036 + 0
.
0001 = 0
.
0037
This is the same as saying
P
(
x
≥
3), so you could calculate this using 1
−
F
X
(2)
as well.
P
(
fail
) is lower for the four-damper system than the two-damper system, so
the four-damper system is safer.
This might match our intuition that more
dampers are safer, but part (b) is a counterfactual to that intuition.
(b) Following the same process as above for part (a) but with different values for
p
f
, we get the following values for
P
(
fail
):
•
0.25 for the two-damper system
•
0.3125 for the four-damper system
With a higher probability of failure, the two-damper system is safer.
(c) Using the binomial distribution, we calculate the probability of failure of the
system using the below parameters:
•
n
= 20 dampers
•
p
=
p
f
= 0
.
5
Note that
P
(
fail
) is the case when
X
= (10, 20]. Or more than 10 dampers
fail, up to all 20/20 dampers failing. This probability can be calculated in a
couple of ways:
You can calculate it in the same way was calculated for parts (a) and (b):
P
(
fail
) =
p
X
(
x
= 11) +
p
X
(
x
= 12) +
· · ·
+
p
X
(
x
= 20) = 0
.
412
You can also calculate it using the
binomical CDF
(evaluated on computer):
P
(
fail
) =
F
X
(
x
= 20)
−
F
X
(
x
= 10) = 0
.
412
Note, because the upper bound of this distribution has negligible probability
(i.e., when
x >
20), this is the same as:
P
(
fail
) = 1
−
F
X
(
x
= 10) = 0
.
412
To use the normal distribution to approximate this probability, you instead
calculate the probability of failure of the system using the below parameters:
Page 6 of 12
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
- Access to all documents
- Unlimited textbook solutions
- 24/7 expert homework help
CEE 373
Homework #5
•
µ
=
np
= 10 dampers
•
σ
X
=
p
np
(1
−
p
) = 2
.
236
In this case, you are looking for
P
(10
< X
≤
20)
The probability of failure using the
normal CDF
is thus (evaluated on com-
puter):
P
(
fail
) =
F
X
(
x
= 20)
−
F
X
(
x
= 10) = 0
.
5
Same as above, because the upper bound of this distribution has negligible
probability (i.e., when
x >
20), this is really similar to:
P
(
fail
) = 1
−
F
X
(
x
= 10) = 0
.
4999999
(The value of x here can be flexible inside of 10 to 11, because this is just
approximation.)
The probabilities we calculated are shown below:
The binomial and normal values are not similar. If there were more dampers,
these would become more similar.
(d) The results above rely on the assumption of independent damper failures.
This assumption may not be valid (e.g., the dampers are manufactured and
serviced using similar procedures, and they may all fail if the power fails during
a windstorm, etc.). These potential
common cause failures
may cause us to
question our results.
A less critical assumption is that the system failure is a single trial at a single
instant in time. Four dampers might provide extra safety because the failure
of the first damper may serve as a warning of trouble for the other dampers,
allowing the operators to perform inspections on the other dampers.
Page 7 of 12
CEE 373
Homework #5
4. (20 points) Let
X
= the time between two arrivals of a car at a stoplight. The
average time between intervals based on another stoplight in town is 2.5 minutes.
(a) What is the standard deviation for the average time between two arrivals?
(b) What is the probability that the arrival time is between 1 and 2 minutes?
(c) What is the probability that the arrival time is less than the average?
(d) What is the median arrival time? Is this greater or less than the mean arrival
time? Why?
Solution:
(a) Given that we are interested in the time between events, this should indicate to
us that
X
has an exponential PDF. Therefore, because the mean and standard
deviation for exponential PDF’s are the same, we get
sigma
X
=
µ
X
= 2
.
5
minutes.
Another way to solve this is solve for
λ
.
Based on the equation for
µ
for a
exponential random variable,
λ
=
1
µ
X
= 0
.
4.
Plugging this value in for
λ
, we get
σ
X
=
q
1
λ
2
= 2
.
5 minutes.
(b) To calculate
P
(1
≤
x
≤
2) we can use the CDF of the exponential PDF:
P
(1
≤
x
≤
2) =
F
X
(2)
−
F
X
(1) = (1
−
e
−
0
.
4
∗
2
)
−
(1
−
e
−
0
.
4
∗
1
) = 0
.
2209
(c) To calculate
P
(
x
≤
µ
X
), we can still use the CDF:
P
(
x
≤
µ
X
) =
F
X
(
µ
X
) = (1
−
e
−
0
.
4
∗
2
.
5
) = 0
.
632
(d) The median arrival time, ˜
x
, is the arrival with 50% of the probability less than
this value or
F
X
(˜
x
) = 0
.
5.
Therefore:
1
−
e
−
0
.
4
∗
˜
x
= 0
.
5
Solving for ˜
x
, we get
ln
(1
−
0
.
5)
−
0
.
4
= 1
.
732 minutes.
This is less than the mean because the exponential distribution is skewed
right. Therefore the mean is pulled towards the tail, which is on the right of
the distribution, so it’s greater than the median.
In addition,
F
X
(
µ
X
)
> F
X
(˜
x
), indicating there is more area to the left of
µ
X
than ˜
x
, indicating
µ
X
is larger.
5. (20 points) [
Computer required.
] This problem will ask you about a series of dis-
tributions we covered in lecture. You will use a combination of code you developed
Page 8 of 12
CEE 373
Homework #5
in previous homeworks plus the provided starter code for this question:
https://
colab.research.google.com/drive/1XJosRank4Xl8HO-ljGnBMgAhI0YCv_fS?usp=
sharing
.
(a) The capacity of a building to withstand earthquake loads without damage
is a random variable,
X
, that has a gamma distribution with a mean of
2000 tons and a standard deviation of 800 tons. Plot the probability density
function (PDF) and cumulative distribution function (CDF) for
X
. What
is the probability that the building’s capacity
will not be
strong enough to
withstand a load of 3000 tons?
(b) In a complex of five of the same buildings as part (a), what is the probability
that at least three of them will be damaged because they cannot withstand
a load of 3000 tons? Assume that the occurrences of damage,
Y
, to the five
different buildings are independent.
(c) The time between earthquakes with shaking strong enough to create loads
of 3000 tons,
T
, can be represented by an exponential distribution with an
occurrence rate,
λ
, of once every 10 years. What is the probability that there
will be zero occurrences of earthquakes of this size over t=25 years?
(d) Now assume that for a new building of interest, the probability of being
damaged when subjected to smaller earthquakes (e.g., smaller than our pre-
viously considered earthquake) is instead 1
/
40. It is also assumed that these
small earthquakes occur yearly. Calculate the probability that this building
will be damaged
after exactly 40 years
. Plot the PMF and CDF function for
the probability distribution of the building being damaged after ”n” years.
(You can use the
stats.geom.pmf
and
stats.geom.cdf
functions in the
Scipy module.)
(e) The replacement cost ratio (or the ratio of the costs of damage to the to-
tal cost) for a building from an earthquake,
C
, follows a Beta distribution
(
Beta
(
α, β
)). The parameters for
f
C
are related to earthquake forces on the
building through the following equation:
α
=
Earthquake force
1000
!
3
,
β
= 10
Plot the PDF and CDF of
C
when the earthquake force is 2000 tons. What
is the average replacement cost ratio? (You can use
stats.beta.pdf
and
stats.beta.cdf
functions in Scipy module.)
Solution:
The solution code is here:
https://colab.research.google.com/drive/
1Ffwty7kx0UAEVIcxoTO0r31NolYyiBsW?usp=sharing
.
Page 9 of 12
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
- Access to all documents
- Unlimited textbook solutions
- 24/7 expert homework help
CEE 373
Homework #5
Note: if you used a different definition of ”at least” for this problem, we will accept
both interpretations (either greater than or greater than or equal to).
(a) If we decide earthquake forces as
x
,
X
∼
Gamma
(
α, β
). In the question,
µ
=
α
β
= 2000
σ
=
α
β
2
= 800
2
From these values,
α
= 6
.
25 and
β
= 0
.
003125.
Therefore, the gamma distribution is:
f
(
x
) =
β
α
Γ(
α
)
x
α
−
1
e
−
βx
=
0
.
003125
6
.
25
Γ(6
.
25)
x
6
.
25
−
1
e
−
0
.
003125
x
Plots of PDF and CDF:
The probability can be calculated like this.
P
(
x <
3000) =
F
(3000) = 0
.
888
(b)
p
=
P
(
x <
3000) =
F
(3000) = 0
.
888
,
q
= 1
−
p
= 0
.
112
Three buildings will be damaged:
P
(
three buildings damaged
) =
5
C
3
(
p
3
)
q
2
= 0
.
088
Four buildings will be damaged:
P
(
four buildings damaged
) =
5
C
4
(
p
4
)
q
1
= 0
.
348
Five buildings will be damaged:
P
(
five buildings damaged
) =
5
C
5
(
p
5
)
q
0
= 0
.
552
At least three buildings will be damaged:
P
(
at least three buildings damaged
) = 0
.
988
Page 10 of 12
CEE 373
Homework #5
(c) This is an exponential distribution (g(t)) and its CDF (G(t)).
g
(
t
) = 0
.
1
e
−
0
.
1
t
G
(
t
) = 1
−
e
−
0
.
1
t
Here, g(t) is the exponential distribution (T
∼
Exponential(0.1)).
The two probability can be calculated using G(x).
P
(
no x >
3000
during
25
years
) = 1
−
G
(25) = 0
.
082
(1)
(d) If we set n as years when the building will collapse, the geometric distribution
(N
∼
Geom(1/40)) can be used:
p
=
1
40
q
=
39
40
f
(
n
) =
pq
n
−
1
Therefore, the probability that the building will collapse after 40 years is:
P
(
n
= 40
yrs.
) = (
1
40
)(
39
40
)
40
−
1
= 0
.
009
Plots of PMF and CDF:
(e) When calculating parameters(
α
,
β
):
α
=
2000
1000
3
= 8
β
= 10
The replacement cost ratio follows Beta distribution (
C
∼
Beta
(
α, β
)).
f
(
x
) =
Γ(
α
+
β
)
Γ(
α
)Γ(
β
)
x
α
−
1
(1
−
x
)
β
−
1
=
Γ(8 + 10)
Γ(8)Γ(10)
x
8
−
1
(1
−
x
)
10
−
1
Page 11 of 12
CEE 373
Homework #5
Plots of PDF and CDF:
The average replacement cost ratio is 0.4444.
Page 12 of 12
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
- Access to all documents
- Unlimited textbook solutions
- 24/7 expert homework help