21.4.2 Continuous Fourier Transform
The Fourier transform of a function f is defined by
F(ω)= | ∫ | | e−i ω t f(t) dt
=F | ⎧
⎨
⎩ | f(t) | ⎫
⎬
⎭ | (ω),
|
where ω∈ℝ. The fourier
command computes the Fourier transform by table lookup and application of transform properties.
-
fourier takes one mandatory argument and several optional
arguments:
-
expr, an expression which defines a function
f(t)=expr.
- Optionally, t, the variable for f (by default
t).
- Optionally, ω, the variable for the Fourier
transform (by default omega).
- Optionally, a sequence of arguments in form opt=bool, where
bool is a boolean value and opt is one of the following:
-
int or integrate or Int or Integrate,
for specifying whether symbolic integration should be attempted for unknown
transform pairs (by default, this is disabled).
- diff or derive, for specifying whether to attempt transforming
the derivatives of unknown transform pairs (by default, this is disabled).
- fourier(expr ⟨,t,ω ⟩) returns
the Fourier transform F(ω) of f(t).
The inverse Fourier transform, as its name implies, takes a Fourier
transform F(ω) and returns the original function f(t). It is
given by:
f(t)= | | | ∫ | | ei ω t F(ω)
dω=F−1 | ⎧
⎨
⎩ | F(ω) | ⎫
⎬
⎭ | (t)=
| | F | ⎧
⎨
⎩ | F(ω) | ⎫
⎬
⎭ | (−t).
|
The ifourier
command computes the inverse Fourier transform by using the above identity.
-
ifourier takes one mandatory argument and several optional
arguments:
-
expr, an expression which defines a function
F(ω)=expr.
- Optionally, ω, the variable for F (by default
omega).
- Optionally, t, the variable for the original
function f (by default t).
- Optionally, a sequence of arguments in form opt=bool, where
bool is a boolean value and opt is one of the following:
-
int or integrate or Int or Integrate,
for specifying whether symbolic integration should be attempted for unknown
transform pairs (by default, this is disabled).
- diff or derive, for specifying whether to attempt finding
unknown transform pairs by transforming the derivative of the original
(by default, this is disabled).
- ifourier(expr ⟨,ω,t ⟩) returns
the inverse Fourier transform f(t) of F(ω).
The Fourier command is the inert form of
fourier. It is used by fourier and ifourier when
returning unknown transforms.
Transforming rational functions.
An arbitrary rational function can be transformed as long as
its full partial fraction decomposition can be found.
Examples
Find the Fourier transform of f(t)=t/t3−19 t+30.
F:=fourier(t/(t^3-19t+30)) |
|
| π | ⎛
⎝ | 5 i e5 i ω−21 i e−3 i ω+16 i e−2 i ω | ⎞
⎠ | sign | ⎛
⎝ | ω | ⎞
⎠ |
|
|
56 |
|
| | | | | | | | | | |
|
Indeed:
Find the transform of f(t)=t2+1/t2−1.
F:=fourier((t^2+1)/(t^2-1)) |
|
2 π | ⎛
⎝ | δ | ⎛
⎝ | ω | ⎞
⎠ | −sign | ⎛
⎝ | ω | ⎞
⎠ | sinω | ⎞
⎠ |
| | | | | | | | | | |
|
Indeed:
Find the transform of f(t)=2/1+4t4.
|
π | ⎛
⎜
⎜
⎝ | sin | ⎛
⎜
⎜
⎝ | | ⎞
⎟
⎟
⎠ | +cos | ⎛
⎜
⎜
⎝ | | ⎞
⎟
⎟
⎠ | ⎞
⎟
⎟
⎠ | e | |
| | | | | | | | | | |
|
Indeed:
As a special case, you can transform all poylnomials. For example:
|
2 π | ⎛
⎝ | δ | ⎛
⎝ | s | ⎞
⎠ | +2 i δ | ⎛
⎝ | s,1 | ⎞
⎠ | −3 δ | ⎛
⎝ | s,2 | ⎞
⎠ | ⎞
⎠ |
| | | | | | | | | | |
|
Transforming general functions.
A range of other (generalized) functions and distributions can be
transformed, as demonstrated in the following examples.
Examples
fourier(Dirac(x-1)+Dirac(x+1),x) |
fourier(exp(-2*abs(x-1)),x,s) |
fourier(BesselJ(3,x),x,s) |
|
− | s | ⎛
⎝ | 4 s2−3 | ⎞
⎠ | ⎛
⎝ | −i sign | ⎛
⎝ | s+1 | ⎞
⎠ | +i sign | ⎛
⎝ | s−1 | ⎞
⎠ | ⎞
⎠ |
|
|
|
|
| | | | | | | | | | |
|
F:=fourier(sin(x)*sign(x),x,s) |
F:=fourier(abs(2t-3)^(-3/4)) |
|
| Γ | ⎛
⎜
⎜
⎝ | | ⎞
⎟
⎟
⎠ | | | | ⎛
⎜
⎝ | ⎪
⎪ | ω | ⎪
⎪ | | ⎞
⎟
⎠ | | e | |
|
|
|
|
| | | | | | | | | | |
|
fourier(exp(-abs(x))*sinc(x),x,s) |
|
arctan | ⎛
⎝ | s+1 | ⎞
⎠ | −arctan | ⎛
⎝ | s−1 | ⎞
⎠ |
| | | | | | | | | | |
|
fourier(1/sqrt(abs(x)),x,s) |
F:=fourier(1/cosh(2x),x,s) |
F:=fourier(Gamma(1+i*x/3),x,s) |
|
π ugamma | ⎛
⎝ | 0,4 | ⎪
⎪ | s | ⎪
⎪ | ⎞
⎠ |
| | | | | | | | | | |
|
assume(a>0):;
fourier(exp(-a*x^2+b),x,s) |
Piecewise functions can be transformed if defined as
piecewise(t<a1,f1,x<a2,f2,…,t<an,fn,f0)
where f0,…,fn are expressions
and a1,a2,…,an are real numbers such that
a1<a2<⋯<an . Inequalities may be strict or non-strict.
For example:
f:=piecewise(t<-1,exp(t+1),t<1,1,exp(2-2t)):;
F:=fourier(f) |
|
| −i ω sinω+3 ω cosω+4 sinω |
|
|
|
| | | | | | | | | | |
|
|
θ | ⎛
⎝ | −t+1 | ⎞
⎠ | −θ | ⎛
⎝ | −t−1 | ⎞
⎠ | +θ | ⎛
⎝ | t−1 | ⎞
⎠ | e−2 t+2+θ | ⎛
⎝ | −t−1 | ⎞
⎠ | et+1
|
| | | | | | | | | | |
|
You can verify that the above expression coincides with f(t) by plotting
them together with the plot command. Alternatively, you can apply piecewise
to the result (see Section 5.1.3):
|
| ⎧
⎪
⎪
⎨
⎪
⎪
⎩ | et+1, | t<−1 |
1, | t<1 |
| otherwise |
|
|
| | | | | | | | | | |
|
Convolution Theorem and applications.
The Fourier transform behaves nicely when applied to convolutions.
Recall that the convolution f∗ g (see Section 21.2.5)
of two functions f and g is defined by
(f∗ g)(t)= | ∫ | | f(u) g(t−u) du.
|
The Convolution Theorem states that F(f∗ g)=F(f)·F(g).
As an example, we use this result for computing the
convolution of f(t)=e−|t| with itself. Note that
Xcas is unable to compute f∗ f from the definition:
f(t):=exp(-abs(t)):;
int(f(u)*f(t-u),u=-inf..inf) |
Using Fourier transform:
The above result is the desired convolution
(f∗ f)(t)=∫−∞+∞f(u) f(t−u) du.