# Tag Info

21

You can realize a discrete Hilbert transform by convolving your discrete signal with a Hilbert kernel. The convolution is implemented with least effort in the frequency domain, where the spectrum of the Hilbert kernel is $$\sigma_H(\omega)=-i\cdot\mathrm{sgn}(\omega)$$ where $\omega$ is the angular frequency. Continuous case We define a function to perform ...

20

You can use a trick to prevent Mathematica from taking your expression apart: LaplaceTransform[Abs[1 - Cos[t]]/t, t, s] (* 1/2 Log[1 + 1/s^2] *)

19

Here's a direct implementation of the formula $$\mathcal H(u)(t) = \frac1{\pi} -\hspace{-1.1em}\int_{-\infty}^\infty \frac{u(\tau)}{t-\tau}\, \mathrm d\tau$$ hilbertTransform[f_, u_, t_] := FullSimplify[Convolve[f, 1/u, u, t, PrincipalValue -> True]/π] Try it out: hilbertTransform[#, v, w] & /@ {Sin[v], Cos[v], 1/(1 + v^2), Sinc[v], ...

13

Finally I found the most promising algorithm proposed in this really good reference Manuel Guizar-Sicairos and Julio C. Gutiérrez-Vega, "Computation of quasi-discrete Hankel transforms of integer order for propagating optical wave fields," J. Opt. Soc. Am. A 21, 53-58 (2004). The authors call the algorithm pth-order quasi-discrete Hankel Transform (pQDHT) ...

11

This is not an answer, but a hint how to possibly proceed. It is a pity to pass on some nice Wolfram Language abilities. Let me know if I should remove it. Idea is: I think YOU should be the first to derive this integral - if it is possible. Consider only rational numbers. If this integral behaves smoothly - which it obviously does: ...

11

When Mathematica tries to pull the fraction apart, it gets $$\mathcal{L}_t\left[\frac{1-\cos(t)}{t}\right](s)=\mathcal{L}_t\left[\frac{1}{t}\right](s) - \mathcal{L}_t\left[\frac{\cos(t)}{t}\right](s)$$ While the cosine term has a Laplace-transform, $1/t$ doesn't have a transform. That might be the reason why Mathematica cannot solve it. The problem is, ...

11

Here is my attempt at an answer - I had to make up an example, and obviously much of what follows is dependent on details of this example. Edit However, what I believe this example shows quite clearly is that a finite set of tabulated data at discrete points does not suffice to guarantee a good inverse Laplace transform, because the analytic structure of ...

9

InverseLaplaceTransform[(2 s^2 + s + 13)/((s - 1) ((s + 1)^2 + 4)), s, t] 2*E^t + (3/4)IE^((-1 - 2*I)t) (-1 + E^(4*I*t)) % // ComplexExpand // Simplify 2*E^t - (3*Cos[t]*Sin[t])/E^t % // TrigReduce ((1/2)*(4*E^(2*t) - 3*Sin[2*t]))/E^t In "one" step InverseLaplaceTransform[(2 s^2 + s + 13)/((s - 1) ((s + 1)^2 + 4)), s, t] // ...

8

For continuous signal, I think is easy, took this in a course. For discrete, hard for me, we did not study it at school (yet). But if the signal is continuous, this gives the Hilbert transform of the signal: f[t_] := Sin[t]; g = FourierTransform[f[t], t, omega]; InverseFourierTransform[I* Sign[omega]*g, omega, t] ==> -Cos[t] P.S. I just saw a ...

8

Ok, I think I know why the integral worked, but not the Laplace transform. When using the integral, there is a pole at t=0 but this is a removable singularity. Series[1 - Cos[t], {t, 0, 6}] // Normal Now dividing by t (#/t) & /@ r So, the t in the denominator is gone. I do not know how Mathematica actually removed this pole at t=0 in the code, ...

8

