- https://www.mathworks.com/help/comm/ref/awgnchannel.html
- https://www.mathworks.com/help/comm/ug/awgn-channel.html
Simulink AWGN block, Input signal power from variable
3 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
Hey,
I am using the "AWGN Channel" block in Simulink and I want to input the "Input signal power" from a variable from inside the simulation.
What I mean is that I have a block in the Simulink that calculates the signal power and outputs it. I want this to be the input to the "Input signal power" block.
Is there a way to do it?
0 commentaires
Réponses (1)
Sourabh
le 25 Avr 2025
Modifié(e) : Sourabh
le 25 Avr 2025
Hey @Ilya Michlin
In Simulink, the "AWGN Channel" block does not natively support dynamic input for the "Input signal power" parameter during simulation. This parameter is typically set as a fixed value in the block's parameters dialog box and cannot be connected directly to a signal line within the model.
You can follow this alternative approach to achieve dynamic noise variance based on a computed signal power:
1. In the AWGN Channel block parameters, set the "Mode" to "Variance" and “Noise variance source” to “Input port”.
2. Add a “MATLAB Function” block to compute the noise variance based on the measured signal power and desired SNR.
Double-click the block and define the function as follows:
function noiseVar = computeVariance(sigPower)
SNR_dB = 10; % Desired SNR in dB
noiseVar = sigPower / (10^(SNR_dB / 10));
end
3. Connect the output of the block that calculates the signal power to the input of MATLAB Function block.
4. Connect the output of MATLAB Function block to the input of AWGN Channel block.
For more details on “AWGN Channel”, kindly visit the following MATLAB documentation links:
I hope this helps!
0 commentaires
Voir également
Catégories
En savoir plus sur Propagation and Channel Models dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!