any idea why i'm getting this error?
Ältere Kommentare anzeigen
why i'm getting Subscript indices must either be real positive integers or logicals.
m = zeros(4,500);
n_trig = 3;
n = (0:Harm).';
f0 = 1/T;
fs = samples / T;
n = (0:n_trig).';
wnt = 2*pi*f0*n*t;
ft = exp((2 - t) / 4);
s1 = (1/T) * sum(ft) / fs;
s2 = (2/T) * ft * cos(2*pi*f0*n*t).' / fs;
s3 = (2/T) * ft * cos(2*pi*f0*n*t).' / fs;
s = s1 + s2*cos(wnt) + s3*sin(wnt);
for n = 0:3
m(n,:) = s(n);
end
thanks
1 Kommentar
Rena Berman
am 5 Apr. 2018
(Answers Dev) Restored edit
Akzeptierte Antwort
Weitere Antworten (0)
Kategorien
Mehr zu Simulation, Tuning, and Visualization finden Sie in Hilfe-Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!