All problems
MRC Combined SNR
Problem
Return the combined output signal-to-noise ratio of maximal-ratio combining with unit signal power:
SNR = sum(g_i^2 / n_i)
where g_i are the channel gains and n_i the branch noise variances.
Hint
MRC adds the branch SNRs, so diversity grows the effective SNR.
Test cases
case 1
in: [[1,1],[1,1]]
expected: 2
case 2
in: [[1,2],[1,1]]
expected: 5
case 3
in: [[1,1],[2,2]]
expected: 1
case 4
in: [[2,2],[4,4]]
expected: 2
Starter codePython
def mrc_snr(gains, noise_vars):
# Your code here
pass4 test cases · run your code against them in the editor