sine wave measure differ
function y = generate_sine()
persistent t
Ts = 0.0001;
if isempty(t)
t = 0;
end
y = sin(377 * t);
t = t + Ts;
This is sine wave generator of 60 Hz.
when the scope set up is below, that isnt 60 Hz.
but same code, that is same function block and measure with sine wave block of 60 Hz , then measure 60 Hz
why?function y = generate_sine()
persistent t
Ts = 0.0001;
if isempty(t)
t = 0;
end
y = sin(377 * t);
t = t + Ts;
This is sine wave generator of 60 Hz.
when the scope set up is below, that isnt 60 Hz.
but same code, that is same function block and measure with sine wave block of 60 Hz , then measure 60 Hz
why? function y = generate_sine()
persistent t
Ts = 0.0001;
if isempty(t)
t = 0;
end
y = sin(377 * t);
t = t + Ts;
This is sine wave generator of 60 Hz.
when the scope set up is below, that isnt 60 Hz.
but same code, that is same function block and measure with sine wave block of 60 Hz , then measure 60 Hz
why? sine, simulink MATLAB Answers — New Questions