0
$\begingroup$

I am trying to integrate a step function given in a book, but it doesn't work.

Phi[x_]:= Piecewise[{{-Hg x, -g/2 <= x <= g/2}, {-g Hg/2, x >= g/2}, {g Hg/2, x < -g/2}}]

I can plot it and give the same result as in book but the integration is not the same so my integration code is:

Integrate[y1/ \[Pi] \[CapitalPhi][x]/((x1-x)^2+y1^2), {x, -Infinity, Infinity}, Assumptions -> x1 > 0 && y1 > 0](*here y1=y in book*)

In book it only says for y>0, so I assume x>0 also because for just y>0 mathematica doesn't integrate. My code screenshot and books page with result is attached. Thanks for your help

enter image description here

enter image description here

$\endgroup$
  • 3
    $\begingroup$ Why not take the expression you have derived, take the expression that's in the book and see if they are equal? You can for instance, plot the two of them and see if they lie on top of each other. $\endgroup$ – bill s Feb 23 '18 at 1:55
  • $\begingroup$ fyi, it looks like a class mate of your just posted the same problem at http://community.wolfram.com/groups/-/m/t/1290148 and someone has answer there, so you might to check that. $\endgroup$ – Nasser Feb 23 '18 at 2:47

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.