You are on page 1of 50

Parametric Time-domain models based on frequency-domain data

(Module 7)

Dr Tristan Perez
Centre for Complex Dynamic Systems and Control (CDSC)

Prof. Thor I Fossen


Department of Engineering Cybernetics

19/09/2007

One-day Tutorial, CAMS'07, Bol, Croatia

Time-domain modelling approaches


Two approaches can be distinguished for timedomain modelling:

Full time-domain hydrodynamic codes, Time-domain models based on frequencydomain data.

Here, we will focus on the second approach.


19/09/2007 One-day Tutorial, CAMS'07, Bol, Croatia 2

Frequency-domain Eq. of Motion


In the hydrodynamic literature it is common to find the following model:

&(t ) + B( ) & (t ) + G (t ) = (t ) [M RB + A ( )]& exc

This is not a true time-domain model (Cummins, 1962) This is valid to describe the steady-state response to sinusoidal excitationsi.e., Frequency Response:
1 ~ ~ 2 = ( [M RB + A( )] + j B( ) + G ) exc 144444424444443

~ denotes complex variable


19/09/2007

Force to Motion RAO

One-day Tutorial, CAMS'07, Bol, Croatia

Cumminss equation
Cummins (1962), took a different modelling approach and consider the radiation problem ab initio in the time domain :

The added mass matrix is constantfrequency and speed independent. The convolution term accounts for fluid-memory effects. The kernel of the convolution is a matrix of retardation functions or impulse responses. This is a true linear time-domain model.

19/09/2007

One-day Tutorial, CAMS'07, Bol, Croatia

Cumminss equation with forward speed

The convolution terms depend on the forward speed. With forward speed appears a constant damping term. The restoring forces are affected by hydrodynamic pressureLift, changes in trim. (Usually ignored for Fn<0.3)

19/09/2007

One-day Tutorial, CAMS'07, Bol, Croatia

Ogilvies relations
If Cumminss Equation is valid for any input, it must then be valid for sinusoids in particular (Ogilvie, 1964).
Ogilvie (1964) transformed the Cummins Equation to the frequency domain, and found that

A ( ) = A

K (t ) sin( t ) dt
0

B( ) = B(U ) + K (t ) cos( t ) dt
0

From the Riemann-Lesbesgue Lemma:


A = lim A ( ) := A ( )

B(U ) = lim B( ) := B()



19/09/2007 One-day Tutorial, CAMS'07, Bol, Croatia 6

Non-parametric Representations

Time-domain

K (t ) =

[B( ) B( )] cos( t ) d
0

Frequency-domain

K ( j ) = [B( ) B( )] + j [ A ( ) A ( )]

19/09/2007

One-day Tutorial, CAMS'07, Bol, Croatia

Parametric Representations
Because the convolution is a dynamic linear operation, it can be represented by a linear ordinary differential equationstate-space model:

& ( ) d r = K (t )
0

& & = A c x + B c x r = Cc x

x1 x x = 2 M xn

19/09/2007

One-day Tutorial, CAMS'07, Bol, Croatia

Parametric Representations
From the state-space representation, it follow

Impulse Response
K (t ) = Cc exp( A ct )B c

Frequency-domain model (Transfer Function matrix)


bm s m + bm 1s m 1 + L + b0 = n Qij ( s ) s + qn 1s n 1 + L + q0 Pij ( s )

P16 ( s ) P 11 ( s ) L Q ( s) Q16 ( s ) 11 K ( s ) = C c ( sI A c ) B c = M O M P61 ( s ) L P66 ( s ) Q ( s) Q66 ( s ) 61

Rational TF
9

19/09/2007

One-day Tutorial, CAMS'07, Bol, Croatia

Convolution replacement

The convolution (non-parametric model) in the Cummins equation can be time and memory consuming for simulation. For analysis and design of a control system, the convolutions are not very well suited. The parametric state-space representation of appropriate order (n-order) eliminates the above problems.

19/09/2007

One-day Tutorial, CAMS'07, Bol, Croatia

10

Convolution replacement
w
+

[M + A ( )]1

&

& ( ) d K ( t )
0

G
& ( ) d r = K (t )
0

& & = A c x + Bc x r = Cc x
11

19/09/2007

