Tag Info

New answers tagged

5

You can gain insight by evaluating and then simplifying the indefinite integrals. Integrate[(1 + b x + c y)/(1 + e x + f y + I η), y, x, Assumptions -> {x ∈ Reals, y ∈ Reals, b ∈ Reals, c ∈ Reals, e ∈ Reals,f ∈ Reals, η ∈ Reals, η != 0}]; ans = Collect[%, {ArcTan[η/(1 + e x + f y)], Log[1 + e^2 x^2 + 2 f y + f^2 y^2 + 2 e (x + f x y) + η^2]}, ...


5

One way to approach this is to look for the source of the problem. In this case, the outer integral (on y) is irrelevant to the problem, because even the simpler integral int = Integrate[(1 + b x)/(1 + e x + I η), {x, -1/2, 1/2}, Assumptions -> {b ∈ Reals, c ∈ Reals, e ∈ Reals, η ∈ Reals, η != 0}] gives a conditional expression. But now the answer ...


4

The following approach transforms ans1 to ans2 and points the way to more general approaches. As noted in the Question, Simplify returns ans1 unchanged. Introducing a ComplexityFunction that defines fewer symbols as less complex helps some. cf[e_] := LeafCount[e] + 100 Count[e, _Symbol, Infinity] Simplify[ans1, ComplexityFunction -> cf] (* ...


2

Maybe you can use the following two constructs to your advantage, which will keep the Conjugate, but evaluate and simplify the derivative inside. Using ReleaseHold, you can then evaluate even the Conjugate. Note that I left out the divisor in the Conjugate-case for clarity, but you can easily add that into the second function's definition. d[g_] := ...


2

You can split up the interval of integration: Integrate[DiracDelta[1 - x] DiracDelta[x] f[x], {x, 0, 1/2, 1}] (* 0 *) Still, it seems a bit inconvenient.


1

Indeed, the integral should give zero even with finite bounds. This workaround seems to give the desired result: Limit[ Integrate[ DiracDelta[1 - x] DiracDelta[x] f[x], {x, ϵ, 1}], ϵ -> 0] (* ==> 0 *) But it works only because it effectively cuts off the lower bound and thus the lower delta function.


1

With v10.0.2 it appears to work only for infinite bounds or using NIntegrate $Version "10.0 for Mac OS X x86 (64-bit) (December 4, 2014)" Integrate[DiracDelta[1 - x] DiracDelta[x] f[x], {x, -Infinity, Infinity}] 0 Integrate[DiracDelta[x, 1 - x] f[x], {x, -Infinity, Infinity}] 0 NIntegrate[DiracDelta[1 - x] DiracDelta[x] f[x], {x, 0, ...


3

Via TransformationFunctions: Clear[xf]; xf[e_] := e /. {Integrate[int_, {x_, a_, b_}] - Integrate[int_, {x_, a_, c_}] :> Integrate[int, {x, c, b}], coeff_ Integrate[int_, {x_, a_, b_}] :> Integrate[coeff int, {x, a, b}]}; sol = DSolve[{f'[t] + f[t]*g[t] == h[t], f[0] == f0}, {f[t]}, t]; Simplify[sol, ...


4

Mathematica evidently won't simplify Integrate[f[t], {t, a, b}] + Integrate[f[t], {t, b, c}] to Integrate[f[t], {t, a, c}] on its own. However, you can easily write a function that does what you want, by using Mathematica's ability to have functions do pattern matching on their arguments. Here's a function that will do what we want: ...


1

Easiest and straightforward may be to define a unit conversion function like so: uc[expr_, targetunit___]:=UnitConvert[#,targetunit]&/@expr/.UnitConvert[a_,b___]->a Usage: uc[x Quantity[y, ("Milliwatts"*"Seconds"^2)/"Joules"]] (* x (Quantity[y/1000, "Seconds"]) *) or giving a desired target unit: uc[x Quantity[y, ...


2

Update In a comment Oleksandr pointed out that the number of iterations may be having an effect. This is evident from running the following code: max = 10; qp = Table[Unique[{q, p}], {max}]; qpFlat = Flatten[qp]; eqn = totalenergy[qp, max]; ceqn = Compile[Evaluate[{#, _Real} & /@ qpFlat], Evaluate[eqn], "RuntimeOptions" -> ...


1

First of all correcting the sign in the exponential we get f2 = Integrate[ Exp[r^2/(2 M^2)] (b^2 - 3 r^2)^2 (Abs[b^2 + r^2] - (b^2 - r^2))/( r (r^2 - b^2)), {r, 0, I \[Infinity]}, Assumptions -> {M > 0, b > 0] (* Out[278]= 18 b^2 M^2 + 4 b^4 E^(b^2/(2 M^2)) ExpIntegralEi[-(b^2/(2 M^2))] *) Taking the pricipal value has no influence as ...



Top 50 recent answers are included