Jump to content
We Need Your Help! ×

IGNORED

Calling all engineers


Patcon

Recommended Posts

My daughter has an assignment and she is struggling to get going at it the right way. Maybe one of you whiz kids could help

"Basically, I am trying to figure out what the Equations of Motion (EOM) for the system are. It is complicated by the fact that we have a moving cart and a massless pendulum. "

image.png

Inverted pendulum is a classic problem in control engineering, as its unstable nature poses a significant challenge to the design and implementation of its controller. The typical configuration of an inverted pendulum system is shown in the figure below.
The moving cart that supports the inverted pendulum is powered by an electric motor through a pulley-belt drive. The rotating bar of the pendulum (mass negligible) supports a metal ball at the top, which can be modeled as a point mass mp. The parameters of the system are as follows:
mp = 300 g; mc = 500 g;
l = 60 cm; r = 2.5 cm.
Additionally, the viscous damping in the cart movement is estimated to be bc = 125 g/sec.
Regarding the instrumentation of the system, the motor shaft rotation angle is measured with a rotary multi-turn potentiometer, with the output of 2V corresponding to each full turn of the shaft. The pendulum angle is measured with a single-turn potentiometer, with ±10V output corresponding to ±160˚ of rotation. Each signal come with 2% of noise. The DC motor in this system has a torque constant of 0.1 N-m/A, and the servo amplifier that drives the motor has a gain of 0.5A per volt of command signal. To simplify the analysis, assume that saturation of the amplifier and motor can be neglected.
2
Controller Design Goals
To prevent the inverted pendulum from falling over, the pendulum rotation angle θ should be stabilized to the equilibrium of zero degree. Additionally, due to the cart’s limited range of motion, the cart movement should be stabilized and controllable. Furthermore, the system should be sufficiently robust against disturbances (e.g., a horizontal impulse force).
As the basis of the controller design, the complete dynamic model of the system should be derived. The model of the plant takes the servo amplifier command (in the unit of V) as the input, and its outputs are the cart position/velocity and the pendulum angular position/velocity (note that only positions are physically measured with potentiometers). In your derivation, model all the dynamic effects without simplification, and obtain the complete state-space dynamic model first. It should be nonlinear. For the controller simulation, this nonlinear model should be implemented directly (without linearization) in the Matlab Simulink to represent the physical system (“plant”). Subsequently, in the controller design, the model can be linearized such that the linear control techniques can be applied.
Two types of control approaches should be investigated, including the classical control (PD or lead compensator) and the modern control approach (full-state feedback).
(1) For the classical control method, the single output of the system should be the cart position (NOT the pendulum angular position). If such method is unable to accomplish the design goal, detailed derivation should be presented to support your conclusion.
(2) For the modern control method, both cart position and pendulum angular position should be controlled. Use the pole placement technique to design the controller.
The controllers should be simulated to quantify its performance. As the references (set points), the desired pendulum angular position is always zero degree (i.e., vertical), and step/ sinusoidal commands should be used for the desired cart position. Furthermore, a horizontal pulse force should be applied to the tip of the pendulum to test and quantify the controller’s robustness, and the maximum value of the force that can be accommodated by your controller should be included in the project report.
Deliverables
This is a group project, with two to three students in each group. The grades will be assigned based on a controller presentation/demonstration (20%), and a project report (80%).
The controller presentation/demonstration will be conducted during the last week of class. Each group will give a 5-minute presentation (2 slides) to summarize the controller design, and demonstrate the controller in Simulink. The controller should be encapsulated into a two-input-single-output subsystem, and combined with the standard plant model (provided by the instructor) for the demonstration.
The project report is due April 26, 2019. Scan or convert your report into a single, colored pdf file (less than 10 MB) and submit it through Blackboard (a group assignment will be created for this purpose). No other files should be uploaded. The following contents are expected in the report (the contents should be arranged in the order shown below):
3
1. A short transmittal letter briefly describing the contributions of each group member, not to exceed one page. This letter should be dated and signed by all group members. (10%)
2. A short description of the project, not to exceed one page using 12 point Times font, minimum 1.5 line spacing, and 1 inch margins all around (minimum). This description should provide an overview of the results obtained in the project, including the system model, the controller design, as well as the simulation results. (10%)
3. System modeling analysis and results. All relevant equations and diagrams should be included. (15%)
4. Control design analysis and results. All details should be presented, including the figures and Matlab scripts. (25%)
5. Simulation results. Simulate the responses to the following commands in cart position: i) a commanded 10 cm step; and ii) 10 cm amplitude sinusoidal commands at 0.25/0.5/1.0 Hz frequencies. Additionally, simulate the system response to an impulse force applied to the tip of the pendulum. Gradually increase the force magnitude and find the maximum value that can be accommodated. Plot the responses of all four states, and also plot the motor torque required. For the sinusoidal tracking, your plots should capture 3 cycles of the desired cart command. Include a discussion on the simulation results, especially on the tracking performances at the different frequencies and the controller’s capability in disturbance rejection.