One-day Tutorial, CAMS'07, Bol, Croatia

Properties of the convolution terms


Property
lim K ( j ) = B()
0

Implication on parametric models K(s) is zero at s=0 for U=0. TFs strictly proper TFs relative degree 1 TF BIBO stable
K(s) is passive => diagonal terms are positive real; off diagonal terms stable.

lim K ( j ) = 0

K (t = 0+ ) = [B( ) B()] d 0
0

lim K (t ) = 0
t

Re{Kii ( j )} 0

Note: Bold symbols denote matrices.


19/09/2007 One-day Tutorial, CAMS'07, Bol, Croatia 12

Low-frequency limit (U=0)


K ( j ) = [B( ) B( )] + j [ A( ) A( )]
In the limit at low freq, B() is zero, since there cannot be waves (Faltinsen, 1990); thus the real part is zero for U=0 and -B() for U>0.

The imaginary part tends to zero as the following difference is finite:

Note that regularity conditions for the exchange of limit and integration are satisfied.

19/09/2007

One-day Tutorial, CAMS'07, Bol, Croatia

13

High-frequency limit (U=0)


K ( j ) = [B( ) B()] + j [ A( ) A( )]

In the limit at high frequency, the real part is zero.

The imaginary part also tends to zero by Ogilvies relation and Riemann-Lebesgue Lemma:

19/09/2007

One-day Tutorial, CAMS'07, Bol, Croatia

14

Initial and final time (U=0)

Initial time:
t 0 +

lim K (t ) = lim +
t 0

[B( ) B( )] cos( t ) d = [B( ) B( )] d 0


0 0

Regularity conditions for the exchange of limit and integration are satisfied. The last relation follows from energy considerations (Faltinsen, 1990):

Final time:
lim K (t ) = lim
t t

[B( ) B( )] cos( t ) d = 0
0

Which follows by Ogilvies relation and Riemann-Lebesgue Lemma.


19/09/2007 One-day Tutorial, CAMS'07, Bol, Croatia 15

Passivity
For U=0 and no current, the damping matrix is symmetric and positive semi-definite:

From this follows the positive realness of the convolution terms and thus the passivity; that is these terms cannot generate energy.
From energy considerations, it also follows that the diagonal terms of K(s) are passive.
19/09/2007 One-day Tutorial, CAMS'07, Bol, Croatia 16

Parametric model identification


The convolution replacement can be posed in different ways, which in theory should provide the same answer:
B( )


K ( j )

Time-domain identification

K (t )

A c Cc

B c Dc A c Cc B c Dc

Frequency-domain identification

A ( ), B( )

Model conversion

( s) K

In practice one method can be more favourable than the other.


19/09/2007 One-day Tutorial, CAMS'07, Bol, Croatia 17

Parametric model identification


Different proposals have appeared in the literature: Time-domain identification:

LS-fitting of the impulse response (Yu & Falnes, 1998) Realization theory (Kristiansen & Egeland, 2003)

Frequency-domain identification:

LS-fitting of the frequency response K(j) (Jeffreys, 1984),(Damaren 2000). LS-fitting of added mass and damping (Soding 1982), (Xia et. al 1998), (Sutulo & Guedes-Soares 2006).

19/09/2007

One-day Tutorial, CAMS'07, Bol, Croatia

18

Time-domain identification

From K(t) to state-space models.

19/09/2007

One-day Tutorial, CAMS'07, Bol, Croatia

19

Numerical computations of K(t)


A key issue for time-domain identification is to start with a good impulse response computed from the damping.

Numerical codes can only provide accurate computations of added mass and damping up to a certain frequency, say . This introduces an error in the computation of the retardation functions:
K ( t ,U ) = [B( ) B(U )] cos(t )d + [B( ) B(U )] cos(t )d
0

K ( t ,U )

[B( ) B(U )] cos(t )d


0

Error (t ,U ) =

[B( ) B(U )] cos(t )d


20

19/09/2007

One-day Tutorial, CAMS'07, Bol, Croatia

High-frequency values of A() and B()


In the limit at high frequency the following tendencies are observed for the 3D damping and added mass:
Bik ( )

ik 2

as

Aik ( ) Aik ( )

ik 2

as

