Professional Documents
Culture Documents
2
2
Introduction
In Chapter 2 we obtained the response of a SDOF as the direct solution of the differential
equation of motion. This approach is undoubtedly the most efficient when an explicit expression
giving the particular solution can be obtained. For many cases in practice, however, the loading or
the system properties are such that an explicit particular solution cannot be obtained and one has
to resort to numerical techniques. In deriving numerical techniques there are two fundamentally
different starting points.
The first approach is very attractive because the issues of numerical instability that can plague
numerical evaluations are avoided altogether. Unfortunately, however, implicit closed-form
solutions are not available for all situations and one has to resort to numerical integration
techniques that start with the equations (not the solution). This chapter derives closed-form
solutions for the response of a LTI system to arbitrary (non-parametric) excitations and examines
the issues involved with their numerical evaluation. For simplicity the initial examination is
presented for a SDOF system. Extension to the multi-degree-of-freedom (MDOF) systems is
done in subsequent chapters. Examination of numerical integration techniques derived directly
from the equations of motion is presented in Chapter 4.
∫ δ (t − a) dt = 1
−∞
(2)
It follows, therefore, that the instantaneous value of a function can be expressed in integral form
as;
∞
U (a ) = ∫ U(τ) δ (τ − a )dτ (3)
−∞
A graphical representation of the Dirac Delta function is depicted in the figure.
ε ∞
dt 0
ε
dt
21
Consider now a SDOF system subjected to a load given by Dirac Delta function (also referred to
as the unit impulse or just an impulse).
.. .
m U + c U + kU = δ ( t ) (4)
h(t)
τ
t
Say you wish to find the response at time t due to only the impulse indicated in the sketch.
Assuming the system is linear and time invariant we can write;
Since the total response at time t comes from the effect of all the impulses applied before time t
(the load is assumed to be right sided) we can obtain U(t) by integrating eq.6 from 0 to t, namely;
t
U ( t ) = ∫ P(τ )h(t − τ )dτ (7)
0
22
which is a general expression for the response for any applied load P(t). The integral in eq.7 is
known as the convolution integral and in the structural dynamics literature is often referred to as
the Duhamel’s integral. If there are non-zero initial conditions the associated free vibration
solution must be added to eq.7.
t
d
U (t ) = ∫ P (τ )h(t − τ )dτ (7a)
dt 0
and
t
d2
U(t ) = 2 ∫ P(τ )h(t − τ )dτ (7b)
dt 0
Leibnitz rule for differentiating inside a definite integral states that if;
b (t )
I (t ) = ∫ f (t ,τ )dτ (7c)
a (t )
then
b (t )
d d d
I ′(t ) = ∫ dt
f (t ,τ )dτ + b(t ) ⋅ f (t , b(t )) − a (t ) ⋅ f (t , a (t ))
dt dt
(7d)
a (t )
t t
= P(τ)h ( t − τ)dτ + P( t ) h (0) = P(τ)h ( t − τ)dτ
U (t) ∫ ∫ (7e)
0 0
and
t
U(t ) = ∫ P(τ )h(t − τ )dτ + P(t )h(0) (7f)
0
which, as expected, shows that accelerations have the ability to react instantaneously to the load.
It is interesting to note that one can flip the shift in the convolution of eq.7 with no effect on the
result, namely
t
U ( t ) = ∫ P( t − τ)h (τ)dτ (7g)
0
the validity of which can be easily shown mathematically by a change of variable as well as from
the “physical argument” that was used in connection with the figure that appears after eq.5. Using
eq.7g and Leibnitz rule one then finds that
23
t
= P ( t − τ) h (τ)dτ + P(0)h ( t )
U (t) ∫ (7h)
0
and
t
(t − τ )h(τ )dτ + P (0) h(t ) + P (0)h(t )
U(t ) = ∫ P (7i)
0
If an impulse is applied to a SDOF system (with a non-zero mass) the system acquires an initial
velocity. Because the duration of the loading is infinitesimally small the displacement that takes
place during the loading approaches zero so the resistance to motion is offered entirely by the
mass. Taking the impulse to be the Dirac delta function (unit impulse) and using the impulse-
momentum principle one concludes that the system attains an initial velocity of 1/m.
From eqs.20-22 of chapter 2 the response to an initial velocity of 1/m is given by;
h(t ) =
1
m( s 2 − s1 )
(
e s2t − e s1t ) (8)
where s1 and s2 are given by eq. 26 in chapter 2. The familiar form for the impulse response can
be obtained from eq.8 by substituting the expressions for the roots into eq.8 and using Euler’s
identity, after a few simple manipulations one gets;
1
h(t ) = e −ω ξ t sin(ω D t ) (9)
mωD
Example #1 – Obtain an expression for the response of a SDOF system subjected to a step load of
magnitude P.
Solution: The response is given by eq.7 with P(τ) = P. Using the form in eq.8 for the impulse
response we get;
t
P
U (t ) = ∫
m( s 2 − s1 ) 0
e s2 ( t −τ ) − e s1 ( t −τ ) dτ (10)
t
P ⎡ e s2 ν e s1 ν ⎤
U (t ) = ⎢ − ⎥ (11)
m( s 2 − s1 ) ⎣ s 2 s1 ⎦ 0
or;
U (t ) =
P
m( s 2 − s1 ) s1 s 2
[
s1e s2 t − s 2 e s1 t − s1 + s 2 ] (12)
24
The reduction of eq.12 to a form in terms of real parameters is left as an exercise.
n
U (n) = ∑ P ( j ) h(n + 1 − j ) dt (13)
j =1
The formula in eq.13 assumes rectangles of width dt centered at each of the ordinates and thus
neglects edge effects. Although it is possible to write a simple correction for the edge this is
typically unnecessary. It’s opportune to note that MATLAB’s convolution command uses eq.13
(with dt = 1).
where L ∈ Rm x r and P(t) ∈ Rr x 1. We close by emphasizing that once the impulse response is
known the computation of response is reduced to the evaluation of a convolution integral.
Mathematical Preliminaries
In the previous section we found that the response of a linear system can be computed in the time
domain by means of the convolution integral.
t
U(t) = ∫ h(t − τ ) P(τ )dτ
0
(14)
25
A disadvantage in the convolution approach is that the numerical cost of the operation is high. As
shall be shown in the development that follow, by transferring eq.14 to the frequency domain the
convolution is rendered a multiplication and significant savings in the numerical effort can result.
A basic review of Fourier analysis is presented next.
Fourier Transform
The Fourier Transform (FT) of a function f(t) is defined as;
∞
F(ω) = ∫ f ( t )e −i ω t dt = A(ω) e i φ ( ω) (16)
−∞
the FT is generally a complex function of the real variable ω. It is illustrative to write it as;
∞
R= ∫ f (t ) cos(ω t )dt
−∞
(18)
and
∞
Ι= ∫ f ( t ) sin(ω t )dt
−∞
(19)
Note that if f(t) is real R(ω) = R(-ω) and I(ω) = - I(-ω). In other words, for real functions the real
part of the Fourier transform is an even function and the imaginary part is odd. It should be noted
that not all functions have Fourier Transforms, in fact for F(ω) to exist it is necessary that;
−∞
∫ f (t ) dt <∞ (20)
f2(t) → F2(ω)
then
2) Time Shifting
(i ( φ ( ω) -ω t o ) )
f(t-t 0 ) → F(ω) exp(-iω t 0 ) = A(ω) e
26
The linearity of the Fourier Transform is evident by inspection of its definition. Proof of the time
shifting property is presented next.
By definition we have;
∞
F(ω) = ∫ f(t )e −i ω t dt
−∞
and
∞
F (ω) = ∫ f(t - t 0 )e −i ω t dt
*
−∞
defining
v = t - t0
one has
t = v + t0
and
dv = dt
therefore
∫ f(v)e
− iω ( v + t 0 )
F (ω ) =
*
dv
−∞
or
∞
F * (ω ) = e −iω t0 ∫ f(v)e
− iω v
dv
−∞
F * (ω ) = e − iω t0 F (ω )
∞
1
∫ F (ω ) e
iω t
f (t ) = dω (21)
2π −∞
Deduction of the inversion formula (eq.21) is not presented here but can be found in many
standard texts (see for example “The Fourier Integral and its Applications” by A.Papoulis).
27
Integral Expression for the Dirac Delta Function
There are several expressions for the Dirac delta function that prove useful in different
circumstances. The one shown below is presented because it will find use later on in our
considerations. This formula can be seen to result directly from the definition of the Dirac delta
function and the inverse formula of eq.21.
∞
1
∫e
iω t
δ(t) = dω (22)
2π −∞
if
U(t) = P(t)*h(t)
then
Proof:
t
U(t) = ∫ P(τ )h(t − τ )dτ
0
(23)
The first step in the derivation is to change the limits of the integration to minus and plus infinity.
It is a simple matter to confirm that this change does not affect the result provided both P(t) and
h(t) are causal functions (zero for negative time). Therefore, assuming causality one can write;
∞
U(t) = ∫ P(τ )h(t − τ )dτ
−∞
(24)
∞ ∞
⎡ ∞ P(τ )h(t − τ )dτ ⎤e − wt dt
∫ U (t )e dt = ∫ ⎢⎣∫−∞
− wt
U(ω) = (25)
⎥⎦
−∞ −∞
28
⎡∞
∞
⎤
∫ ⎢⎢ ∫ P(τ)h(t − τ)e dt ⎥⎥dτ
−i ω t
U(ω) = (26)
−∞ ⎣ −∞ ⎦
or
∞
⎡∞ ⎤
∫−∞ ⎢⎣∞∫ h(t − τ)e dt ⎥⎦dτ
−i ω t
U(ω) = P (τ ) (27)
defining
v=t-τ (28)
one gets;
∞
⎡∞ ⎤
U (ω ) = ∫ P (τ ) ⎢ ∫ h(v)e −i ω ( v −τ ) dv⎥ dτ (29)
−∞ ⎣∞ ⎦
or
∞
⎡∞ ⎤ -i ω τ
∫−∞ ⎢⎣∞∫ h(v)e dv⎥⎦e dτ
−i ω v
U (ω ) = P (τ ) (30)
The term inside the brackets is simply the Fourier transform of h(t), we designate this function as
h(ω) and write;
∫ P(τ ) h(ω ) e
− iωτ
U (ω ) = dτ (31)
−∞
taking h(ω) out of the integral sign we see that what is left is the Fourier transform of the load
P(t) so we conclude that
Efficiency
It is evident that one can avoid the direct convolution by taking the Fourier transforms of the
functions that are to be convolved multiplying them and then taking the inverse Fourier transform
of the result. The question that comes to mind, of course, is why do that? One reason is that
maybe the number of operations can be reduced so that a computer algorithm will operate faster.
As it turns out this is in fact true in many cases when one uses the Fast Fourier Transform (FFT)
algorithm introduced in the 1960’s.
29
While we will not discuss the Fast Fourier Transform algorithm here it is important to recognize
that the approach does not provide the transform of the function given but rather of a periodic
version of the function. When one works with the FFT the periodicity must be kept in mind to
ensure that it doesn’t distort the solution. We will get back to this issue later in the chapter.
∫ f(t)e
−i ω t
F(ω) = dt
−∞
we can express the result in a different and very useful way integrating by parts as follows;
f(t) = u → f ′ (t) dt = du
and
e − iω t
e −iω t dt = dv → v =
− iω
therefore,
∞ ∞ ∞
f(t)e -iω t ⎤ f ′(t)e − iω t
∫ f(t)e ∫ iω dt
−i ω t
dt = ⎥ + (33)
−∞
- iω ⎦ −∞ −∞
we note that due to the causality of f(t) and the periodic nature of the complex exponential the
first term in eq.33 vanishes. Taking this into consideration and multiplying by iω one gets;
∫ f ′(t ) e
−i ω t
iω F ( w) = dt (34)
−∞
but the term in the integral is the Fourier Transform of the derivative of the function so we
conclude that the Fourier transform of the derivative is simply iω times the Fourier Transform of
the function, namely;
⎛d ⎞
F⎜ f (t ) ⎟ = iω F(ω) (35)
⎝ dt ⎠
30
⎛ dn ⎞
F ⎜⎜ n
f ( t ) ⎟⎟ = (iω)nF(ω) (36)
⎝ dt ⎠
m u + c u + k u = P(t)
taking the Fourier transform of both sides and taking advantage of the differentiation property we
get;
P (iw)
u(iω) = (37)
− w m + k + cwi
2
Eq.37 gives, therefore, the Fourier Transform of the response and we can obtain the response in
the time domain by using the inversion formula.
1
h(ω)= (38)
− w m + k + cwi
2
∞
1 1
∫ mω
−∞ D
e −ξ ωD t sin(ω D t) e −iω t dt =
( − w m + k ) + cwi
2
(39)
Another way to arrive at the result in eq.38 is by considering the response of the SDOF system to
a Dirac delta function and taking the Fourier Transform. Indeed, by definition we have;
m h( t ) + c h ( t ) + k h ( t ) = δ( t )
31
Taking a Fourier Transform and recognizing that
∫ δ(t)e
−iwt
F(δ(t)) = dt = 1
−∞
we get;
1
h(iω ) =
[(-ω m + k ) + cωi ]
2
Application of the procedure given previously involves taking the Fourier Transform of the load
histories and taking the inverse Fourier transform of the results in eq.37. In practice neither one of
these operations can be usually carried out in closed-form so one must resort to numerical
techniques for a solution. There are two important issues associated with the periodicity of the
complex exponential that must be understood to be able to carry out numerical evaluations
appropriately.
Consider first the numerical evaluation of the Fourier Transform. Using the same technique used
to convert the convolution into a sum we get;
N
F (ω ) = ∑ f ( j ) e −iω ( j −1) ∆t ) ∆t (40)
j =1
where t = (j-1) ∆t and tmax = (N-1) ∆t. Note that the function in eq.40 will repeat when the values
of the exponential give the same results at the locations where f(t) is sampled. To determine when
this will happen we write;
where ω ~ is a frequency that will have the same Fourier transform than that at ω and k is an
~ one gets;
arbitrary positive or negative integer. Solving for ω
2π ⎛ k ⎞
ω~ = ω + ⎜⎜ ⎟⎟ (42)
∆t ⎝ ( j − 1) ⎠
Careful examination shows that the solution that has the smallest feasible repetition is that when
the parenthesis in eq.42 is taken as unity. We conclude, therefore, that once the time step is
selected the maximum frequency in the transform is 2π/∆t. Although any interval with a range of
2π/∆t can be used, in practice it is customary to operate with a symmetric interval so the
32
maximum frequency that can be computed before the repetition takes over is π/∆t. This
frequency is called the Nyquist frequency, in honor of Henry Nyquist an American engineer that
contributed significantly to the analysis of signals.
We conclude that in selecting the time step we must be careful so that the Nyquist frequency is
large enough to include all of the important part of the true transform. If we take a time step that
is not small enough then the numerically computed transform will not be accurate because the
higher frequencies will affect the computed results – this effect is known as aliasing.
The next question is how to select the discretization of the frequency when taking the inverse
Fourier Transform. The analysis follows a line of reasoning similar to the one used previously.
Specifically, the numerical formula for the inverse transform can be written as;
1 N
U (t ) =
2π
∑ F ( ∆ω j ) e
j =− N
i ( ∆ω j ) t
∆ω (43)
here we conclude that the results will repeat as long as the periodic exponential gives the same
result at every one of the sampled values of the Fourier Transform. To find where this will
happen we write;
i[∆ω j t + 2π k ] = i ∆ω j ~
t (44)
~ 2π ⎛ k ⎞
t =t+ ⎜ ⎟ (45)
∆ω ⎜⎝ j ⎟⎠
with a similar reasoning as with eq.42 one concludes that the response will repeat every 2π/∆ω so
the frequency sampling must be small enough so that this periodic effect in unimportant.
% **********
% OFT.M
% **********
% Routine to clarify some issues associated with the use of the FFT algorithm in Freq. Domain
% Analysis.
% ************************************
% The program considers the time function
% and can be used to examine how the exact transform and the FFT compare or to test how the
% IFFT of the true transform compares with the real function.
a=1;
dur=4;
dt=0.01;
t=0:dt:dur;
y=exp(-a*t);
33
wmax=pi/dt;
dw=2*pi/dur;
% The exact transform is
% yiw=a-i*w/(a^2+w^2);
% Compare the exact transform with the FFT
y1=fft(y*dt);
y1m=fftshift(y1);
ome=-wmax:dw:wmax;
yiw=(a-ome*i)./(a^2+ome.^2);
plot(ome,real(y1m),ome,real(yiw),'g');
pause
% Now we use the exact transform and go back to time.
om1=0:dw:wmax;
om2=-wmax:dw:-dw;
om=[om1 om2];
yiw=(a-om*i)./(a^2+om.^2);
yt=real(ifft(yiw)/dt);
plot(t,yt,t,y,'g');
% Note that when you take the FFT of a time function you must multiply by dt.
% Note that when you take the IFFT of a frequency function the result must be divided by dt.
% Note that in the IFFT of this function there is "vibration" around the origin. This is a result of
% Gibbs phenomenon, which appears when the function y(t) is discontinuous. Note that our
% function is discontinuous at the origin.
% The FFT of a time function will be near the real transform if:
% The FFT of a discrete time function gives coefficients of a periodic expansion of the function.
% The IFFT of a frequency function is periodic with period T=2*pi/dw, the first cycle will be
% close to the real time function if the part of the function beyond the truncation is negligible.
34
1 1
0.8 0.8
0.6 0.6
0.4 0.4
0.2 0.2
0 0
0 1 2 3 4 -400 -200 0 200 400
(a) (b)
1.2
0.4 1
0.2 0.8
0.6
0
0.4
-0.2 0.2
0
-0.4
-0.2
-400 -200 0 200 400 0 1 2 3 4
(c) (d)
(a) Time function; (b) Comparison of real parts of FFT and Fourier Transform; (c) Comparison of
imaginary parts of FFT and Fourier Transform; (d) Comparison of IFFT and the function itself.
Observations:
In the case shown here the true transform and the FFT are very close because the true Fourier
Transform is negligible for frequencies > ωNyquist.
The IFFT gives a very good approximation of the function because dω is small enough and
ωNyquist is large enough.
You can use the program provided to test what happens when you change the parameters.
35