Clear["Global`*"] eq = (2*S0/(y*sigma^2))^nu*(Gamma[nu + (2*mu)/sigma^2]/ Gamma[2*nu + (2*mu)/sigma^2])*Hypergeometric1F1[nu, 2*nu + (2*mu)/sigma^2, -2*S0/(y*sigma^2)]; int = Integrate[eq, {y, K, Infinity}, GenerateConditions -> False] int2 = int /. nu -> (-vu/2 + Sqrt[vu^2 + 8*alpha/sigma^2]/2) /.vu -> (2*mu/sigma^2 - 1) mu = 15/100; sigma = ...

8

The following is not particularly fast and could be more accurate but does make progress toward the goals set in the Question. To begin, consider the analytical properties of f, as defined in the Question. By observation, it has branch points at {I Sqrt[6/5] ξ, I Sqrt[2/5] ξ} and their conjugates. Poles are obtained by p /. ...

7

If you don't want to resort to tricks, you can differentiate the transform over s first, which would bring -t downstairs and cancel 1/t. You can then take the transform for: LaplaceTransform[(1 - Cos[t]), t, s] (* 1/s - s/(1 + s^2) *) and then integrate this over s (with a negative sign, since differentiation produced an extra -1): -Integrate[1/s - s/(1 ...

7

I was asked to explain how I arrived at the statement of my comment, regarding the first step of the complete solution. Here it is: The y-integral is of the form u0 := c Integrate[y^-a Hypergeometric1F1[p, q, -b/y], {y, k, \[Infinity]}] where a, b, c, p, q, and k are parameters independent of y. Letting y = b/z, dy = - b/z^2 dz u0 becomes u1 := c1 ...

6

Here is a series-expansion way of doing your integral. Expand the integrand as Sum[(-1)^n Sin[θ/2]^(n β), {n, 0, ∞}] (* 1/(1+Sin[θ/2]^β) *) Integrate each term in the sum using Integrate[Sin[θ/2]^(n β), {θ, 0, π}] (* ConditionalExpression[(Sqrt[π] Gamma[1/2 (1 + n β)])/Gamma[1 + (n β)/2], Re[n β] > -1] *) Fold it all together to obtain ...

6

