Why can't the orthogonal PN codes help in the near-far effect?

the orthogonal PN sequences used in CDMA be able to handle this?

Orthogonal PN sequences could.

In reality, you don't get these – frequency and timing offsets, and trade-offs during the design phase mean that you only get approximately orthogonal sequences.

So, even if the cross-correlation between what TX1 and TX2 transmits is say -50 dB, but TX2 is 53 dB stronger at the receiver than TX1, then TX1's energy after correlation with the matching PN sequence is still only half of that of TX2's interference.


Well, the clue is in the last sentence. The receiver has to reliably detect the number of received signals (e.g. 1's in the code sequence), since they add up on the receiver end.

If there are two handsets, one with a received signal strength of say, 10 (disregarding exact units) and another one with a strength of 1, then we have total incoming signal strenghts of 0, 1, 10 and 11 (again, over-simplifying). That's pretty difficult to separate for a receiver as 4 different levels. Now if the ratio is 100:1, which is not unlikely with radios, the levels are 0, 1, 100 and 101; impossible to separate.

When the units are more or less equal in power, we get values 0, 1 and 2 (no, not 3). Much easier to separate and detect.


CDMA is very unique in comparison with other multiplexing schemes because it doesn't (even in the ideal case) completely remove interference from other users. In an ideal time based (i.e TDMA) or an ideal frequency based (i.e FDMA) you can effectively remove all interference from other users, whilst in a CDMA scheme all you are doing is effectively scaling down other users' interference by a factor of \$N\$, where \$N\$ is the length of the spreading codes.

So if you have a two users \$a\$ and \$b\$ both transmitting to a common receiver using a common power level of \$P\$ but the power levels being received are \$P_a\$ and \$P_b\$ respectively (because one is near and the other is far away) then in an ideal FDMA system and transmitting over unit channel gain then you would have the normal SNR formula of

$$ SNR_a = \frac{P_a}{P_N} $$

for user \$a\$ and a formula of

$$ SNR_b = \frac{P_b}{P_N} $$

for user \$b\$. \$P_N\$ is the noise power. So it's basically a pure multiplexing scheme and so provided the two SNR values above are above your receiver's sensitivity then you should be able to decode them just fine. In an ideal CDMA scheme however the interference from other users is not removed but instead just scaled back by a factor of \$N\$ so the SNR for user \$a\$ would be

$$ SNR_a = \frac{P_a}{\frac{P_b}{N} + P_N} $$

and for user \$b\$ it's

$$ SNR_b = \frac{P_b}{\frac{P_a}{N} + P_N} $$

Now, if your orthogonal spreading sequence length \$N\$ is long enough this isn't an issue as this SNR will effectively be the same as in the first case. If on the other hand \$N\$ is not very long and you have one device near and the other one far then you will have \$P_a >> P_b\$ if user \$b\$ is far away. This can then cause \$SNR_b\$ to fall below the receive sensitivity of the receiver and make it hard for you to receive packets from \$b\$. You can mitigate this near far problem to a great extent by using long perfectly orthogonal PN sequences. In a lot of cases though PN sequences that are not perfectly orthogonal are used, the interference from other users is then reduced by a factor slightly lower than the PN sequence length. This exacerbates the "near far" problem.