compute the indefinite integral
7 views (last 30 days)
Show older comments
how can I compute the indefinite integral of an anonymous function?
f=1010;
d= 0:0.0001:8;
z = @(d) sawtooth(2*pi*f*d+pi,0);
3 Comments
Accepted Answer
Torsten
on 23 Oct 2022
f = 1010;
z = @(d) sawtooth(2*pi*f*d+pi,0);
dstart = 0.0;
dend = 0.01;
delta_d = 1e-5;
d = dstart:delta_d:dend;
intz = cumtrapz(d,z(d));
hold on
yyaxis left
plot(d,z(d))
yyaxis right
plot(d,intz)
hold off
0 Comments
More Answers (0)
See Also
Categories
Find more on Calculus 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!