Lecture 19

IIT Kanpur July 201
20 followers
Aug 10, 2024
[Music]
okay welcome back to the class and we
have been discussing this hard decoding
okay how this hard decoding actually
reduces to the nearest distance
likelihood rule okay plus I will use
this framework to develop soft decoding
okay before we wrap this up a quick
recap of what we have done till now okay
so we have constructed we have
considered this abstracted transmitter
and an abstracted receiver and our awgn
Channel okay so if we recall this
transmitter takes an message signal Maps
it to some quam constellation goes this
quam constellation is transmitted over
AWG and channel and then receiver
receives this receive signal R okay and
then based on this receive signal it has
to come up with this estimate of M okay
right and how this estimate of M is
calculated in our case is basically
looking at the map rule okay and what is
this map rule what do it tell it
estimates the the estimate of M is
chosen as m0 if this probability okay
which is the a posterior probability is
is greater than this a posterior
probability okay and what is this a
posterior probability basically the
posterior probability of row given M
okay into the probability of M okay
right so now what this reduces to is as
follows okay that's what we calculated
in the last class that the this PDF of
the receive signal is the PDF of the
noise and which is shifted by S not
given m not was transmitted okay and
then on right side similarly we have
shifted PDF of noise shifted by S1 and
then scaled by P of M1 okay and what is
this now this is a PDF of noise shifted
by S PDF of noise shifted by S1 okay
right now using this we'll basically
analyze few things and what are we going
to analyze okay so what we I'm going to
consider multiple examples okay and then
see how that map varies okay how does
that map rule change so what are we
saying okay when s not is one okay we
are what are we saying that s not of one
is transmitted with a probability of 7
okay recall that we are considering
binary phase shift key okay so there
will be only two values m0 and M1 okay
right and so we are transmitting s0 is
one and what is the other value minus
one and that is being transmitted by
with a probability of3 okay correct and
now if you look at it okay so the we
have to consider the noise variance
Sigma Square so this is the noise power
I'm considering for Simplicity as one
okay what is happening now is okay so if
you look at those like uh the
probabilities which we uh looked at in
the last slide okay what were they okay
so if I have them here okay no okay so
I'll have to go back a little bit okay
but what are we what is this okay this
is PDF of a gan correct okay and you
look at this what is this scaled by a
Priory probability of message and not
being transmitted okay similarly this is
a PDF of another Gan okay and then B
Escape by a Priory probability of M1 so
what am I going to do in the next slide
which I showed you just now I'm going to
plot both of
them okay plot this PDF scal by this
probability plot this PDF scal by this
probability and I just showed you right
what is we know everything from here
okay we know noise variance we know P of
m not we know what s not is right okay
then it is very easy to plot this PDF
scaled by this constant number it's very
easy to plot this PDF and scale by this
constant number correct okay right so if
you look at the plot in the next slide
that's what is
happening how many such PDFs are there
there are two PDFs okay one on the left
hand side and one on the right hand side
okay and so what is this this PDF in
blue okay where is it located it is
located at S1 which is
minus1 right this is a blue PDF okay
and why this blue PDF has a lower height
and the PDF in red because this is
scaled
by3 right this blue PDF what is the a
prary probability it's 3 right correct
and otherwise the PDF will be at one if
it is not scaled okay P of m0 is
basically if both of them are like if it
is not scaled PDF it has to its value it
Peak will be at one now we are scaling
it with probability 3 so you see this it
is reduced to the height is reduced to3
in this case it is scaled by 7 so the
height is 7 right the PDF the red PDF is
that value the height it is is at 7 okay
right okay now so this is what is
sitting on the right side and this is
one PDF and this is another PDF now what
does what do we need to calculate okay
what does basically the map rule says
when will you pick M hat as m not okay m
not is basically this s not okay when
will you pick this when this when the
probability in red is greater than
probability in blue right okay so what's
happening okay if you look at this this
is basically the first PDF okay and this
is the second PDF okay now what is
happening here so these two PDFs
intersect at certain Valu okay I'm
calling this value as a okay and
whenever they intersect wherever they
intersect
these the value is the probability is
same of course right that is basically
this they are intersecting and that
value will be same okay whenever they
are intersecting now on this side okay
this intersection point I'm calling it
as a threshold a okay right if so what
are we saying here on this side of
threshold what is happening this PDF has
a lower value than this PDF right you
look at this what is happening to this
blue PDF on this side has a lower value
than the red PDF correct on this side of
the threshold what is happening right
that this blue PDF has a higher value
than the red PDF correct right so and
what was the rule so what is this rule
when whenever this probability is
greater row given s into P of M is
greater what will you
declare the the estimate of message will
become M and where is it happening it is
happening on this side of the threshold
Okay so this is basically becoming the
threshold okay so if this received value
is greater than this threshold what does
that mean okay that this PDF is greater
then what will happen if this PDF is
greater which message was transmitted m0
right m is equal to declare M hat as m0
if the received value row is greater
than a and it is essentially the same
what we saw on the last slide okay that
uh probability of this is that scale PDF
look at this right P of n row minus what
is this s given M and if this value is
greater than P of row minus S1 into P of
M1 you declare the transmit signal as m0
and where is that happening as I said it
is happening on this side of the
threshold okay right so if row is
greater than a m had becomes m not okay
so now to calculate this threshold you
should know this threshold where to like
basically declare this right if row is
greater than a you to calculate this
threshold okay and how will you
calculate this threshold both these PDFs
are equal correct okay and if you
calculate this if so what are we saying
on this threshold both these PDFs are
equal so I've said that instead of
inequality I made that equality okay and
if you solve this okay right so what
have I said okay at this value what is
row row is basically a right so what
have I done here I've taken those was
last equation okay P of it was row minus
s squ but whenever we are calculating a
threshold row is basically we are
treating that as a so row has become a
minus s not this is the PDF 1 by < tk2
pi Sigma square that gets cancelled on
both side and then we have P of m0 okay
so if you solve this there is a
threshold which we are going to get okay
right so I'm not solving this this is
one step exercise which can be done very
easily okay now you see this okay this
will immediately tell you how this map
is basically equivalent to nearest
distance rule okay just to make our life
simple what are we doing here I'm
setting P of M1 is equal to P of
m0 okay so what happens here lawn of 1
is zero so this term goes to zero
correct what will this threshold be S
not as 1 and S1 as minus one this
threshold will be
zero right okay so what are we saying
here okay choose M hat as m not if row
is greater than a if the receive signal
is greater than zero right so the
threshold becomes zero okay so what is
this if received value is positive right
you are declaring that as s not if row
value is negative you're declaring that
as S1 isn't this the minimum distance
rule okay what is this if row is greater
than Z which basically the received
signal will be close to s0 if row is
less than zero the receive signal is
close to minus one that's essentially
the minimum distance trueu okay and it
is basically coming from the map rule
okay so that's that map rule is
basically reducing to the minimum
distance rule which we looked at in our
original demodulated discussion okay and
what we did not look at at that
discussion is basically the effect of
this a Priory probabilities okay right I
could show you this minimum distance
very easily with this by taking this a
Priory probabilties same okay but
actually in this case also a Priory
probabilities are different you'll get a
different threshold but at the end of
the day that is also a minimum distance
rule with a different threshold okay
that's what we are going to see now okay
so let's see this okay so in this case
if P of M1 and m0 as what we have taken
in this Slide the minimum this threshold
comes out to be
4236 okay right and you see this the
threshold is moving
towards moving away
from s right instead of now it has
become minus
44236 okay so what are what is happening
here
that the the probability of transmitting
s not is greater than probability of
transmitting uh S1 okay so the you're
giving more region to declare S1 okay
basically as as the correct decision
okay so you look at this minus.
4236 so it is the decision region has
become here okay the threshold has moved
towards here okay so if the decision
region is basically moving towards the
negative side okay there are a more
chances of declaring the receive signal
as s not right because the decision
region is moving towards the negative
side okay correct and why is that
happening because probability of
transmitting s not is greater than
probability of transmitting
S1 okay so now what happens if
probability of m0 I mean s not and
probability of s S1 are same okay in
that case so this noise variance Still
Remains same okay see this both of them
have like equal Heights and where are
they intersecting we just did this
exercise in the last slide also they'll
intersect now at zero okay intersection
threshold is zero okay
so this is basically what students
normally do is they like uh when we give
them an question like this they
intuitively uh
calculate this threshold okay that if
you given a system like this binary
system okay it is declare a value
receive signal as like basically s not
if it is greater than zero okay
otherwise declare it as S1 but that
intuitive probability that intuitive
calculation of decision threshold is
wrong because you have not Incorporated
the a Priory probabilities okay right so
that is another takeaway but what are we
saying here when this the a Priory
probabilities are same the decision
threshold is balanced okay is balanced
between s not and S1 okay in the last
case P of S1 was greater P of s not was
greater right okay so the decision
region basically was moving towards the
left okay now both of them are same it
has come somewhere in between okay right
so what is the next case Okay so both
the probabilities are basically the same
okay now and what have I done here is I
have reduced the noise variance okay so
what happens in this case you see this
what will this noise variance do okay
noise variance is basically reducing the
width of the noise PDF okay so we have
lesser noise in the system okay right
what does this tell okay so if you
transmit this symbol okay right it will
basically that what is the probability
that it will B basically move towards
move away from zero okay what is that
probability this is that probability
right okay why because what are you
doing you're adding this you
transmitting this s0 okay and you're
adding noise to it the noise has a
lesser variance okay there's a lesser
probability that it will cross the
threshold right okay Ral to S + n okay
if the noise has lesser variance okay
that then with a lesser probability this
signal this transmit signal will move
towards will cross the threshold and
that's what you are seeing over here in
this in this
region right
or right if you sum this probability
okay this is the probability basically
wherein this s not will
will move will cross the region will
cross this decision boundary and move
towards S1 okay right and you see this
this probability is basically come down
when compared with this
case look at
this right and why is that happening
because the noise variance is higher in
this
case right okay correct what is this
probability this is basically
probability of error
okay you transmitted this s not okay
right the noise has taken it toward
cross the threshold and move it towards
the left side okay and what is the
probability of error you basically sum
this up correct and with Sigma Square
equal to 1 this is basically the
probability of error okay when Sigma
square is equal to
31 this is the probability of error you
sum this up okay so the probability of
error has reduced because the noise has
reduced
okay right so intersection threshold
Still Remains zero okay because we are
not changing the a Priory probabilities
okay but what are we showing over here
the effect of noise on how this like the
trans how it is going to affect the
transmit signal because noise has a
lesser variance which essentially means
what it receive signal has a higher SNR
right okay so and this gets reflected
like this wherein
the probability of this s not becoming
S1 is only this right and similar is the
case with S1 becoming s not this is the
probability of error for
the right
okay now you further reduce the
variance point1 you see what
happens look at this because noise is
further reduced okay you basically
like this is a
transmit Point okay you're adding this
Goan noise and but the Varian is of the
noise is low okay so what is what is it
telling okay that when you have a noise
like this what happens how will your
receive symbols look like okay this is
bpsk right the noise is is a lower
variance what will happen you'll receive
points only in this range they'll move
like
this right okay so they'll move little
because the noise variance is
low correct okay and that's what is
showing you over here okay like look at
the this is the error probability then
close to zero right so whatever you are
transmitting you'll be able to receive
that signal with the very high
probability you'll be able to correctly
decode that signal okay that's what this
this plot is telling you we only look at
the constellation plot but this is
another way of looking at it from noise
perspective when you add basically to
when you plot it with the with the
goshan PDF okay right what is Ral to S +
n n is goian and that's what we are
plotting over here right and we are
plotting them for two different values
of s okay one is+ one other one is minus
okay right intersection threshold
remains same but this is the key point
okay that the with very low probability
you are going to make an error at the
receiver okay then you further reduce it
okay right you see this intersection
threshold remains zero look at
this whatever you transmit that's what
you're going to receive even here so
you'll they'll move very little you stay
in this because look at this okay right
because the noise is reduced you're not
never going to make an error right okay
so there are a noise variance at which
communication system would like to
operate because you'll not make errors
but that's not guaranteed and that's why
we have all this ldpc codes to help you
out wherein the noise is high but you
can by sending parity bits you can
recover the correct signal okay right so
this above thresholding based receiver
as I said is called a hard decoding
because you are already declaring that
the receive signal is either + one or
minus one that's what we do right so if
it is we did it for bpsk right same idea
can be extended for qpsk also why
because qpsk is bpsk on xaxis and bpsk
on Y axis okay so if it is a qpsk symbol
you look at you do this hard
thresholding for the real part of it
then you do the hard thresholding for
the imaginary part of it
right okay so same idea can be extended
okay right so for other higher order
modulation scam we'll have to do a
little bit of more homework but the idea
Remains the Same okay right so this was
basically the hard decoding and we
basically threshold and the threshold is
we can calculate it very easily okay
right and typically this the a prior
probabilties are same okay for any
message signal they are same but you
should if they are not same you should
be able to incorporate those
probabilities in your decision okay
because they change the decision
threshold right okay so after studying
this what is left for us to understand
is the soft decision values okay so what
are what happens here is what is our map
rule again we come back to this map rule
okay and you'll quickly see that it is
the soft decision is only basically
rewriting it in a slightly different
form okay and that's what I'm going to
show you what is our map rule fine what
did we do for this hard decision
decoding we basically simplified this
okay correct and now but at the end of
the day right what is this this is
basically a probability okay right
there's also another probability this
correct okay and we compare we calculate
this probability we set it equal both of
these probabilities to be equal and then
we come up with the threshold correct
okay and we use that threshold to
declare whether the transmit bit was z+
one or minus one if we don't do that
okay right if we basically stick to
these probabilities okay right and then
feed these probabilities to the decoder
that's what is called the soft decision
rule let's see that okay so what are we
saying here so earlier we set them equal
okay right and then we basically came up
with a threshold I'm not doing that now
what are we saying I moved it over here
okay right now what is this P of R this
is this is a PDF okay right so and then
I have substituted this okay what am I
saying here okay what are
this I'm not simplifying it okay right
so what is what is coming on top what is
this this is a probability that M was
transmitted and this is the probability
that M1 was transmitted okay right I'm
not thresholding that whatever
probability I have basically calculated
I keep as I keep that probability as
such okay and calculate its ratio okay
now if I want to threshold this ratio
okay so what will happen is that will
become my hard decision rule how will
that happen if this ratio is greater
than one what will the message signal be
message signal is s if the this is less
than one the message signal will become
S1 right okay because it's rewriting the
same thing in a different form but
instead of thresholding this what am I
doing here I'll keep these probabilities
as such okay and what are this what are
this we do not threshold but calculate
the above probability okay and what is
this first of all this is the
likelihood right and this is the ratio
of of to
likelihood okay correct so what is what
can you call it as this is likelihood
ratio okay now there's an exponential
coming over here so typically you can
further simplify this by taking log of
it okay right so that ratio is called
log likelihood ratio okay and what is
that ratio log likelihood ratio it is a
ratio of two likelihoods scaled by the a
Priory probabilities
correct if let to you want to simplify
this you can set these like a prior
probabilities to same they get they'll
get cancelled okay so what is happening
here in order to understand it better
the ratio of log likelihood ratios okay
you have the likelihood you take the log
of that and then you calculate a ratio
and what is that ratio that ratio tells
us what is the probability of s not
being transmitted divided by the
probability of S1 being transmitted
method okay so if you look at it what
are we doing now we are calculating the
ratios and feeding that ratio to the
ldpc decode right so at this stage we
have not decided ourself whether the
transmit bit was 0 or 1 or plus one or
minus one okay we only calculated the
ratios okay and then you can how is it
going to help the decoder I'll give you
an example and what is that example as I
just showed you that what happen happens
at the through this awgn
channel okay right that this is what you
transmitted okay noise basically moved
it to other
side this is what is received okay
correct now if you threshold it youve
already moved it
to minus one correct okay you already
pushed it towards the minus one you have
declared it with so much of confidence
that the transmit signal was minus1 okay
so the decoder will have to do lot of
work to bring it back to plus one to
correct this error right but instead of
that if I pass on this probability right
which I'm calculating here probability
of this bit being zero or this bit being
one okay I only pass this ratio I don't
declare it correct
and with those probabilities it'll be
easier for the decoder to decide to make
it to push push it towards the to
towards the actual transmit symbol and
correct the error okay because you not
pushed it you not thresholded it you
just retained these probabilities and
these calculating the probability like
this is shown to give you 2.5 DB of gain
okay you can improve the SNR okay by a
factor of 2.5 DB okay by only making
this change okay and actually if it is
you get with this kind of improvement
okay you can it is a 3db Improvement in
SNR the uee can go twice the distance
okay with this 3db SNR improvement from
the base station okay and that
Improvement is huge okay typically what
happens is that in any receiver you
never do the hard thresholding you
always calculate these log likelihood
ratio and then feed it to the decoder
which makes the decoder life easier and
then it is able to give you that gain
okay so this brings to the end of
discussion on the demodulator aspect and
what did we learn in this lecture in the
last lecture was two things one is that
how does this actual hard decision
decoding is a result of maximizing the a
posterior probability okay and how do
you define this a posterior probability
this is the probability of a given bit
being transmitted of probability of a
bit being transmitted given that you
have received some signal okay right so
you maximize that probability and if
that lead first leads to hard decision
rule but if you don't use that if you
simplify it like this if you rewrite it
like this okay you can calculate the
ratio of the probabilities or the
likelihoods okay and those ratios if you
feed to the decoder directly then that
will give you a much better performance
then
when compared with the case when you are
thresholding and then giving feeding it
to the decoder okay so I'll stop here
thank you
[Music]
[Music]
[Music]
