Today's. pptx

advertisement
Lecture 2. A Day of Principles
(with an example that applies ‘em all at the end)
The principle of virtual work
d’Alembert’s principle
Hamilton’s principle
1
Principle of virtual work says
the work done by a virtual displacement from an equilibrium position must be zero.
N
W   fi  ri  0
i1
This can be used in statics to find forces
to move this up to dynamics
We need
d’Alembert’s principle says that ma  mvÝ can be treated as an
inertial force

2
Combine these
N
W   fi  mvÝi  ri  0
i1
We eliminated internal forces last time, so the fs are external

We suppose we know them, and since the displacement is tiny
they don’t change during the virtual displacement
3
The virtual displacements, if unconstrained, can be written
ri  xi  yj zk
What I’d like to do is gather all of this up into what I’ll call configuration space

q  x1

y1
z1
x2
y2
z2
xK
yK
zK 
T
The dimension of q is N = 3K
4
That’s just an example of a configuration space.
We’ll see more as we go along.
The general rule, which we’ll investigate as we go along,
there are (at least) as many qs as there are degrees of freedom.
We’ll take up the matter of constraints — relations among the qs —later
Bottom line: we can write the rs in terms of the qs.
5
Simple example of possible qs
k1
k3
k2
m
m
1
2
y1
y2
y1  y1  y 2 
q   , 

y
y

y
 2   1
2 

6
Each r can depend on all the qs.
ri 
N  3K

i1

N
ri k ri k
q  k q
k
q
q
W   fi  mvÝi  
i1
repeated
indices
ri k
q  0
k
q
summation
convention does not apply to i in this formula

7
Let’s do some rearranging
ri k N
ri k
Ý
f


q

m
v

 i qk
 i qk q
i1
i1
N

 N
ri  k  N
ri  k
 fi  k q   mvÝi  k q
q 
i1 q 
i1
 N
ri 

Define the generalized force Qk   fi  k 
i1 q 
 the kth generalized coordinate
This force goes with
8
 N
ri  k
k
 mvÝi  k q  Qkq
q 
i1
The left hand side looks a lot like a momentum change
dotted into something. If you like manipulations
 you’ll LOVE what comes next
First a bit of what I call “integration by parts”
d
d
Ý
Ý
Ý
fg

f
g

f
g

f
g

 
 fg  fgÝ
dt
dt

This is a useful trick in deriving things
9
ri
d  ri 
d ri 
mi vÝi  k  mi v i  k  mi v i   k 
q
dt  q 
dt q 
d

  j
dt  q

 qÝj 

d ri   ri  j
 k  j  k qÝ
dt q  q q 
 ri  j
 ri  j
qÝ  k  j qÝ
j 
k 
q q 
q q 
qÝj is not a function of q k



 ri  j
 ri j 
qÝ  k  j qÝ 
k 
j 
q q  q q

 ri j  
v i
Ý
Ý
q

r





i
q k q j  q k
q k
10
ri
d  ri 
 ri  j
mi vÝi  k  mi v i  k  mi v i  j  k qÝ
q
dt  q 
q q 
so
turns
 into
ri
d  ri 
v
mi vÝi  k  mi v i  k  mi v i  ki
q
dt  q 
q
We still
 aren’t done. The second term on the right is cool
 Ti
vi
 1
mi vi  k  k  mi vi  vi  k
 q
q
q 2
but we need to play with the first term
11
d  ri 
m i v i  k 
dt  q 
sort of a trick

r
v
r
v i  ij qÝj  ij  ij
q
qÝ q

so

 d  
d  v i  d   1
mi v i  k   k  mi v i  v i   k Ti 
 dt qÝ
dt  qÝ  dt qÝ 2


12
 N
ri  k
k
 mvÝi  k q  Qkq
q 
i1
so
 d T  T
 k
  k  k  Qk q  0
dt qÝ  q

 into
turns
Remember that there is a sum on k here!

I can split Qk into two pieces: the potential and nonpotential parts
Qk  

V
 QNP k
q k
13
 d T  T V
 k
  k  k  k  QNP k q  0
dt qÝ  q q

For our purposes

V  V q k 
V
0
k
qÝ
 d T  V  T  V 
 k
 QNP k q  0
 

k
k
q
dt  qÝ 



 d T  V  T  V  k
k


q

Q

q
 




NP k
k
qk 
dt  qÝ 
14
The Lagrangian
L  T V
 d  L  L  k
k
  k  k q  Qkq
