Amplitude Modulation Synthesis function in matlab?
3 views (last 30 days)
Show older comments
For Amplitude Modulation, it suppose to have carrier amplitude and modulated amplitude.
however, the matlab built in function which is ammod, i cannot find which is carrier amplitude.
y = ammod(x,Fc,Fs,ini_phase)
Thanks!
0 Comments
Answers (1)
AR
on 27 Feb 2025
As per my understanding, for “y = ammod(x, Fc, Fs, ini_phase)”, the carrier amplitude is implicitly set to 1. The same can be seen in the example below:
% Parameters
Fs = 1000; % Sampling frequency
Fc = 100; % Carrier frequency
ini_phase = 0; % Initial phase
t = (0:1/Fs:1)'; % Time vector
% Message signal (constant)
x = ones(size(t));
% Modulate the signal
y = ammod(x, Fc, Fs, ini_phase);
% Plot the modulated signal
figure;
plot(t, y);
title('AM Modulated Signal');
xlabel('Time (s)');
ylabel('Amplitude');
grid on;
% Calculate the peak amplitude
peak_amplitude = max(abs(y));
disp(['Peak amplitude of the modulated signal: ', num2str(peak_amplitude)]);
If the need is to explicitly control the carrier amplitude, use the extended syntax that includes the carrier amplitude parameter -
y = ammod(x, Fc, Fs, ini_phase, carramp)
Refer the below link for the same:
Hope this helps!
0 Comments
See Also
Categories
Find more on Modulation in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!