When we know the density of
θ
θ, the likelihood function can be expressed as
pr|
ℳ
i
r=∫pr|
ℳ
i
θrpθθdθ
p
r
ℳ
i
r
θ
p
r
ℳ
i
θ
r
p
θ
θ
and the likelihood ratio in the random parameter case becomes
Λr=∫pr|
ℳ
i
θrpθθdθ∫pr|
ℳ
i
θrpθθdθ
Λ
r
θ
p
r
ℳ
i
θ
r
p
θ
θ
θ
p
r
ℳ
i
θ
r
p
θ
θ
Unfortunately, there are many examples where either the
integrals involved are intractable or the sufficient statistic
is virtually the same as the likelihood ratio, which can be
difficult to compute.
A simple, but interesting, example that results in a
computable answer occurs when the mean of Gaussian random
variables is either zero (model 0) or is
±m
±
m
with equal probability (hypothesis 1). The second hypothesis
means that a non-zero mean is present, but its sign is not
known. We are therefore stating that if hypothesis one is in
fact valid, the mean has fixed sign for each observation -
what is random is its a priori value. As
before,
L
L
statistically independent observations are made.
ℳ
0
:
r∼0σ2I
ℳ
0
:
r
0
σ
2
I
ℳ
1
:
r∼mσ2I
ℳ
1
:
r
m
σ
2
I
m=m…mProb1/2-m…-mProb1/2
m
m
…
m
12
m
…
m
12
The numerator of the likelihood ratio is the sum of two
Gaussian densities weighted by
1/2 12 (the
a priori probability values), one having a
positive mean, the other negative. The likelihood ratio,
after simple cancellation of common terms, becomes
Λr=12ⅇ2m∑l=0L-1
r
l
-Lm22σ2+12ⅇ-2m∑l=0L-1
r
l
-Lm22σ2
Λ
r
1
2
2
m
l
0
L
1
r
l
L
m
2
2
σ
2
1
2
-2
m
l
0
L
1
r
l
L
m
2
2
σ
2
and the decision rule takes the form
coshmσ2∑l=0L-1
r
l
≷
ℳ
0
ℳ
1
ηⅇLm22σ2
m
σ
2
l
0
L
1
r
l
≷
ℳ
0
ℳ
1
η
L
m
2
2
σ
2
where
coshx
x
is the hyperbolic cosine given simply as
ⅇx+ⅇ-x2
x
x
2
. As this quantity is an even function, the sign of
its argument has no effect on the result. The decision rule
can be written more simply as
|∑l=0L-1
r
l
|
≷
ℳ
0
ℳ
1
σ2|m|arccoshηⅇLm22σ2
l
0
L
1
r
l
≷
ℳ
0
ℳ
1
σ
2
m
η
L
m
2
2
σ
2
The sufficient statistic equals the
magnitude of the sum of the observations
in this case. While the right side of this expression, which
equals
γ γ, is complicated, it need only
be computed once. Calculation of the performance
probabilities can be complicated; in this case, the
false-alarm probability is easy to find and the others more
difficult.