As commented by Damaren (2000), this seems at odds with what is generally stated in the hydrodynamic literature! Note that there are no expansions involved to obtain these results, the only assumption is the linearity which results in a rational representation and the relative degree 1, which results from the integration of damping over the frequencies.
19/09/2007 One-day Tutorial, CAMS'07, Bol, Croatia 21

Example Containership

(Taghipour et al., 2007a)

The panel sizing was done to be able to compute frequencies up to 2.5 rad/s. Rule of thumb: characteristic panel length < 1/8 min wave length (Faltinsen, 1993).
19/09/2007 One-day Tutorial, CAMS'07, Bol, Croatia 22

Numerical computations
Extending the damping with tail prop to 1/2
6 B33 [Kg/s] 4 2 0 x 10
7

6 B35 [Kgm/s rad] B33 B33 ext w


-2

x 10

B35 4 2 0 B35 ext w


-2 -2 -4

B35 ext w +w

0 x 10
8

10 15 Freq. [rad/s]

20

0 x 10
11

10 15 Freq. [rad/s]

20

6 B53 [Kgm/s rad] 4 2 0

3 B53 ext w
2 -2 -2 -4

B55 [Kg m /s]

B53 B53 ext w +w

B55 2 1 0 B55 ext w


-2

In this example, the tail /2 is not a very good for B35 and B53 (2.5rad/s is too low), whereas it is ok for B33 and B55.

10 15 Freq. [rad/s]

20

10 15 Freq. [rad/s]

20

19/09/2007

One-day Tutorial, CAMS'07, Bol, Croatia

23

Numerical computations
Sometimes it is necessary to extend the damping with asymptotic values:
x 10
11

K (t )
3 x 10
11

B
0

ext

( ) cos(t )d
K55 K55ext

B55 B55 ext w 2


2
-2

2.5

B55 [Kg m /s]

1.5
K55

1.5

0.5

0.5
0

0 1 2 3 4 5 6 Freq. [rad/s] 7 8 9

-0.5

10 time [s]

15

20

25

When doing time-domain identification, it is important to start from a good approx of the retardation function!
19/09/2007

Note the differences at t=0+, and the errors at different time instants.

One-day Tutorial, CAMS'07, Bol, Croatia

24

Impulse response curve fitting


Given the SISO SS realization of order n:

The parameters can be obtained from

The application of this method to marine structures was proposed by Yu and Falnes (1998).
19/09/2007 One-day Tutorial, CAMS'07, Bol, Croatia 25

Impulse response curve fitting

It is hard to guess the order of the system by looking at the impulse response aloneone should start with lower order and increase it to improve the fit. The LS-problem is non-linear in the parameters. This problem can be solved with Gaussian-Newton methods. The Gaussian-Newton methods are known to work well if the parameters initial guess are close to the optimal parameters. Since the initial value of the parameters is difficult to obtain from the impulse response, and these depends on the particular realization being chosen, the method is not very practical.

19/09/2007

One-day Tutorial, CAMS'07, Bol, Croatia

26

Realization theory
A key result of realization theory is the following factorization (Ho and Kalman, 1966):

Hankel matrix of the impulse response values (constant along the anti-diagonals) Extended controllability matrix

Extended observability matrix

19/09/2007

One-day Tutorial, CAMS'07, Bol, Croatia

27

Realization theory
Kungs Algorithm (Kung, 1978):
Singular value decomposition

The number of significant singular values give the order of the system:

19/09/2007

One-day Tutorial, CAMS'07, Bol, Croatia

28

Realization theory
Kungs Algorithm (Kung, 1978):

The application of this method to marine structures was proposed by Kristiansen and Egeland (2003).
19/09/2007 One-day Tutorial, CAMS'07, Bol, Croatia 29

Realization theory

The problem is solved in discrete time Kungs algorithm obtains the model based on a SVD-factorization of the Hankel matrix of samples of the impulse response. If the impulse response is not accurate, it may in very large order systems The conversion from discrete to continuous often gives a matrix Dc in the state-space realization, which is inconsistent with the dynamics of the problem for the retardation function (relative degree 1). The MATLAB command imp2ss implements Kungs algorithm, and chooses the order by neglecting singular values less than 1% of the largest one. imp2ss requires using model order reduction afterwards (Kristiansen et al 2005). The resulting models may not be passive.