Link to comment
Share on other sites

That looks quite complex.  Been a long time since I have taken a physics class, like almost 40 years.

While I have worked extensively with DC motors and mechanical systems, I have not worked at all with control and feed back loops, or servo motors.  My thoughts on this are that you would want to set-up the +/-10V potentiometer output (and it's pendulum components) on one side of the equation and the motor Voltage/Torque (and it's components) on the other side.  However, they could not necessarily be equal because you would never correct the pendulum back to zero.  Seems like you would have to overshoot/exceed the potentiometer output to re-center the pendulum.  Perhaps the frequency determines how quickly the pendulum gets re-centered.  I would think that the massless pendulum arm would make the calculation a bit simpler, although, doesn't seem to be anything simple about this.  That's about as far as I'm going to get on this.

Interesting that the damping is a grams/sec value and not a function of the cart velocity, x/sec.

Hopefully this is a college level problem and  not high school  ☺️

Link to comment
Share on other sites

2 minutes ago, motorman7 said:

That looks quite complex.  Been a long time since I have taken a physics class, like almost 40 years.

While I have worked extensively with DC motors and mechanical systems, I have not worked at all with control and feed back loops, or servo motors.  My thoughts on this are that you would want to set-up the +/-10V potentiometer output (and it's pendulum components) on one side of the equation and the motor Voltage/Torque (and it's components) on the other side.  However, they could not necessarily be equal because you would never correct the pendulum back to zero.  Seems like you would have to overshoot/exceed the potentiometer output to re-center the pendulum.  Perhaps the frequency determines how quickly the pendulum gets re-centered.  I would think that the massless pendulum arm would make the calculation a bit simpler, although, doesn't seem to be anything simple about this.  That's about as far as I'm going to get on this.

Interesting that the damping is a grams/sec value and not a function of the cart velocity, x/sec.

Hopefully this is a college level problem and  not high school  ☺️

Well, his kids are home-schooled, and his wife is a pretty tough teacher, so that's not a given.

Link to comment
Share on other sites

I think it is just a torque problem.  The basic element is force in the +X direction from the car on the ball transmitted along the shaft has to counter the -X direction force of mg from the ball falling.... which I believe is proportionate to sin θ. 

When θ is negative and the ball falls in -x everything is reversed.

Equation of motion is F=ma for the cart where F is equal to the X component of F=mg Sin θ  from the falling ball.

 

Seems like a Segway.

 

btw I'm not an engineer ?

Edited by 240260280
Link to comment
Share on other sites

Just remember that the period of oscillation is independent of the mass of the pendulum.  Ha ha ha...  Wikipedia.  I don't know any of this.  And don't feel bad, Galileo had problems too.  Maybe you should pray.  

https://en.wikipedia.org/wiki/Equations_of_motion

"Galileo did not fully grasp the third law of motion, the law of the equality of action and reaction, though he corrected some errors of Aristotle. With Stevin and others Galileo also wrote on statics. He formulated the principle of the parallelogram of forces, but he did not fully recognize its scope.

Galileo also was interested by the laws of the pendulum, his first observations of which were as a young man. In 1583, while he was praying in the cathedral at Pisa, his attention was arrested by the motion of the great lamp lighted and left swinging, referencing his own pulse for time keeping. To him the period appeared the same, even after the motion had greatly diminished, discovering the isochronism of the pendulum.

More careful experiments carried out by him later, and described in his Discourses, revealed the period of oscillation varies with the square root of length but is independent of the mass the pendulum."

 

 

  • Haha 1
Link to comment
Share on other sites

Wow... That's no fun. At all. Due in two days, huh?  I'm assuming this is a final project for a control theory class? I can't give you any hard answers, but might be able to help a little bit in some areas.

First thing to do would be to define the project...  It appears to me that there are two major approaches that should be applied to solve the problem:

