Accelerometer – Model Identification and Controller Design
May 2009
System Block Diagram
The simplified block diagram for the system is shown below in Figure 1. The objective of the closed-loop
control system to track the desired position. In this application the desired position is dead centre. The
current is scaled and deformed to yield an estimate of the external acceleration experienced by the
accelerometer.
Acceleration
Desired Position Controller Accelerometer Actual
Current
D(z) G(z)
Position Error Position
Measured Position
Figure 1: System block diagram of a single-axis accelerometer.
Control Strategy
Here we shall only consider a pair of electromagnets aligned along a fixed axis with the magnetic bead
attached to the fibre optic pendulum positioned between these two electromagnets (See Figure 2).
Figure 2: Electromagnet pair and magnetic bead attached to the optic fibre for a single axis.
In order to suspend the magnetic bead in a stable state between the two electromagnets a bias current
(I₀), common to both electromagnets, results in both electromagnets attracting the magnetic bead.
The control current (Ic) is then added to one electromagnet’s current but subtracted from the other
one’s current to produce a displacement (Figure 3).
I₀
Ic
Figure 3: Bias current (I₀) and control current (Ic) applied to the electromagnet pair.
Measured Data
In the first tests only a single electromagnet was energised. Throughout the sampling period T was set
to 400s . The data contained in Test_1B.txt is shown below in Figure 4. This depicts the situation
where a step input is applied to the electromagnet. At the moment the step is applied the magnetic
bead oscillates about this new position and eventually settles. A close-up view of a smaller portion of
the signal reveals that the complete open-loop accelerometer system can be approximated by a second-
order system.
DACC Test 1 (Data File: Test 1B)
0.8
0.6
0.4
0.2
Position (mm)
-0.2
-0.4
-0.6
-0.8
0.5 1 1.5 2 2.5
Time (sec)
Figure 4: Data measurement for a single electromagnet activated by a step input.
Notice the slow damping of the oscillatory motion exhibited by the fibre optic pendulum.
Several other tests were conducted. Of particular interest to the current work is where a bias current
magnetises the two electromagnets so that both attract the magnetic bead. A control current is then
applied to offset the position of the magnetic bead. This experiment was repeated for several different
values of the bias current. Figure 5 shows such a case where a step input was applied to control current
input while the bias current was held fixed. The data plotted here is contained in Test_4A.txt.
DACC Test 1 (Data File: Test 4A)
0.4
0.3
0.2
Position (mm)
0.1
-0.1
-0.2
-0.3
0.5 1 1.5 2 2.5
Time (sec)
Figure 5: Data measurement for a electromagnet with a fixed bias current and a step control current.
Model Identification
The following model was fitted, in a least-squares sense, to the data,
a
x(t ) c1 e a t cos bt sin bt .
b
Setting t nT , where T is the sampling period, this equations becomes
a
x(nT ) c1 e aTn cos bTn sin bTn .
b
The corresponding z -transform [1, Appendix VIII] is
c( Az B) z
G ( z ) R( z ) ,
( z 2 z e cos bT e 2 aT )( z 1)
2 aT
where R(z ) is the input’s z -transform and
a a
A 1 e aT cos bT sin bT and B e 2 aT e aT sin bT cos bT .
b b
Since it was found experimentally that each complete oscillatory cycle of the step response contained
far more than 50 samples the effect of the ZOH was omitted. Assuming the input to have been a step
input with amplitude r0 , i.e. R( z ) r0 z /( z 1) , the pulse transfer function of the accelerometer
becomes
c( Az B) / r0
G( z )
( z 2 z e aT cos bT e 2 aT )
2
The MATLAB routines Accel_Model4.m and cost_accel4.m perform the above identification. Figure 6
shows the result obtained of identifying the above model on the data contained in Test_4A.txt.
DACC Test 1 (Data File: Test 4A)
-0.1
-0.2
Position (mm)
-0.3
-0.4
-0.5
-0.6
-0.7
-0.8
0.5 1 1.5 2 2.5
Time (sec)
(a)
DACC Test 1 (Data File: Test 4A)
-0.1
-0.2
Position (mm)
-0.3
-0.4
-0.5
-0.6
-0.7
0.4 0.45 0.5 0.55 0.6
Time (sec)
(b)
Figure 6: Second-order model identification: (a) Global view of the fit.
(b) Local view directly after the step input has taken effect.
The transfer function obtained from the above data is
0.0018901z 0.0018893 0.0018901( z 0.9996)
G( z )
z 1.9891z 0.99873 z-0.9945 - j 0.0980z-0.9945 j 0.0980
2
Controller Design
Several different controller design approached are being investigated. Here we present the results of
one particularly useful approach called optimum response design [2].
For the test data contained in Test_4A.txt the following controller was obtained by means of the
optimum response design procedure,
z 2 1.989 z 0.9987
D( z ) .
z 2 0.5001z 0.4999
The MATLAB routine Accel_Model4.m implements this control design procedure. Figure 7 compare the
original open-loop measurements with the identified model and with the controller designed using this
identified model.
DACC Test 1 (Data File: Test 4A)
-0.1
-0.2
Position (mm)
-0.3
-0.4
-0.5
-0.6
-0.7
-0.8
0.5 1 1.5 2 2.5
Time (sec)
(a)
DACC Test 1 (Data File: Test 4A)
-0.1
-0.2
Position (mm)
-0.3
-0.4
-0.5
-0.6
-0.7
-0.8
0.38 0.4 0.42 0.44 0.46 0.48 0.5 0.52 0.54
Time (sec)
(b)
Figure 7: Second-order model identification and controller design: (a) Global view.
(b) Local view directly after the step input has taken effect.
Results produced by the simulation that combines the above designed controller and the identified
plant model in a closed-loop configuration shows significant improvement in stabilising the magnetic
bead’s motion <Matlab Script Name>.
References
1. Charles L. Phillips, H. Troy Nagle, Digital Control System Analysis and Design, 3rd edition, Prentice
Hall International, 1995.
2. Francis H. Raven, Automatic Control Engineering, 5th edition, McGraw-Hill, 1995.