dt qÝ  q 
From here on in Qk will be understood to be the nonpotential generalized forces
We’ll have an algorithm for the calculation later.

If the qk are independent, then we have the Euler-Lagrange equations
 d  L  L 
  k  k  Qk
dt qÝ  q 

15
What did we do and what did we assume?
Principle of virtual work
d’Alembert’s principle (inertial forces)
Independence of the generalized coordinates
All the rest was clever manipulation
l spend a lot of time dealing with cases where the qs are not independent.. . . . but not tod
16
??
17
Hamilton’s Principle
This is a formalism that leads to the Euler-Lagrange equations
and it will help us when we need to consider constraints
(relations between the qs).
This is generally posed in terms of the Lagrangian
but that eliminates the generalized forces
which I’d like to include
Let me define
L*  T  W
where W denotes the work, potential and nonpotential

18
We write the action integral
I

t2
t1
L * qk , qÝk ,t dt
The action integral depends on the path between the two end points.

19
Hamilton’s principle states
The actual path will be the path that minimizes the action integral.
Suppose that
qk  qk , qk 0  q0k

I 


t2
t1
dI
0
d
where the zero denotes the desired path
L * qk ,t , qÝk ,t ,t dt

t2
t1
L * q k L * qÝk 
 k
 k
dt
q  qÝ  
The first piece is fine; we need to play with the second.

20

t2
t1
L * qÝk 
 k
dt 
qÝ  

t2
t1
L * d qk 
 k  dt
qÝ dt  
I do my integration by parts trick again


t2
t1
L * d qk 
 k  dt 
qÝ dt  

t2
t1
 d L * qk  d L *qk 
  k
  k  dt
dt qÝ   dt qÝ   
I can integrate the first part. All the paths hit the end points, and the integral is zero.

q k
q  q  


k

k
0

 

  0 
q k
 q k  0

21
so I have
dI
0
d

t2
t1
L * d L * q k
dt 
 k   k 
Ý
dt q  
q

t2
t1
L * d L * k
 k   k q dt
dt qÝ 
q
and this gives us the Euler-Lagrange equations

No matter how we look at it, we have a governing system
 d  L  L  k
k
  k  k q  Qkq
dt qÝ  q 

22
from a governing integral

t2
t1

L d  L  k
Qk  k   k q dt
q dt qÝ 

We get the Euler-Lagrange equations if the qk are independent

We will have issues regarding independence
and solutions for them.
We will have issues regarding the generalized forces
and we’ll develop techniques for finding them.
23
??
24
A special kind of friction: “viscous” friction, damper/dashpot
friction force  cyÝ

damping constant
y
25
We can get the force by differentiating something called
the Rayleigh dissipation function
1
F   ijqÝiqÝj
2
note double summation
the coefficients are the most general
they will usually be much simpler
The (unconstrained) Euler-Lagrange equations become

d  L  F
L


 Qk
 k 
k
k
dt qÝ  qÝ q
where Qk no longer includes the friction forces

26
I’d like to put all this together in some sort of procedure.
We can look at some mechanical systems that can be viewed as
collections of point masses
??
OK. Away we go . . .
27
The Euler-Lagrange process
1. Find T and V as easily as you can
2. Apply geometric constraints to get to N coordinates
3. Assign generalized coordinates
4. Define the Lagrangian
28
5. Differentiate the Lagrangian with respect to the
derivative of the first generalized coordinate
6. Differentiate that result with respect to time

7. Differentiate the Lagrangian
with respect to the same generalized coordinate

8. Subtract that and set the result equal to Q1
L
qÝ1
d L 
 
dt qÝ1 
L
q1
d L  L
 dt qÝ1  q1  Q1
 
Repeat until you have done all the coordinates

29
OVERHEAD CRANE
(start without the generalized forces)
y1  q1, q  q 2
y1, f1
M
Steps 1-4 lead us to

T
1
1 2 22
12
Ý
M

m
q

ml qÝ  mlqÝ1qÝ2 cosq2


2
2
V  mglcosq
2
q
m
1
1 2 22
12
L  M  mqÝ  ml qÝ  mlqÝ1qÝ2 cosq2  mglcosq2
2
2
(y2, z2)
30
For q1
L
2
2
1
1
M  mqÝ1  ml2qÝ2  mlqÝ1qÝ2 cosq2  mglcosq2
2
2
L
5.  1  M  mqÝ1  mlqÝ1 cosq1
qÝ
6.
d L 
1
1 2
22
Ý
Ý
Ý
Ý
Ý

