Why i am getting error in the 2nd input line

t=0:0.001:1;
fm = input('input modulating signal frequency = ');
Unable to run the 'fevalJSON' function because it calls the 'input' function, which is not supported for this product offering.
fc = input('input carrier signal frequency = ');
Am = input('input amplitude of modulating signal = ');
Ac = input('input amplitude of carrier signal = ');
Ms = Am *cos(2*pi*fm*t);
subplot(3,1,1)
plot(Ms)
title('Modulating Signal');
Cs = Ac *cos(2*pi*fc*t);
subplot(3,1,2)
plot(Cs)
title('Carrrier Signal');
AMs = Ms.*Cs;
subplot(3,1,3)
plot(AMs)
title('Modulated Signal');

2 Comments

What input you have given?
no input function or directory created just created a new script named lab1

Sign in to comment.

Answers (1)

It looks there is some function in your working directory on the name input. What does
which input
show up?
Rename the function input, if you have it in the directory.

Asked:

on 28 Feb 2022

Commented:

on 28 Feb 2022

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!