Fourier expansion of dirac delta function

16 views (last 30 days)
Emre Gemici
Emre Gemici on 6 Apr 2022
Commented: Emre Gemici on 7 Apr 2022
Hi,
I am working on moving loads on beams and load is defiend by delta function as:
Sum of the series at x=v0*t must be equal to F0 for every n values. Below is my code that plots F0 and with increasing n value it also increases. I can't find what is wron with my code or isomething is wrong with the formulation?
L=10;
F0=10000;
v0=1;
t=4;
x=-10:0.1:10;
n=4;
f=0;
for i=1:n
wn=i*pi/L;
f=f+2*F0/L*sin(wn*v0*t)*sin(wn*x);
end
plot(x, f);
grid;

Accepted Answer

Paul
Paul on 6 Apr 2022
Increasing n to better approximate the infinte sum yields
L=10;
F0=10000;
v0=1;
t=4;
x=-10:0.1:10;
n=400;
f=0;
for i=1:n
wn=i*pi/L;
f=f+2*F0/L*sin(wn*v0*t)*sin(wn*x);
end
plot(x, f);
grid;
Don't know if that's what's expected.
  4 Comments
Emre Gemici
Emre Gemici on 7 Apr 2022
Ahh of course. F0 is not equal to peak value of the curve, it is equal to area under the curve between 0 and L. There is no need to restrict x or y. It is a periodic function with period of 2L (-L to L) but since our interval is 0 to L it is multiplied by 2. Thanks for helping.

Sign in to comment.

More Answers (0)

Community Treasure Hunt

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

Start Hunting!