19/09/2007

One-day Tutorial, CAMS'07, Bol, Croatia

30

Example Container ship


Singular values of the Hankel matrix of the samples of the impulse response.
1 0.8 0.6 0.4 0.2 0 Normalised Singular Values Normalised Singular Values K33 K33ext 1 0.8 0.6 0.4 0.2 0 K35 K35ext

These suggest (based on the blue plots)


5 10 15 20

10

15

20

1 Normalised Singular Values Normalised Singular Values 0.8 0.6 0.4 0.2 0 K53 K53ext

1 0.8 0.6 0.4 0.2 0 K55 K55ext

Order K33(s) = 3 or 4 Oder K35(s) = 5 or 6 Order K55(s) = 3 or 4

10

15

20

10

15

20

19/09/2007

One-day Tutorial, CAMS'07, Bol, Croatia

31

Example Container ship


Impulse response fitting for K33(t) with a system of order 4. Identification method: imp2ss + balmr (model order reduction).
3.5 x 10
7

K33(t)
Data Approximation order 4

K33(jw)
155 150 |K33(jw)| dB 145 140 135 130 125 K33(jw) K33(jw) order 4 Convolution Frequency Response

2.5

2 Retardation function

1.5

120 -3 10

10

-2

10 Freq. [rad/s]

-1

10

10

200
0.5

Phase K33(jw) [deg]


0 5 10 Time [s] 15 20 25

150 100 50 0 -50 -100 -3 10


-2 -1 0 1

-0.5

-1

10

10 Freq. [rad/s]

10

10

The identified model is not passive and does not have a zero at s=0.

19/09/2007

One-day Tutorial, CAMS'07, Bol, Croatia

32

Example Container ship


Impulse response fitting for K33(t) with a system of order 3. Identification method: imp2ss + balmr (model order reduction). K33(t)
3.5 x 10
7

K33(jw)
Data Approximation order 3

155 150 |K33(jw)| dB 145 140 135 130 125

Convolution Frequency Response

2.5

2 Retardation function

K33(jw) K33(jw) order 3

1.5

120 -3 10

10

-2

10 Freq. [rad/s]

-1

10

10

100
0.5

Phase K33(jw) [deg]


0 5 10 Time [s] 15 20 25

50 0 -50

-0.5

-1

-100 -3 10

10

-2

10 Freq. [rad/s]

-1

10

10

The identified model is passive, but still does not have a zero at s=0.
19/09/2007 One-day Tutorial, CAMS'07, Bol, Croatia 33

Example Container ship


Impulse response fitting for K35(t) with a system of order 5.
10 x 10
8

K35(t)
180
Data Approximation order 5

K35(jw)
Convolution Frequency Response 170 |K35(jw)| dB 160 150 140 130 -3 10 K35(jw) K35(jw) order 5

6 Retardation function

10

-2

10 Freq. [rad/s]

-1

10

10

100 Phase K35(jw) [deg]


0 5 10 Time [s] 15 20 25 2

50 0 -50

-2

-100 -3 10

10

-2

10 Freq. [rad/s]

-1

10

10

The identified model is passive, but still does not have a zero at s=0. Note that the off-diagonal terms do not necessarily have to passive for K(s) to be passive (Unneland & Perez, 2007).
19/09/2007 One-day Tutorial, CAMS'07, Bol, Croatia 34

Comments about Realization Theory

Depending on the hydrodynamic data, it may be necessary to extend the damping at high freq. to have a good estimate the of the impulse response function before doing the idetification. Looking at the impulse response fitting alone is not a good criteriamost properties are evident from the freq. response. Imp2ss may require using model order reduction afterwards. The models almost never satisfy the low frequency asymptotic values (zero at s=0). High-order models may not be passive; this can solved trying different orders or using a model order reduction method that enforces passivity.
One-day Tutorial, CAMS'07, Bol, Croatia 35

19/09/2007

Frequency-domain Identification
From K(j) to K(s)

19/09/2007

One-day Tutorial, CAMS'07, Bol, Croatia

36

Frequency-domain identification
We can fit a SISO TF to each entry of K(j):

Pij ( s ) Kij ( s ) = Qij ( s )


Where,

Pij ( s ) has a zero at s=0 for U=0 or constant for U>0


Relative degree = 1; i.e., deg Qij ( s ) = deg Pij ( s ) + 1 Stable
One-day Tutorial, CAMS'07, Bol, Croatia

19/09/2007

37

Relative degree condition


From the finite initial time of the impulse response:
t 0 +

lim Kij (t ) = lim +


t 0

[ B ( ) B ( )] cos( t ) d = [ B ( ) B ( )] d 0
ij ij ij ij 0 0

From the Initial-value Theorem of the Laplace Transform:


bm s m +1 Kij (t ) = lim sKij ( s ) = lim lim = . n + s s t 0 Qij ( s ) s sPij ( s )

Hence for this to be finite n=m+1; relative degree = 1.


19/09/2007 One-day Tutorial, CAMS'07, Bol, Croatia 38

Minimum order transfer function


Because of the restriction of relative degree 1, the minimum order TF that can represent a convolution term is
b1s s2 + a s + a 1 0 min Kij ( s ) = b1s + b0 2 s + a1s + a0 U = 0,

U > 0,

Therefore, we can start with a system of order n=2, and then increase the order until we improve the fitting at an appropriate level.
19/09/2007 One-day Tutorial, CAMS'07, Bol, Croatia 39

Regression in the frequency domain


In this method, a rational transfer function

is fitted to the frequency response data:

The application of this method to marine structures was proposed by Jeffreys (1984) and Damaren (2000).
19/09/2007 One-day Tutorial, CAMS'07, Bol, Croatia 40

Quasi-linear regression
Levi (1959) proposed the following linearization:

This can be obtained If we chose the weights in the nonlinear problem as

which is affine in the parameters and reduces to a linear LS problem.


19/09/2007 One-day Tutorial, CAMS'07, Bol, Croatia 41

Iterative Quasi-linear regression


The quasi-linear regressor tend to have a poor fit a low freq. This can be avoided by solving the linear LS problem iteratively, starting with the quasi-linear regressor and using the parameters obtained to compute a weighing:

k = 2,3,K
After a few iterations, nonlinear problem is recovered.
19/09/2007 One-day Tutorial, CAMS'07, Bol, Croatia

and the

42

Containership example
Frequency-domain identification of K33(jw) order 3 Identification method: iterative quasi-linear regression (invfreqs.m)
160 150 |K33(jw)| 140 130 120 110 100 -3 10
-2 -1 0 1

Convolution Frequency Response

K33(jw) K33(jw) order 3

10

10 Freq. [rad/s]

10

10

The model is passive and satisfy the asymptotic values.

100 Phase K33(jw) [deg] 50 0 -50

-100 -3 10

10

-2

10 Freq. [rad/s]

-1

10

10

19/09/2007

One-day Tutorial, CAMS'07, Bol, Croatia

43

Containership example
Frequency-domain identification of K35(jw) order 5 and K55(jw) order 3 Identification method: iterative quasi-linear regression (invfreqs.m)
180 170 |K35(jw)| 160 150 140 130 120 -3 10
-2 -1 0 1

Convolution Frequency Response

230 220 |K55(jw)| 210 200 190 180


10 10 Freq. [rad/s] 10 10

Convolution Frequency Response

K35(jw) K35(jw) order 5

K55(jw) K55(jw) order 3

170 -3 10

10

-2

10 Freq. [rad/s]

-1

10

10

100 Phase K35(jw) [deg] 50 0 -50

100 Phase K55(jw) [deg]


-2 -1 0 1

50 0 -50

-100 -3 10

10

10 Freq. [rad/s]

10

10

-100 -3 10

10

-2

10 Freq. [rad/s]

-1

10

10

19/09/2007

One-day Tutorial, CAMS'07, Bol, Croatia

44

Reconstructing B()
6 B33 [Kg/s] 4 2 0 x 10
7

B33 6 B33 FD ident, order 3 B35 [Kg/s] 4 2 0

x 10

B35 B35 FD ident, order 5

0 x 10
8

2 4 Freq. [rad/s]

0 x 10
11

2 4 Freq. [rad/s]

6 B53 [Kg/s] 4 2 0

B55 [Kg/s]

3 B53 B53 FD ident, order 5 2 1 0 -1

B55 B55 FD ident, order 3

2 4 Freq. [rad/s]

2 4 Freq. [rad/s]

19/09/2007

One-day Tutorial, CAMS'07, Bol, Croatia

45

Reconstructing A()
2.6 2.4 2.2 2 A35 [Kgm] A33 [Kg] 1.8 1.6 1.4 1.2 1 0.8 0.6 0 0.5 1 1.5 2 2.5 3 Freq. [rad/s] 3.5 4 4.5 5 x 10
8

3 A33 A33 FD ident, order 3 A33inf 2.8 2.6 2.4 2.2 2 1.8 1.6 1.4 1.2 1

x 10

A35 A35 FD ident, order 5 A35inf

0.5

1.5

2.5 3 Freq. [rad/s]

3.5

4.5

3 2.8 2.6 2.4 A53 [Kgm] 2.2 2 1.8 1.6 1.4 1.2 1

x 10

9 A53 A53 TD ident, order 5 A53inf A55 [Kg m ]


2

x 10

11

8 7 6 5 4 3

A55 A55 TD ident, order 3 A55inf

0.5

1.5

2.5 3 Freq. [rad/s]

3.5

4.5

0.5

1.5

2.5 3 Freq. [rad/s]

3.5

4.5

19/09/2007

One-day Tutorial, CAMS'07, Bol, Croatia

46

Comments about Freq.-dom. regression

FD-identification avoids having to compute the impulse response from the damping The identification method is simplest: a series of linear LS problemseasy to programme. The zero at s=0 and the relative degree can be enforced in the structure of the model, so the asymptotic values are always ensured. The resulting models may be unstable: this is fixed by reflecting the unstable poles about the imaginary axis. The resulting models may not be passive: this can be solved using weights in the LS problem.
One-day Tutorial, CAMS'07, Bol, Croatia 47

19/09/2007

Simulink Model implementation


After obtaining a state-space representation or the transfers functions, we can assemble a complete model:

19/09/2007

One-day Tutorial, CAMS'07, Bol, Croatia

48

References

Perez, T. and T. I. Fossen (2006) Time-domain Models of Marine Surface Vessels Based on Seakeeping Computations. 7th IFAC Conference on Manoeuvring and Control of Marine Vessels MCMC, Portugal, September. Perez, T. (2007) Identification and Validation of a Time-domain Hydrodynamic Model of a Prototype Hull for a Wave Energy Converter (WEC). Technical Report. Centre for Complex Dynamic Systems and Control. Australia. Cummins, W., 1962. The impulse response function and ship motions. Schiffstechnik 9 (1661), 101109. Ogilvie, T., 1964. Recent progress towards the understanding and prediction of ship motions. In: 6th Symposium on Naval Hydrodynamics. Kristiansen, E., Egeland, O., 2003. Frequency-dependent added mass in models for controller design for wave motion damping. In: Proceedings of 6th Conference on Maneoeuvering and Control ofMarine Craft, Girona, Spain.

19/09/2007

One-day Tutorial, CAMS'07, Bol, Croatia

49

References

Damaren, C.J. (2000). Time-domain floating body dynamics by rational approximations of the radiation impedance and diffraction mapping. Ocean Engineering 27, 687705. Yu, Z., Falnes, J., 1998. State-space modelling of dynamic systems in ocean engineering. Journal of Hydrodynamics B(1), 117. Sutulo, S., Guedes-Soares, C., 2005. An implementation of the method of auxiliary state variables for solving seakeeping problems. International shipbuilding progress (Int. shipbuild. prog.) 52, 357384. Taghipour, R., Perez, T., Moan, T., 2007a. Hybrid Frequency-Time Domain Models for Dynamic Response Analysis of Marine Structures. (To appear in Ocean Engieering) Taghipour, R., Perez, T., Moan, T., 2007b. Time domain hydroelastic analysis of a flexible marine structure using state-space models. In: 26th International Conference on Offshore Mechanics and Arctic Engineering-OMAE 07, San Diego, CA, USA.

19/09/2007

One-day Tutorial, CAMS'07, Bol, Croatia

50

You might also like