DOC PREVIEW
CALTECH CDS 101 - Problem Set 2

This preview shows page 1 out of 3 pages.

Save
View full document
View full document
Premium Document
Do you want full access? Go Premium and unlock all 3 pages.
Access to all documents
Download any document
Ad free experience
Premium Document
Do you want full access? Go Premium and unlock all 3 pages.
Access to all documents
Download any document
Ad free experience

Unformatted text preview:

CALIFORNIA INSTITUTE OF TECHNOLOGYControl and Dynamical SystemsCDS 101/110R. M. MurrayFall 2002Problem Set #2 Issued: 7 Oct 02Due: 14 Oct 02Note: In the upper left hand corner of the first page of your homework set, please put theclass you are taking (CDS 101, CDS 110) and the number of hours that you spent on thishomework set (including reading).All students should complete the following problems:1. For each of the following systems or subsystems, describe the “state”, the “inputs” and “output”, andthe “dynamics”. Your may give your answers in words, but please be as precise as possible.(a) Inverted pendulum(b) Lateral motion of an automobile(c) Microsoft Word(d) Flying insect(e) New York Stock Exchange2. (MATLAB/SIMULINK) In this problem you will build a model of a vehicle in SIMULINK and controlthe vehicle using feedback control. The vehicle will consist of a body (chassis + wheels) and a drivetrain (engine + transmission). Assume that the vehicle dynamics are of the formm ˙v = −bv + Fengine+ Fhillwhere m = 1000 kg is the mass of the vehicle, b = 50 N sec/m is the viscous damping coefficient, andFengineand Fhillrepresent the forces on the vehicle due to the engine and the terrain, respectively. Wecan implement this in SIMULINK as a two input, one output system, written in state space form as˙xv=£−b/m¤xv+£1/m 1/m¤uvyv= xv(1)where xv= v is the vehicle state, uv=£FengineFhill¤Tis the vehicle input (two dimensional), andyv= v is the vehicle output (velocity). You should make this into a single SIMULINK block using the“State Space” block (under Simulink→Continuous→State Space in the Simulink Library Browser).You may also want to use the Mux block (under Signals & Systems).We will model the engine dynamics as a “first order lag”. Let τ represent the engine torque and assumethe engine has the following dynamics:˙τ = −aτ + ueye= Kτ(2)where a = 0.2 is the lag coefficient, K = 5 is the conversion factor between engine torque and forceapplied to the vehicle (representing the transmission) and ueis the accelerator input (which we willassume has the proper units). You should also create a SIMULINK block for this subsystem.Finally, we include the effects of a hill. The hill simply exerts a force on the car that is based on theangle of the hill:Fhill= −mg sin(θ) (3)where g = 9.8 kg m/sec2and θ = π/18 is the angle of the hill (10 degrees).(a) Plot the output of the vehicle model (1) for a step input of Fengine= 500 Newtons (assumeFhill= 0). What is the rise time (0 to 95% of the final value)?(b) Plot the output of the engine model (2) for a step input of ue= 100 Nm. What is the rise time?(c) In the homework from last week, you built a simple cruise controller. Replace the vehicle/enginemodel in that system with your vehicle and engine models and plot the response for the defaultgains (Ki= 50, Kp= 1000). Make sure to set your simulation time to be sufficiently long.(d) Now include the effect of a hill on your system. You should model the system so that the car isinitially on a flat surface and then encounters the hill at T = 100 seconds. Plot the response ofthe system and compute the rise time.Note: if you are having trouble figuring out how to create these blocks in SIMULINK, take a look at“hw1cruise.mdl” from last week’s homework and see if you can modify it appropriately. It has all ofthe subsystems you will need (except for the Mux block). You may also find the following web-basedtutorial helpful:http://www.engin.umich.edu/group/ctm/examples/cruise/cc.html(ignore the sections on transfer functions; we will get to these later in the class).Only CDS 110a/ChE 105 students need to complete the following additional problems:3. (MATLAB) Build a finite state controller for a traffic light system at an intersection. Your controllershould take as inputs the sensor signals on the road that detect whether a car is present and shouldhave as outputs the colors of the various signals. For simplicity, assume that all traffic is two-way (i.e.don’t worry about left turn lanes, etc.). Implement your solution as a MATLAB function, which youcan assume is called every 1 second of intersection operation. See the accompanying documentationon the course web page for more details:http://www.cds.caltech.edu/~murray/cds101/L2.1_modeling.shtml#Homework4. Consider the following discrete time systemz[k + 1] = Az[k] + Bu[k]y[k + 1] = Cz[k + 1]wherez =·z1z2¸A =·a11a120 a22¸B =·01¸C =£1 0¤In this problem, we will explore some of the properties of this discrete time system as a function of theparameters, the initial conditions, and the inputs.(a) Assume that the off diagonal element a12= 0 and that there is no input, u = 0. Write a closedform expression for the output of the system from a nonzero initial condition z[0] = (z1[0], z2[0])and give conditions on a11and a22under which the output gets smaller as k gets larger.(b) Now assume that a126= 0 and write a closed form expression for the response of the system froma nonzero initial conditions. Given a condition on the elements of A under which the output getssmaller as k gets larger.(c) Write a MATLAB program to plot the output of the system in response to a unit step input,u[k] = 1, k ≥ 0. Plot the response of your system with z[0] = 0 and A given byA =·0.5 10 0.25¸25. Consider the coupled mass spring system show in the figure below (the same one considered in classon Monday):u(t) = sin ωtm mkkbq1q2kbThe input to this system is the sinusoidal motion of the end of rightmost spring and the output is theposition of each mass, q1and q2.(a) Write the equations of motion for the system, using the positions and velocities of each mass asstates.(b) Rewrite the dynamics in terms of z1=12(q1+ q2) and z2=12(q1− q2).(c) Note that the resulting equations are diagonal. Solve these linear ODEs for z1(t) and z2(t) giveninitial conditions and input.(d) Plot the amplitude and relative phase of the motion of the first mass as a function of the frequencyof the sinusoidal input (you may assume a unit magnitude input). You can either solve thisproblem numerically (by building a simulation and measuring the results) or analytically (usingthe solution from part 5c and computing the motion of the first mass). If you use a numericalsolution, you can use m = 250, k = 50, b =


View Full Document

CALTECH CDS 101 - Problem Set 2

Documents in this Course
Load more
Download Problem Set 2
Our administrator received your request to download this document. We will send you the file to your email shortly.
Loading Unlocking...
Login

Join to view Problem Set 2 and access 3M+ class-specific study document.

or
We will never post anything without your permission.
Don't have an account?
Sign Up

Join to view Problem Set 2 2 2 and access 3M+ class-specific study document.

or

By creating an account you agree to our Privacy Policy and Terms Of Use

Already a member?