just different forms: hilbertTransformV1[f_, u_, t_] :=Module[{fp = FourierParameters -> {1, -1}, x}, FullSimplify@InverseFourierTransform[-I (2 HeavisideTheta[x] -1) FourierTransform[f, u, x, fp], x, t, fp]]; hilbertTransformV2[f_, u_, t_] := FullSimplify[Convolve[f, 1/u, u, t, PrincipalValue -> True]/Pi] Looking at the 1/(1 + ...

6

The easiest work-around I can think of is to write a "shell" for the current FourierTransform: ft[(h : List | Plus | Equal)[a__], t_, w_] := ft[#, t, w] & /@ h[a] ft[a_ b_, t_, w_] /; FreeQ[b, t] := b ft[a, t, w] ft[a_, t_, w_] := FourierTransform[a, t, w] ft[{a f[t] + b g'[t] == 0, c f'[t] + d e g[t] h[t] == 0}, t, w] {a FourierTransform[f[t], t, ...

6

Mathematica's FourierTransform can be a bit difficult at times, so I'll let someone else address whether your code can be tweaked to work, and instead show how to do it symbolically. Defining $$f(\mathbf{r})=\exp\left(-|W\mathbf{r}|\right)$$ where $$W=\left( \begin{array}{ccc} \sqrt{w_x} & 0 & 0 \\ 0 & \sqrt{w_y} & 0 \\ 0 & 0 & ... 6 This is due to the sum of two very large numbers (coming from CosIntegral and SinhIntegral) being carried out without sufficient machine precision used to represent them. You can fix it giving an appropriate value of WorkingPrecision as an option to plot. You can see quite clearly that the problem comes from this by plotting the two functions (the one ... 6 This is decidedly not a general answer, but let's play a bit. If we do expr = Integrate[Exp[s t] c/s , {s, a - b I, a + b I} , Assumptions -> {a > 0, b > a, c ∈ Reals, t ∈ Reals}]/(2*π*I) this yields ConditionalExpression[ -((I c (-ExpIntegralEi[(a - I b) t] + ExpIntegralEi[(a + I b) t]))/(2 π)) , t >= 0] We of course need to choose a ... 6 I think one possible issue is that e.g. a+Infinity*I becomes just DirectedInfinity[I] because the "finite" part gets swallowed. You can rewrite in such a way that this does not happen. Integrate[ Exp[(s*I + a)*t]*(1/(s*I + a)), {s, - Infinity, Infinity}, Assumptions -> Element[{a, t}, Reals]] (* Out[246]= ConditionalExpression[ E^(a t) (\[Pi] ... 6 The issue here is that the replacement rule LHS evaluates: LaplaceTransform[u_, z, s] -> l[u] (* Out[1402]= u_/s -> l[u] *) To address this one can just prevent this with HoldPattern LaplaceTransform[u2[z], z, s] /. HoldPattern[LaplaceTransform[u_, z, s]] -> l[u] (* Out[1401]= l[u2[z]] *) 5 There are several issues here with the way you are proceeding: FIRST, if X is a random variable with pdf f(x), then the moment generating function (mgf) is defined as:$$E[e^{t X}] = \int_{-\infty }^{\infty } e^{t x} f(x) \, dx where the expectation is carried out over the full domain of support, which for a Normal distributed random variable ... is ...

5

I have two suggestions. You may: Establish a function that contains the integration $g(s)$. The bad news is that you may need a lot of time to evaluate the integration. In my opinion, in the inverse Laplace calculation, we don't have to give the analytical expression of $F(S)$. If I were you, I may write the function like: F[s_]:=(g = ...

5

Adding assumptions finds two of the cases. Assuming[{a, t, r, z} ∈ Reals && t > z, Integrate[ DiracDelta[ t - a - (r^2 + (z - a)^2)^(1/2)]/(4 Pi (r^2 + (z - a)^2)^(1/2)), {a, -Infinity, Infinity}] ] (* 1/(4 π t - 4 π z) *) Assuming[{a, t, r, z} ∈ Reals && t < z, Integrate[ DiracDelta[ t - a - (r^2 + (z - ...

5

One of the nicest things about Mathematica is that one can often just implement the definitions as they are: bilateralZTransform[c_, k_, z_, opts___] := Sum[c/z^k, {k, -∞, ∞}, opts] Otherwise, one can exploit the relationship between GeneratingFunction[] and ZTransform[]: bilateralZTransform[c_, k_, z_, opts___] := ...

5

When parameters to a integral are integers, I often fall back to calculating the "general" result, make a table where the parameter is explicitly given integer values, and then feed to FindSequenceFunction. In this case: table = Table[h[x, a, e] - g[x, a, e], {a, 1, 11}]; limits = Limit[#, e -> 0] & /@ table; f = FindSequenceFunction[limits]; ...

5

Direct Integration Possible issues in performing the integrations include choice of Assumptions, branch cuts in the integrands, and how limits are taken. Addressing the first of these gives five solutions. il[f_, s_, t_] := Module[{r}, 1/(2 π I) Integrate[f Exp[s t], {s, r - I ∞, r + I ∞}, Assumptions -> r > 2 && t > 0]] ...

4

Another quick way is to use the following trig identity In[13]:= TrigFactor[(1-Cos[2x])] Out[13]= 2 Sin[x]^2 If t==2*x, then we have the integrand becomes: LaplaceTransform[2 Sin[x]^2/x, x, 2*s] (* 1/2 Log[1+1/s^2] *)

4

This works in V9.0.1: Assuming[0 < a < b, Integrate[ArcCos[x/Sqrt[(a + b) x - a b]], {x, a, b}, GenerateConditions -> False]] // Timing (* {3.835651, ((a - b)^2 π)/(4 (a + b))} *)

Only top voted, non community-wiki answers of a minimum length are eligible