a) First approach (the "classical control method") in which the single output of the system should be the cart position (NOT the pendulum angular position). So the only thing you have is the force required to move the cart.

If the pendulum is not vertical, the force required to move the cart in the direction of the (off center) pendulum will be greater than if the pendulum were perfectly vertical (in equilibrium). And the force required to move the cart AWAY from the (off center) pendulum will be LESS than equilibrium.

So it sounds to me that the "classical control method" would be to rock the position of the cart back and forth (sinusoidal) and measure the force required to move it. That force should be able to be derived by the current necessary to rotate the motor. That's where the PD lead-compensator stuff comes in... You should be able to keep the sine wave constant and as small as possible.

And there is some doubt about the success of this approach as laid out in the original problem. You are supposed to program it all up this way and see if you can make it work. And if not, explain why not. For example, the control loop may not be stable and you may find that the sine wave required is increasing in amplitude until you run out of track length. I suspect this approach is not very robust and resistant to outside applied interference (the bump nudge described in the problem).

b) The second approach allows the student to utilize the position feedback on the pendulum and it becomes a more direct control loop. Move the cart in the direction the feedback pot tells you to and strive to keep the output of the feedback pot at 0V. That should be much faster and more accurate feedback than using the cart force and should be able to do a much better job of compensating for externally applied interference.  (Proof is left to the student.)

If I understood the project correctly, then I would break it down into pieces:

Write some equations for the force required to move the cart independent of the pendulum.
Write some equations for the force on the cart due to the position of the pendulum (this is the part that Blue started working on above).
Then combine the two.
Write some equations for the relationship between the rotation of the shaft and the linear position on the cart.
Write some equations for the electrical energy required to rotate the shaft.

Etc...

I'm so glad I graduated!!      :geek:

Link to comment
Share on other sites

Hey guys, this is Georgia (the daughter working on the project, and yes @motorman7 it's a college problem ?.)

 

 
 
 
2 hours ago, SteveJ said:

And as usual, an engineer provides a completely correct answer that doesn't help you resolve the situation at all.

A true engineer at heart!  It's the thought that counts right? 

 

 
 
 
 
 
 
5 minutes ago, Captain Obvious said:

b) The second approach allows the student to utilize the position feedback on the pendulum and it becomes a more direct control loop. Move the cart in the direction the feedback pot tells you to and strive to keep the output of the feedback pot at 0V. That should be much faster and more accurate feedback than using the cart force and should be able to do a much better job of compensating for externally applied interference.  (Proof is left to the student.)

Write some equations for the force on the cart due to the position of the pendulum (this is the part that Blue started working on above).
Then combine the two.

When writing the equations to account for the angle, would it be fair to assume that theta is very small so as to simplify the sine and cosine aspects of the equation? I believe it is, but I am also ending up with a fourth order equation which is only slightly the worst thing ever to solve. ?

 

-G

Link to comment
Share on other sites

If the control loop is working properly, then theta should be very small.  Problem is to make the control loop work properly.

Actually for the second section, if you are allowed to use the feedback pot on the pendulum shaft, "theta" becomes a "concept". You just need volts:

"The pendulum angle is measured with a single-turn potentiometer, with ±10V output corresponding to ±160˚ of rotation"

That means you've got +10 V when the pendulum is almost horizontal in one direction and -10V when it's almost horizontal in the other. You've got +/-16 degrees per volt or (the inverse of that) 125 mV per degree around vertical.

You're striving to keep the pendulum pot output at 0.00000 volts. And every 125 millivolts you are away from that is one degree off vertical and the sign of the voltage will tell you which way you are off.

 

 

Edited by Captain Obvious
Math clarification
Link to comment
Share on other sites

I'll simplify my suggestion: 

1. The ball wants to fall vertically in Y axis due to the force of gravity. 

2. The cart can only push/pull in X axis (i.e. it can not push ball upward in Y direction). This limits all forces to right the pendulum in the X axis.... so the force of the falling ball has to be translated to X axis. 

3. The ball-on-a-stick is a classic torque model where the rotational force at the fulcrum can be broken into an X and a Y component proportional to the angle. (Typically θ  is drawn between the arm and X axis and cos θ would be used to obtain X component of force but in this case sin θ is needed)

 

Once the relationship with the torque's X component is expressed, the rest is just translating this to the pulley and strings then translating to voltage.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Privacy Policy and Guidelines. We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.