Search:

[Login]  
 Research & Teaching
· Courses

 Resources
· FAQ
· Wiki
· Web Mail
· Mailing Lists
· Web Folders
· Projects

 Search


FAQ (Frequently Asked Questions)

Category: CDS 101/110 Fall 2003

Identifiers: FN H0 H1 H2 H3 H4 H5 H6 H7 H8 L0.0 L1.1 L1.2 L10.1 L2.1 L2.2 L3.1 L3.2 L4.1 L4.2 L5.1 L5.2 L6.2 L8.1 L9.1 L9.2

Questions

Answers

  • How can I go from a continuous linear ODE to a discrete representation?
    Submitted by: lars
    Submitted on: October 8, 2003
    Identifier:
    L2.2

    MATLAB has functions built-in to the Control Systems Toolbox that handle conversion between continuous and discrete time using various methods. You can represent your continuous time system (written in standard first order form) with the "sys" command

    sysc = sys(A,B,C,D)

    and convert it to discrete-time with the function "c2d":

    sysd = c2d(sysc,Ts); % Ts = sampling period in seconds

    There are a couple of good references for the mathematics behind these conversions. Franklin, Powell and Enami-Naeni has a section on this, and Mathworks has some excellent background on manipulating linear time-invariant (LTI) systems in their help files. They can be accessed at http://www.mathworks.com/access/helpdesk/help/toolbox/control/manipmod/manipmod.shtml (look for "Continuous/Discrete Conversions of LTI Models" in the menu on the left).

    [Back to Top]

  • Why is it called infinite (finite) impulse response
    Submitted by: macmardg
    Submitted on: October 8, 2003
    Identifier:
    L2.2

    A system has "finite impulse response" if, for an input which is nonzero only at zero time (u_0=1, u_k=0 for k non-zero), the output is identically zero after some finite time. Otherwise, the system has "infinite impulse response". If the output depends only on a finite number of past inputs, then it will eventually be zero. If the output *also* depends on past values of the state, then it may decay towards zero, but is never identically equal to zero. There were several related questions; the specific definition of IIR and FIR systems is not directly relevant to the course, but are useful as examples to understand the concept of state. For these systems, the output depends on prior inputs and/or prior values of the output. Since the "state" at time k+1 depends only on the state at time k and the input at time k, then these prior values must be considered as part of the state vector. There is some discussion of FIR and IIR systems in the context of filter design on the Mathworks web site (http://www.mathworks.com/access/helpdesk/help/toolbox/signal/signal.shmtl and look for "IIR filter design" and "FIR filter design" under "Filter Design and Implementation" in the menu at the left.)

    [Back to Top]

  • How do you know when your model is sufficiently complex?
    Submitted by: waydo
    Submitted on: October 8, 2003
    Identifier:
    L2.2

    Knowing when your model is sufficiently complex is often a somewhat subjective judgement call and one that requires some experience to be comfortable with. Some choices are clear, for example in the model of Bob's interaction with the terrain from class we certainly don't have to worry about the motion of a person riding within the vehicle. Others are less so, for example whether a one-wheel model of Bob is sufficient or if it would miss important features captured by the two-wheel model.

    When we're really not sure what we end up doing is building models at multiple levels of complexity and comparing the results - if we weren't convinced that a single-wheel model of Bob was sufficient for the problem we discussed in class, the fact that the results were almost identical to those obtained from the more complex two-wheel model should convince us. Often a simple model will be used for most of the work and occasionally verified against a more complex model that would be more difficult to work with most of the time.

    As was implied by the feedback loop in the design path put on the board in class, sometimes we discover our model was not sufficiently complex only when we build and test a system and it does not behave as expected. At that point we try to identify the neglected factors that were important and modify our model to include them.

    [Back to Top]

  • I did not understand the difference equation examples.
    Submitted by: waydo
    Submitted on: October 8, 2003
    Identifier:
    L2.2

    Check out the FAQ topic called "Why is it called infinite (finite) impulse response?" - hopefully that will help explain exactly what IIR and FIR systems are.

    In general, it may be helpful to think of a difference equation as representing a sampling of a continuous system at discrete times, say by a digital sensor. To write an equation about how such a system changes in time, rather than using a derivative we talk about the difference between this state and the next one. If we then think about taking the sampling interval to zero, we get an ODE back out again.

    [Back to Top]

  • What is a dashpot?
    Submitted by: waydo
    Submitted on: October 8, 2003
    Identifier:
    L2.2

    webster.com defines a dashpot as "a device for cushioning or damping a movement (as of a mechanical part) to avoid shock" and generally refers to a device in which a plunger is pressed through a cylinder of fluid, as in a shock absorber in a car, which should explain the symbol we use to draw one.

    The standard model of a dashpot is that it provides force proportional and opposite in direction to the velocity of the plunger, which corresponds to the viscous friction model we use with many systems. Because of this, we often draw a dashpot to represent any viscous friction, regardless of the actual cause.

    [Back to Top]

  • In a difference equation, how is the state continuous even though the time is discrete?
    Submitted by: mreiser
    Submitted on: October 8, 2003
    Identifier:
    L2.1 , L2.2

    This type of system model arises naturally in many problems. Consider for example the predator-prey from Monday's lecture. In this model the state vector (consisting of the number of rabbits and the number of foxes) is treated as real-valued (though of course thinking about non-integer animal quantities seems silly), and the rate at which we update the population occurs at a discrete time interval, one year or one months or similar.

    Perhaps a better example is any sample-based system. Suppose our cruise controller uses some standard microprocessor system, that samples the instantaneous car velocity at some fixed rate. Here the sampling in our sensor generates the discreteness of the problem, but of course the quantity we sample can take on any value. We could try to write continuous time control laws for this system, but it seems foolish to do so, since we only get information about our system at discrete time steps. One simple thing we might want to do with these sampled values is smooth them so we are less likely to be effected by a sensor error. This can be done with a difference equation that implements a moving average, where the state vector keeps track of the last few measurements.

    [Back to Top]

  • Could you explain the matrix-within-a-matrix notation?
    Submitted by: demetri
    Submitted on: October 8, 2003
    Identifier:
    L2.2

    This notation occurs commonly in control theory. It is a shorthand for matrix concatenation (cf. the matlab tutorial in which we created matrices as concatenations of other matrices).

    The idea is simple: simply stack (row or column-wise) the matrices as indicated. This notation is only used when it is dimensionally consistent, i.e. all rows and columns should line up properly.

    An example: let I be the 2x2 identity matrix and Z the 2x2 zero matrix. Then, consider the following matrix:

    H = [Z I; -I Z]

    H is precisely the following 4x4 matrix:

    H = [0 0 1 0; 0 0 0 1; -1 0 0 0; 0 -1 0 0]

    Again, the semicolon indicates the end of a row.

    [Back to Top]

  • Could you explain the A matrix and B vector in the mechanical model?
    Submitted by: demetri
    Submitted on: October 8, 2003
    Identifier:
    L2.2

    First, for a discussion of matrix-within-a-matrix notation, see the associated FAQ.

    Now, recall that in control design we want to formulate the differential equation in first order form. The original equation is:

    Mx'' + Cx' + Kx = F

    Here M C and K are nxn, and F is nx1, where n is the number of degrees of freedom of the system (informally speaking, the number of masses).

    Recall that for first-order form, we simply append the derivative vector to the state vector. Multiplying the orignal equation by the inverse mass-matrix, we obtain:

    x'' +M-1Cx' + M-1Kx = M-1F

    Denoting the (2nx1) state vector by q, we can write the above equation as:

    [0 I]q' + [M-1K M-1C]q = M-1F

    Now all we need is to append the fact that the state vector consists of the positions and their velocities:

    [I 0]q' = [0 I]q

    Assembling all the pieces, we have:

    q' = [0 I; M-1K M-1C]q + [0;M-1F]

    [Back to Top]

  • How is the Jordan form related to the matrix exponential?
    Submitted by: demetri
    Submitted on: October 8, 2003
    Identifier:
    L2.2

    First, one should check the previous FAQ(s) on Jordan form. Second, we promise that all relevant material on Jordan forms will be presented as needed in class :-)

    Having said that, the Jordan form of a matrix (say A) satisfies a "similarity" relation:

    A = TJT-1

    Here T is the matrix of (generalized) eigenvectors of A. Let's check out the square of A:

    A2 = TJT-1TJT-1 = TJ2T-1

    Thus, we can move power series (and by extension, exponentiation) "inside" the similarity transformation defined by T. This is very useful because exponentiating Jordan blocks is much easier than exponentiating general matrices (see the associated FAQs for these issues).

    Hence, the Jordan form gives a convenient formula for exponentiation of a matrix.

    [Back to Top]