[Solved] ME227 Assignment 6-Linearization and Project Reflection

$25

File Name: ME227_Assignment_6-Linearization_and_Project_Reflection.zip
File Size: 518.1 KB

SKU: [Solved] ME227 Assignment 6-Linearization and Project Reflection Category: Tag:
5/5 - (1 vote)

For this homework, we will study linearization, reflect on the project, and start thinking about racing.

Instructions

This homework assignment will be submitted using Gradescope.

All written portions must be turned in through Gradescope. See the Piazza post on homework guidelines for more instructions on the different homework resources available to you. Whatever format you decide to use, please BOX all of your final answers.

1

Problem 1 Linearization

In the last homework, you used your intuition about vehicle dynamics to determine signs of feedback gains to stabilize around a drift equilibrium. This week, we are going to learn how we can compute a linearization and use linear control techniques to determine these gains, rather than by inspection.

For all the following problems, consider a drift equilibrium consisting of req = 0.7486 rad/s, Uy,eq = 8.661 m/s, Ux,eq = 10.3224 m/s, eq = 0.5132 rad, and Fxr,eq = 7317 N.

(This is derived from drifting an 18 meter radius path ( = 1/18) with constant sideslip of 40)

Question 1.A Linearization of our Velocity Dynamics (MATLAB Grader)

Up until now, we have linearized our dynamics via linear assumptions, such as small angle approximations and linear tires. We will now directly linearize our dynamics (which allows analysis and control of cool vehicle behavior such as drifting).

Consider just our velocity states, so x = [r,Uy]T. We can write our dynamics as being a nonlinear function of our state and steering input (forget Fxr for now assume we are using the same longitudinal controller from HW5): x = f(x,)

We can linearize the dynamics and write our system as:

x = f(xeq) + A(x xeq) + B( eq) = A(x xeq) + B( eq)

x = Ax + B

(6.1)

(6.2)

To calculate the partial derivatives, we need to carefully consider what each term in our dynamics is a function of. Based on the Fiala lateral tire model:

Fyf = f(f) = f(Uy,r,)

Generally while drifting, r > sl so:

Fyr = f(Fxr)

So to calculate the first entry in the A matrix:

To calculate , we then need to take the derivative of each term in the Fiala model with respect to r. The rest of the derivatives can be computed similarly.

For this two state model we have computed the A & B matrices for you (so you wont need to take the derivative of the Fiala model). However, make sure you understand how one could compute each term in A & B, as you will be finding some of the derivatives in the next problem.

(6.3)

(6.4)

Finally, lets use the control law = Kx (full state feedback).

Find the gain vector K that puts the poles of the closed loop system at -4 and -8. Compute this by hand and show your work. Submit your gain vector to MATLAB Grader.

Question 1.B Incorporating Path Tracking (MATLAB Grader)

Drifting by itself is pretty cool, but what if we wanted to incorporate a reference path? Lets define a new state x = [r,Uy,e,]T.

Find a value for eq given the drift equilibrium we are using in this problem. Do not make any small angle assumptions.

Lets linearize these dynamics as before and then try to find gains that stabilize the system. This time, our linearized matrices are:

(6.5)

(6.6)

Find ss and the new linearized dynamics matrices. Using full state feedback as before, place the poles at [-4 +/- 4.5j, -0.15 +/- 0.75j]. You are encouraged to use the place function in

MATLAB. Report your gain vector and ss on MATLAB Grader

Question 1.C Simulation (MATLAB Online / Gradescope)

Lets see if the gains for combined drifting and path tracking work. Implement our new controller using the provided simulator framework.

We have provided the 18m radius reference path, as well as the lower level functions that you have implemented several times by now. You only need to edit the file called mainproblem 1c.

Provide two plots, one of the velocity states (Ux, Uy, r) and one of our path tracking errors (Figs 2 &4 in provided plotting script). Do the results match what you expected, based on our closed loop pole locations? Why or why not.

Problem 2 Reflection

Youve completed your project. Youve watched your lookahead and group controller executed on a real vehicle. Youre officially a vehicle dynamicist!

In the project, you developed feedforward and feedback controllers for steering Niki along a defined path. Having had a chance to try those controllers on the actual car, you now have additional information about the appropriateness of your design choices beyond what you could gain from simulation. We want you to reflect on your project experience in light of this new information. This should be an individual response, not a team response. If you do find something wrong in your code when answering the first question, however, you can (and should) point this out to your teammates.

With the data and video from your vehicle testing, lets take a closer look at how your simulated performance compares to the actual performance on the vehicle.

Question 2.A Reflection of Lookahead Controller (Gradescope)

Well start with a reflection on your lookahead controller. Lets take a look at your code and make sure that everything was actually implemented correctly. A couple of teams had some implementation issues so, if your results seemed strange, check again that your code was written correctly.

Next, consider whether you think the amount of feedback and feedforward was appropriate. Feedforward enables you to lower feedback gains by adjusting the steering to the value you expect you need for a turn. It can, however, lead to errors if the feedforward steering is not exact (which is very possible if there is even a slight misalignment of the steering). Feedback particularly proportional feedback reduces the steady-state error but also makes the system response faster, potentially amplifying noise or the effects of delay.

  • Was everything implemented correctly? If not, what implementation challenges did your team run into?
  • Did each of your controllers effectively use feedback and feedforward? Support your conclusion with plots of your performance.

Question 2.B Reflection of Group Controller (Gradescope)

Now lets move on to your groups controller. Lets take a look at your code once more to make sure that everything was actually implemented correctly. Lets again consider whether you think the amount of feedback and feedforward was appropriate in this case.

  • Was everything implemented correctly? If not, what implementation challenges did your team run into?
  • Did each of your controllers effectively use feedback and feedforward? Support your conclusion with plots of your performance.

Question 2.C Reflection of Project (Gradescope)

Now that weve reflected on both the lookahead controller and your groups controller, lets reflect on what weve learned from the design, analysis, and testing of these controllers.

  • What did you take away from the project?
  • What, if anything, is still unclear to you about the controllers you used or linear vehicle dynamics after this project?

Reviews

There are no reviews yet.

Only logged in customers who have purchased this product may leave a review.

Shopping Cart
[Solved] ME227 Assignment 6-Linearization and Project Reflection
$25