Error: Too many functions when plotting series
显示 更早的评论
x=[0:pi/100:2*pi];
figure;
syms k;
syms f(x);
S1 = symsum((1/k)*sin(k*x),k,1,Inf);
S2 = symsum((1/(2*k-1))*sin((2*k-1)*x),k,1,Inf);
fplot(x,S1,x,S2);
xlabel('x')
ylabel('y')
I get this error when I'm trying to plot two series, what did I do wrong?
And how to properly apply the domain from 0 to 2pi ?
采纳的回答
更多回答(1 个)
Rik
2022-12-4
I suspect this will do what you want:
fplot(x,S1);
hold on
fplot(x,S2)
hold off
类别
在 帮助中心 和 File Exchange 中查找有关 Assumptions 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!