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

The Triangular Distribution

Carl Sorensen
April 15, 2011

It is sometimes difficult to get good data on setup and repair times. Ideally,
a large number of events (either setup or repair) would be recorded, and an
average and standard deviation could be calculated from the recorded data.
Additionally, a histogram of the times could be plotted and the general shape
of the data could be recorded.
Rare events like breakdowns, however, are difficult to measure in this way.
The distributions tend not to be normal, and the effects of rare but very long
repairs are likely to either not show up in the sample, or to overly bias the
sample if they do show up.
One way around this difficulty is to use the triangular distribution to model
the repair times. The triangular distribution has three characteristic values:
a minimum, a maximum, and a mode. The probability density increases in a
straight line from the minimum to the mode, then decreases in a straight line
to the maximum. The height of the mode is adjusted to make the area under
the curve be 1.

Probability Density 6

2 2
xmax −xmin = δ3
QQ
 Q
 Q
Q
 Q
 Q
Q
 Q -
xmin xmode xmax
Random Value

Figure 1: Probability density function for triangular distribution.

For convenience in working with the triangular distribution, we define the


differences between the critical points in the distribution

δ1 = xmode − xmin
δ2 = xmax − xmode (1)
δ3 = xmax − xmin

1
A graph of the triangular distribution is shown in Figure 1. The probability
density of the triangular distribution is given by
( 2(x−xmin ) 2(x−xmin )
(xmode −xmin )(xmax −xmin ) = δ1 δ3 for xmin < x < xmode
y= 2(xmax −x) 2(xmax −x) (2)
(xmax −xmode )(xmax −xmin ) = δ2 δ3 for xmode < x < xmax

The mean value of the triangular distribution is


1
µ= (xmin + xmode + xmax ) (3)
3
The variance of the triangular distribution is:

x2min + x2max + x2mode − xmax ∗ xmin − xmax ∗ xmode − xmode ∗ xmin


σ2 = (4)
18
In practice, the values for the triangular distribution are obtained by asking
someone who is familiar with the process three questions.
1. How long does the process generally take? (The answer to this question
is the mode).
2. What is the shortest time you can remember for the process? (The answer
to this question is the minimum).
3. What is the longest time you can remember for the process? (The answer
to this question is the maximum).
Once the values have been obtained, the triangular distribution can be com-
pletely calculated.
We can derive the equation of the density function for the triangular dis-
tribution as follows. First, we define the value of the density function at the
mode to be h (p(xmode ) = h). The total area inside the distribution is given by
the sum of the areas of the right triangle below the mode and the right triangle
above the mode
h h h
Area = δ1 + δ2 = δ3 (5)
2 2 2
Since the total area under any probability density curve must be 1, we can solve
for h
2 ∗ Area 2
h= = (6)
δ3 δ3
To the left of the mode, the density function is given by

h(x − min)
p(x) = (7)
δ1
To the right of the mode, the density function is given by
h(max − x)
p(x) = (8)
δ2

2
This gives us the value of the density function as
(
2(x−xmin )
δ1 δ3 ; xmin ≤ x ≤ xmode
p(x) = 2(xmax −x) (9)
δ2 δ3 ; xmode ≤ x ≤ xmax
The cumulative distribution function G(x) can be determined by integrating
the density function p(x):

x τ  Rx
; xmin ≤ x ≤ xmode
Z Z
xRmin
p(τ )dτ
G(x) = p(τ )dτ = p(τ )dτ = xmax
−∞ xmin 1− x
; xmode ≤ x ≤ xmax
p(τ )dτ
(10)
When combined with the expression for p(x) given above, we obtain:
(x−xmin )2
(
δ1 δ3 ; xmin ≤ x ≤ xmode
G(x) = (xmax −x)2
(11)
1− δ2 δ3 ; xmode ≤ x ≤ xmax

For calculating variances with the triangular distribution, we sometimes need


to calculate the following integral:
Z xmax
µ2 = E(x2 ) = x2 p(x)dx (12)
xmin

It can be shown that this integral evaluates to

x4mode x4 x3
 4
x4 x3
  
2 xmin 2 xmode xmax
µ2 = + min − mode + + max − mode
δ1 δ3 4 12 3 δ2 δ3 4 12 3
(13)
An easier way to evaluate this integral is to recognize that

V ariance = E[(x − µ2 )] = E(x2 ) − µ2 (14)


so

µ2 = E(x2 ) = σ 2 + µ2 (15)
and the previous equations for the mean and standard deviation can be used.

You might also like