matlab-add-awgn

Add AWGN to MATLAB signals with explicit power and convertSNR conversions.

883|109|Updated Apr 3, 2026
One-click install
npx skills add https://github.com/matlab/matlab-agentic-toolkit --skill matlab-add-awgn
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: matlab-add-awgn
Source: https://github.com/matlab/matlab-agentic-toolkit/tree/main/skills-catalog/wireless-communications/matlab-add-awgn
Command: npx skills add https://github.com/matlab/matlab-agentic-toolkit --skill matlab-add-awgn

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

Prevents incorrect noise levels and SNR/Eb-N0 mix-ups when adding Additive White Gaussian Noise (AWGN) in MATLAB communications simulations, especially for OFDM and coded systems.

Core Features & Use Cases

  • Correct AWGN calling conventions: Enforces explicit signal power to awgn (never the 'measured' option) and supports both unit-power and non-normalized signals.
  • Reliable SNR/Eb/No conversions: Uses convertSNR for all conversions and clarifies wideband SNR vs per-subcarrier SNR workflows in OFDM.
  • Soft-demod noise variance: Recommends capturing [y, nVar] = awgn(...) and passing nVar into soft demodulation via NoiseVariance=nVar.
  • Use Case: Add AWGN after a Rayleigh fading channel and compute soft-decision BER/LLRs with the correct noise scaling instead of silently using mismatched SNR definitions.

Quick Start

Ask the skill to add AWGN to your signal at a specified SNR (or Eb/No) and provide the correct MATLAB code using explicit power and the appropriate convertSNR path for your modulation and OFDM parameters.

Frequently Asked Questions about matlab-add-awgn

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I add AWGN to a MATLAB signal at a specific SNR without using the 'measured' option?

To add AWGN correctly in MATLAB, call the awgn function using explicit signal power rather than the 'measured' option. This avoids scaling anti-patterns and ensures the noise level matches your intended SNR definition for both unit-power and non-normalized signals.

Why does my MATLAB OFDM simulation have incorrect noise levels when converting SNR?

OFDM simulation noise levels are often incorrect due to wideband SNR and per-subcarrier SNR mix-ups. Use the convertSNR function for all SNR conversions, applying the two-step OFDM workflow to accurately translate between definitions before adding noise.

How do I pass the correct noise variance to a soft-decision demodulator in MATLAB?

To pass correct noise variance to a soft-decision demodulator, capture the output nVar from the awgn function and pass it directly into the demodulation function using the NoiseVariance parameter for accurate LLR computation.

What parameters do I need to convert Eb/No to SNR for coded systems in MATLAB?

Converting Eb/No to SNR for coded systems in MATLAB requires providing BitsPerSymbol, CodingRate, and SamplesPerSymbol to the convertSNR function. This ensures the conversion accounts for modulation and coding overhead accurately.

Can I use the awgn function after a Rayleigh fading channel in MATLAB?

You can add AWGN after a Rayleigh fading channel by providing the explicit signal power to the awgn function. This maintains correct noise scaling for computing soft-decision BER and LLRs without mismatched SNR definitions.