The Math Forum

Search All of the Math Forum:

Views expressed in these public forums are not endorsed by NCTM or The Math Forum.

Math Forum » Discussions » Software » comp.soft-sys.matlab

Topic: Dirac Delta Question
Replies: 11   Last Post: Mar 1, 2013 1:43 AM

Advanced Search

Back to Topic List Back to Topic List Jump to Tree View Jump to Tree View   Messages: [ Previous | Next ]
Tony Kittler

Posts: 109
Registered: 2/5/11
Re: Dirac Delta Question
Posted: Feb 6, 2013 8:44 AM
  Click to see the message monospaced in plain text Plain Text   Click to reply to this topic Reply


I have a question about Dirac delta (not as in a matlab function, my question is related to its theory)

Assume that you have a vector v. If the value of v is equal to zero then the result of the dirac delta of v is zero (so, it does not matter it is a vector or scalar) If the value of v is not zero then what is the result of the dirac delta function of the vector v? Is the result a vector or scalar value ?

"Roger Stafford" wrote in message <kda1pg$p98$>...
> "Sam " <> wrote in message <kd9r7h$38b$>...
> > Hey y'all, I'm very confused as to how to numerically incorporate dirac delta behaviour into my differential equation. Maybe I'm using a wrong approach? I keep getting error messages to no avail. Any advice would be greatly appreciated!
> >
> > function dirac
> > close all
> > clc; clear
> >
> > %Parameters:
> > G=1.07;
> > w=2*pi;
> > w0=(1.5)*w;
> > B=(w0)/4;
> >
> > % Initial Conditions
> > y0 = [0,0];
> >
> > % Make a theta vs. time plot
> > [t,y] = ode23(@f,[0 25],y0,[],G,w,w0,B);
> >
> > hold all
> > plot(t,y(:,1))
> >
> > function dydt = f(t,y,G,w,w0,B)
> > dydt = [y(2);-2*B*y(2)-(w0^2)*sin(y(1))+G*(w0^2)*cos(w*t)+dirac(t-5)];

> - - - - - - - - - - -
> You cannot actually do numerical computation using the dirac delta function directly. It is only numerically meaningful in its integrated form as a unit step function. That is, its integral from 0 to 0 is understood to be 1. That of course is impossible for ordinary numerical integration to accomplish. For that reason you have to treat it in special ways such as with the method Bruno has suggested. Some of the symbolic tools are also able to handle it properly but never, never try to compute numerically with it directly.
> Roger Stafford

Point your RSS reader here for a feed of the latest messages in this topic.

[Privacy Policy] [Terms of Use]

© The Math Forum at NCTM 1994-2017. All Rights Reserved.