Group Abstract Group Abstract

Message Boards Message Boards

1
|
6.1K Views
|
6 Replies
|
2 Total Likes
View groups...
Share
Share this post:

Integrate sum of dirac delta and a piecewise defined continuous function?

Posted 8 years ago
POSTED BY: Mike Luntz
6 Replies
Posted 8 years ago

Thanks for the update Daniel.

POSTED BY: Mike Luntz
Posted 8 years ago

I don't know if this helps in isolating the problem, but here is another oddity related to the bug.

f[t_] = Piecewise[{{Exp[-t], 0 <= t < 1}}]
x=Range[5]
Integrate[f[t] + f[t - 2], {t, -1, 4}]
(* results in 2(-1+e)/e *)
Integrate[DiracDelta[t] + f[t] + f[t - 2], {t, -1, 4}]
(* results in (-1+e)/e *)
Integrate[Sum[x[[k]] f[t - 2 k], {k, 1, 5}], {t, -1, 20}]
(* results in 15(-1+e)/e *)
Integrate[DiracDelta[t] +Sum[x[[k]] f[t - 2 k], {k, 1, 5}], {t, -1, 20}]
(* results in (-1+e)/e *)

I tried the weighted sum of functions since in the notebook that I first encountered the problem, adding the delta function to the weighted sum resulted in not even being able to calculate the integral. In the example above Mathematica computed the integral; it just got the wrong result.

POSTED BY: Mike Luntz
POSTED BY: Daniel Lichtblau
Posted 8 years ago

Thanks for confirming that it is a bug Daniel. If that is not a known bug, can you report it to whomever should be told about it or should I submit a bug report?

POSTED BY: Mike Luntz

Not to worry, I'll report it.

POSTED BY: Daniel Lichtblau

A bug. Explicitly splitting the sum will show this.

g[t_] = Piecewise[{{Exp[-t], 0 <= t < 1}}];
Integrate[DiracDelta[t] + g[t], {t, -1, 2}]

(* Out[278]= (-1 + E)/E *)

Integrate[DiracDelta[t], {t, -1, 2}] + Integrate[g[t], {t, -1, 2}]

(* Out[279]= 1 + (-1 + E)/E *)

My guess, which at some point I will try to check, is that the integration range gets split due to the Piecewise, and the fact that the delta has its payload at a boundary point causes trouble.

POSTED BY: Daniel Lichtblau
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard