Modelling and Control of a Machine Tool Using Co-Simulation

SIMPACK User Meeting Eisenach, 2004 Modelling and Control of a Machine Tool Using Co-Simulation Alexandra Ratering Peter Eberhard Institute B of Mec...
Author: Daniel Burke
0 downloads 1 Views 1MB Size
SIMPACK User Meeting Eisenach, 2004

Modelling and Control of a Machine Tool Using Co-Simulation Alexandra Ratering Peter Eberhard

Institute B of Mechanics Prof. Dr.-Ing. Peter Eberhard University of Stuttgart

Outline ™ introduction ™ the Lambda Kinematic ™ modelling • mechanical and mathematical model • equations of motion

™ flatness • introduction to the concept of flatness • flatness analysis of the machine tool

™ controller design • linear cascaded P-PI control • flatness based control

™ simulation • simulation environment • comparison of control concepts

™ conclusions Institute B of Mechanics Prof. Dr.-Ing. Peter Eberhard University of Stuttgart

demand for highly productive machine tools

Introduction

(high velocities, large scale movements, …)

development of • new machine types (parallel and hybrid kinematics) • new technologies (linear drives, lightweight structures, …)

problem • assumption of independently controllable drives questionable • elastic properties become important • nonlinearities become important

solution hierarchical controllers combining position control with methods of active vibration damping Institute B of Mechanics Prof. Dr.-Ing. Peter Eberhard University of Stuttgart

the Lambda Kinematic

Machine Tool

• processing of plate-like workpieces (esp. wood processing) • scissors-like kinematic for movement in xy-plane • movement along z-axis realized by a serial axle • high dynamics: support velocities up to 2 m/s, max. acceleration 9 m/s2 • implemented motion control system: two independent P-PI controllers for each drive built at the Institute of Machine Tools (IfW) at the University of Stuttgart

Institute B of Mechanics Prof. Dr.-Ing. Peter Eberhard University of Stuttgart

problems with • overall performance • vibrations during processing F 1st step: development of a better position controller

Animation of Motion

Institute B of Mechanics Prof. Dr.-Ing. Peter Eberhard University of Stuttgart

y

Mechanical Model A

TCP

C

multibody system model R P

• 4 rigid bodies P, H, R, A

β γA

γR

• 2 degrees of freedom

x H

• 1 kinematic loop: DAE system • minimal coordinates q m = [xP xH ]

• joint coordinates q t = [xP xH γ R γ A ]

procedure • cut kinematic loop at joint C • Newton-Euler equations for each branch of open tree structure • algebraic constraint as loop closing condition Institute B of Mechanics Prof. Dr.-Ing. Peter Eberhard University of Stuttgart

Newton-Euler equations for the open tree structure

Equations of Motion

generalized gyroscopic generalized Boolean and centrifugal forces applied forces matrix mass matrix

motor forces

&&t + k (q t , q& t ) = Q a (q t , q& t , t ) + H ⋅ u + Q r M (q t ) ⋅ q

generalized constraint/ reaction forces

Qr = GT ⋅ λ implicit constraint equations

 x p − xH + l R cos(γ R ) + l A cos(γ A ) g(q t ) =  =0   y P − y H + l R sin (γ R ) − l A sin (γ A ) 

g& ≡

∂g ⋅ q& t = G (q t ) ⋅ q& t = 0 ∂q t

equations of motion in minimal coordinates explicit constraint equations qt = qt (q m ) can be calculated analytically

Institute B of Mechanics Prof. Dr.-Ing. Peter Eberhard University of Stuttgart

i = R, A γ i = γ i (q m ),  ⇒ γ&i = γ&i (q m , q& m ), γ&& = γ&& (q , q& , q  i i m m && m ), but resulting ODE-formulation is complicated and for flatnessbased controller not necessary!

Flatness

definition

x& = f (x, u ),

x(0 ) = x 0 ∈ ℜ n , u ∈ ℜ m

is (differentially) flat, if there exists

(

)

y = Φ x, u, u& ,K, u (α ) , dim(y ) = dim(u )

( ) u = Ψ (y , y& ,K, y β )

for which (locally) x = Ψ1 y , y& ,K, y ( β )

( +1)

2

y is called a flat output of the system

in other words: all states and inputs of a system can be calculated as an algebraic function of the flat output and a final number of its derivatives

open loop control

yd

inverse system

ud

machine tool

! y = yd

… sufficient for ideal system Institute B of Mechanics Prof. Dr.-Ing. Peter Eberhard University of Stuttgart

input: u = [u1 u 2 ]

Flatness Analysis

states: x = [q m q& m ] = [xP x& P xH x& H ] flat output: y = q m = [xP xH ]

x& = f (x, u )  x = Ψ1 (y , y& )  ⇔ y = [xP xH ] u = Ψ 2 (y , y& , &y& )

γ R , γ A , γ&R , γ& A , γ&&R , γ&&A

… auxiliary variables

y1

d/dt

y&1

d/dt

y& 2

d/dt

system is flat, hence controllable and observable singularities: • 2 possible positions • not reachable due to construction

Institute B of Mechanics Prof. Dr.-Ing. Peter Eberhard University of Stuttgart

&y&1

x2 , x4 γ&R , γ& A

x1 , x3 γ R, γ A y2

d/dt

u1 , u2 γ&&R , γ&&A &y&2

Linear Controller • preliminary: implemented P-PI controller (for a single support, i = P, H) 1/s xid + -

Kv

+

-

Kp/Tn Kp

Fz + +

Kf

ui

support i

num. diff.

- equivalent to an incomplete PID controller - tuned experimentally - equal Kp,Kv and Tn values for both supports - system performance varies over the workspace

Institute B of Mechanics Prof. Dr.-Ing. Peter Eberhard University of Stuttgart

xi

Flat Controller Design with Feedback Linearization

• static state feedback

u = u(y , y& , v )

¾ linear system with new input v = &y& = q && m

• PD controller, PID controller

(

)

(

)

(

)

v = &y& d + K 1 ⋅ y& d − y& + K 2 ⋅ y d − y + K 3 ⋅ ∫ y d − y dt



¾ linear, asymptotic stable error dynamics &e& + K 1 ⋅ e& + K 2 ⋅ e + K 3 ⋅ e dt = 0 ¾ tuning e.g. with pole placement … w

d

trajectory planing

yd

v controller

state feedback

u

machine tool

- homogenous system performance over the whole workspace - simple tuning of PID controller - robustness? Institute B of Mechanics Prof. Dr.-Ing. Peter Eberhard University of Stuttgart

x

Flat Controller Design with Feedforward Linearization • feedforward linearization (Hagenmeyer, Delaleau 2003)

(

u = u y d , y& d , v

)

¾ exact linearization when being on the desired trajectory • PD controller, PID controller

(

)

(

)

(

)

v = &y& d + K 1 ⋅ y& d − y& + K 2 ⋅ y d − y + K 3 ⋅ ∫ y d − y dt ¾ stabilizing in the vicinity of the desired trajectory w

d

trajectory planing

yd controller

v

feedforward linearization

u

machine tool

x

z=x

Institute B of Mechanics Prof. Dr.-Ing. Peter Eberhard University of Stuttgart

- better robustness expected against measurement noise, parameter uncertainties …

Why Co-Simulation? Co-Simulation + implementation of control and other non-mechanical model parts ¾ well established control design and simulation tools ¾ easy to adapt/change ¾ offline trajectory generation ¾ real time code generation ¾…

Institute B of Mechanics Prof. Dr.-Ing. Peter Eberhard University of Stuttgart

simulation of complex MBS ¾ nonlinear dynamics ¾ kinematic loops ¾ elastic bodies ¾…

ability to efficiently test MBS with different control concepts etc. and vice versa

control • easy to change/adapt • real-time code (dSPACE …) desired trajectory (generation offline)

Simulation Environment

positions, velocities, …

SIMPACK

SIMULINK

motor forces, …

Institute B of Mechanics Prof. Dr.-Ing. Peter Eberhard University of Stuttgart

process forces

Open- vs. Closed-Loop Control

with 30% disturbance of the moment of inertia of the rod and the cantilever in the state feedback calculation

closed-loop

0.8

0.8

0.6

0.6

yTCP [m]

yTCP [m]

open-loop

0.4

0.2

0.2 2.6

0.4

2.8

3

xTCP [m]

3.2

3.4

Institute B of Mechanics Prof. Dr.-Ing. Peter Eberhard University of Stuttgart

2.6

2.8

3

xTCP [m]

3.2

: trajectory : simulation result

3.4

Linear vs. Nonlinear Controller

trajectory 0.8 -3

0.6

x 10

0.2 -2

4 2 0 -2 -4 0 -3 x 10 4 2 0 -2 -4 0

∆xP [mm]

0.4

-1

0

xTCP [m]

1

2

with 30% disturbance of the moment of inertia of the rod and the cantilever in the state feedback calculation

Institute B of Mechanics Prof. Dr.-Ing. Peter Eberhard University of Stuttgart

∆xH [mm]

yTCP [m]

position error of the supports

10

20

10

20

time [s]

: linear controller : flatness-based controller

Simulation with Process Forces

trajectory 0.8 0.6

∆xP [µm]

2

0.4 0.2 -2

-1

0

xTCP [m]

1

2

simplified model of the milling process

Fc = kc (v f )(sin (Ωzt ) + 1) in feed direction FcN = kcN (v f )(sin (Ωzt ) + 1) in z-direction

-6

0

2

x 10

5

10

15

20

25

5

10

15

20

25

-6

0

-2

Institute B of Mechanics Prof. Dr.-Ing. Peter Eberhard University of Stuttgart

x 10

-2

∆xH [µm]

yTCP [m]

position error of the supports

time [s]

with 30% disturbance of the moment of inertia of the rod and the cantilever in the state feedback calculation workspace

Feedforward and Feedback Linearization section of workspace

1

0.6

0.6

0.55 0.4

yTCP [m]

yTCP [m]

0.8

0.2 0

0.2

: trajectory

0.4

0.6

xTCP [m]

0.8

: feedback linearization : feedforward linearization

Institute B of Mechanics Prof. Dr.-Ing. Peter Eberhard University of Stuttgart

0.5

0.45

0.4

-10

-5

xTCP [m]

0

5 -3 x 10

with 30% disturbance of the moment of inertia of the rod and the cantilever in the state feedback calculation workspace

Feedforward and Feedback Linearization large initial error of the supports

1

0.05

∆xP [m]

0

-0.05

0.6

-0.1

0.4

0 0.2

0.05

0.1

0.05

0.1

0.4 0

0.2

: trajectory

0.4

0.6

xTCP [m]

0.8

: feedback linearization : feedforward linearization

∆xH [m]

yTCP [m]

0.8

0.2 0 0

Institute B of Mechanics Prof. Dr.-Ing. Peter Eberhard University of Stuttgart

time [s]

with 30% disturbance of the moment of inertia of the rod and the cantilever in the state feedback calculation workspace

Feedforward and Feedback Linearization position error of the supports

1

1

∆xP [µm]

0.6 0.4

-6

0

-1

0.2

1 0

0.2

: trajectory

0.4

0.6

xTCP [m]

0.8

: feedback linearization : feedforward linearization

∆xH [µm]

yTCP [m]

0.8

x 10

2

3

4

1

2

3

4

-6

0

-1

Institute B of Mechanics Prof. Dr.-Ing. Peter Eberhard University of Stuttgart

x 10

1

time [s]

conclusions • • • • •

flatness-based controller feasible physically insightful simple controller design improves performance significantly co-simulation with SIMPACK and MATLAB/SIMULINK very useful

outlook • model enhancement (elastic MBS, …) • controller enhancement (active vibration damping, hierarchical control) • validation of model and simulation results at the real machine Institute B of Mechanics Prof. Dr.-Ing. Peter Eberhard University of Stuttgart