# Exercise: State feedback control of an AFM in contact mode

From FBSwiki

Consider the model of an AFM in contact mode given in Example 5.9:

Use the MATLAB script afm_data.m to generate the system matrices.

- Compute the reachability matrix of the system and numerically determine its rank. Scale the model by using milliseconds instead of seconds as time units. Repeat the calculation of the reachability matrix and its rank.
- Find a state feedback controller that gives a closed loop system with complex poles having damping ratio 0.707. Use the scaled model for the computations.
- Compute state feedback gains using linear quadratic control. Experiment by using different weights. Compute the gains for , and and explain the result. Choose and explore what happens to the feedback gains and closed loop eigenvalues when you change . Use the scaled system for this computation.