M

m
q

mlcosq
q

ml
q
sin q 2

 1  
dt qÝ
7.

8.
L
0
1
q
d L  L
1
2 2
22
2
Ý
Ý
Ý
Ý
Ý


M

m
q

mlcosq
q

ml
q
sin
q
0


 1 
1
dt qÝ q
31
For q2
L
2
2
1
1
M  mqÝ1  ml2qÝ2  mlqÝ1qÝ2 cosq2  mglcosq2
2
2
5.
L
2 2
1
2
Ý
Ý

ml
q

ml
q
cosq

qÝ2
6.
d  L 
2 2
Ý  mlqÝ
Ý1 cosq 2  mlqÝ1qÝ2 sin q 2
 2  ml qÝ
dt qÝ 
7.
L
1 2
2
2
Ý
Ý

ml
q
q
sin
q

mglsin
q
q 2
8.
d  L  L
2 2
Ý  mlqÝ
Ý1 cosq 2  mlqÝ1qÝ2 sin q 2  mlqÝ1qÝ2  mglsin q2  0
 2  2  ml qÝ
dt qÝ  q
32
The governing equations are then
Ý1  mlcosq 2qÝ
Ý2  mlqÝ2 sin q 2  0
8a. M  mqÝ
2
1
Ý2  mlqÝ
Ý
8b. ml2qÝ
cosq2  mlqÝ1qÝ2 sin q2  mlqÝ1qÝ2  mglsin q2  0

Put the physical variables back so it looks more familiar

Ý
Ý mlq
Ý2 sin q  0
Ý
8a. M  myÝ

mlcos
q
q
1


Ý
Ý mlyÝ
Ýsin q  mlyÝq
Ý mgl sin q  0
Ýcosq  mlyÝq
8b. ml2q


This is all without forcing or damping — let’s add those
33
OVERHEAD CRANE
(with forces)
If y1 changes, f1 does work
Q1 = f 1
add a torque, t1
y1, f1
M
If q changes, f1 does no work
Q2 = 0
If q changes, t1 does work
Q2 = t 1
q
If y1 changes, t1 does no work
Q1 does not change
m
(y2, z2)
34
The governing equations were
Ý
Ý mlq
Ý2 sin q  0
8a. M  mÝ
yÝ mlcosqq


Ý
Ý mlÝ
Ýsin q  mlyÝq
Ý mgl sin q  0
8b. ml2q
yÝcosq  mlyÝq


We added the generalized forces
Ý
Ý mlq
Ý2 sin q  Q  f
8a. M  mÝ
yÝ mlcosqq
1
1


Ý
Ý mlyÝ
Ýsin q  mlyÝq
Ý mgl sin q  Q  t
Ýcosq  mlyÝq
8b. ml2q
2
1


Now we need the Rayleigh dissipation function
35
The damper works when the angle changes, but not when the cart moves
So, the Rayleigh dissipation function for this problem is
1 Ý2
F  cq
2
ŽF
ŽF
Ý
 0,

c
q
Ý
Ž yÝ
Žq

Ý
Ý mlq
Ý2 sin q  f
Ý mlcosqq
8a. M  myÝ
1

Ý
Ý mlÝ
Ýsin q  mlyÝq
Ý mgl sin q  cq
Ý t
8b. ml2q
yÝcosq  mlyÝq
1




36
We aren’t really up to discussing solving these problems,
but let me say a few things that we will revisit.
M  myÝÝ mlcosqqÝÝ mlqÝ2 sin q  f1


Ý
Ý mlyÝ
Ýsin q  mlyÝq
Ý mgl sin q  cq
Ý t
Ýcosq  mlyÝq
ml2q
1

a pair of coupled second order ordinary differential equations

It would be nice to have first order equations
There are lots of ways to do this, and we’ll look at many of them
but the simplest is to let qÝi  u i

37
Then we’ll have
qÝ1  u1
qÝ2  u 2
M  m
uÝ1  mlcosq 2 uÝ2  mlu 2
2
sin q 2  f1
mlcosquÝ1  ml2uÝ2 mlu1u2 sin q1  mlu1u2  mglsin q2  cu2  t1

If you supply a force, a torque and initial conditions
you can solve this set numerically.
38
You can solve for the variables, which I won’t do because it is pretty messy,
and you’ll wind up with
q1   u1 
 2   2 
d q   u 
 1  
3 
dt u  rhs 
4
2


rhs


u 
 



Later on we’ll learn to call this a state vector
39
Download