Generalized coordinates and constraints
Basilio Bona
DAUIN – Politecnico di Torino
Semester 1, 2016-17
B. Bona (DAUIN) Generalized coordinates and constraints Semester 1, 2016-17 1 / 25 Coordinates
Each rigid body is defined by 6 coordinates (called d.o.f. or dof), 3 for the position χ, 3 for the orientation α of a body frame RB attached to it; the position and orientation stacked together are called the posep of the body. p1(t) x1(t) p (t) x (t) 2 2 def x(t) p (t) x (t) p(t) = = 3 = 3 p (t) (t) α(t) 4 α1 p5(t) α2(t) p6(t) α3(t)
A multibody system is a composition of several rigid bodies connected to each other and satisfying some physical or geometrical constraints.
B. Bona (DAUIN) Generalized coordinates and constraints Semester 1, 2016-17 2 / 25 Coordinates A discrete (or “atomic”) rigid body B is composed by a finite set of N geometrical points Pi , each one defined in the 3D space by its position vector with reference to some reference frame (usually the body frame)
"xi1(t)# xi (t) = xi2(t) i = 1,...,N xi3(t) The body B is globally characterized by M = 3N quantities.
x11(t) x12(t) x13(t) χ1(t) x1(t) . . . χ2(t) . . . xk1(t) . . M χ(t) = xk (t) = xk2(t) = ∈ X ⊆ R X = configuration space . χj (t) . xk3(t) . . . . . . xN (t) . χM (t) xN1(t) xN2(t) xN3(t)
B. Bona (DAUIN) Generalized coordinates and constraints Semester 1, 2016-17 3 / 25 Coordinates
We can express the χi coordinates in many different ways; between the two representations we can define a transformation χ0 = f(χ).
The transformation f(·) must be non singular almost everywhere, i.e., the ∂fi transformation jacobian must be full rank ∀χj , with a possible ∂ χj exception of a countable set of configurations.
B. Bona (DAUIN) Generalized coordinates and constraints Semester 1, 2016-17 4 / 25 Coordinates
Example T Consider a point P described by cartesian coordinates x = x1 x2 x3 0 0 0 0 T or by polar/spherical coordinates x = x1 x2 x3 , where
x1 = x x2 = y x3 = z 0 0 0 x1 = ρ x2 = θ x3 = φ In this case the transformations between x0 and x are defined as follows q x = x0 sinx0 cosx0 x0 = x2 + x2 + x2 1 1 2 3 1 1 2 3 0 0 0 −1 q f : x2 = x1 sinx2 sinx3 f : 0 2 2 x2 = arctan( (x1 + x2 )/x3) 0 0 x3 = x1 cosx2 0 x3 = arctan(x2/x1)
B. Bona (DAUIN) Generalized coordinates and constraints Semester 1, 2016-17 5 / 25 Coordinates
The Jacobian Jx of the transformation f is 0 0 0 0 0 0 sinx2 cosx3 ρ cosx2 cosx3 −ρ sinx2 sinx3 sinx0 sinx0 cosx0 sinx0 sinx0 cosx0 Jx = 2 3 ρ 2 3 ρ 2 3 0 0 cosx2 −ρ sinx2 0 with the determinant 2 0 detJx = ρ sinx2 0 If ρ 6= 0 the determinant goes to zero only for θ = x2 = 0 ± 2kπ; this configuration is called a singular configuration. For example, the spherical coordinates are useful to model a satellite orbit motion around Earth.
B. Bona (DAUIN) Generalized coordinates and constraints Semester 1, 2016-17 6 / 25 Constraints
In general, kinematic constraints active on the body elements are defined by implicit function of the M = 3N coordinates, and possibly also of time t, as: ψ(χ1,..., χ3N ,t) = 0
If the constraint are nc , a system of nc equalities arises
ψ1(χ1,..., χ3N ,t) = 0
ψ2(χ1,..., χ3N ,t) = 0 . .
ψnc (χ1,..., χ3N ,t) = 0 that is equivalent to the following matrix equation
Ψ(χ(t),t) = 0.
where Ψ is a nc × 1 matrix containing the nonlinear functions of the coordinates.
B. Bona (DAUIN) Generalized coordinates and constraints Semester 1, 2016-17 7 / 25 Constraints
It is also possible to write constraints involving the time derivative χ˙ (t)
Ψ0(χ(t), χ˙ (t),t) = 0.
and, in general, some constraints can be expressed as inequalities
Ψ00(χ(t), χ˙ (t),t) ≤ 0.
A direct time dependency is present when some constraints are varying according to an external time law, otherwise the constraints depend from time only through the coordinates χi (t). The various types of constraints can be written as: a) Ψ(χ(t),t) = 0 b) Ψ0(χ(t), χ˙ (t),t) = 0 c) Ψ00(χ(t), χ˙ (t),t) ≤ 0 The constraints that directly depend on time are called rheonomic, while the time-independent ones are called sclerononomic.
B. Bona (DAUIN) Generalized coordinates and constraints Semester 1, 2016-17 8 / 25 Constraints - An example
Example
The rigid system is composed by N = 4 point masses, with
T T T x1 = 0 0 0 x2 = 1 0 0 x3 = 0 1 0 x4 = 0 0 1
B. Bona (DAUIN) Generalized coordinates and constraints Semester 1, 2016-17 9 / 25 Constraints - An example
The rigid constraints are expressed as
T 2 T 2 (x1 − x2) (x1 − x2) − d12 = 0 (x1 − x3) (x1 − x3) − d13 = 0 T 2 T 2 (x1 − x4) (x1 − x4) − d14 = 0 (x2 − x3) (x2 − x3) − d23 = 0 T 2 T 2 (x2 − x4) (x2 − x4) − d24 = 0 (x3 − x4) (x3 − x4) − d34 = 0
where dij is the distance between the point masses. There are 3N = 12 configuration variables and N(N − 1)/2 = 6 constraint equations, all independent.
The three oriented segments xi − x1 form a basis of mutually orthogonal vectors, and are the ideal representation of a cartesian reference frame, the most simple example of a rigid body.
The system has therefore only 3N − nv = 12 − 6 = 6 free parameter; this number is the maximum number of dof of a rigid body in space.
B. Bona (DAUIN) Generalized coordinates and constraints Semester 1, 2016-17 10 / 25 Generalized Coordinates
From now on, we assume that all nc constraints are independent. The implicit function theorem guarantees that it is always possible to express nc variables as functions of the n = M − nc remaining ones.
We can therefore identify n = M − nc independent variables q1, q2,..., qn. These variables are called generalized coordinates
q1(t) . q(t) = . ∈ Q qn(t)
They univocally represent the motion of a multibody system, implicitly taking into account the kinematic constraints acting on the system.
All the other nc configuration variables can be computed from them, using the constraint equations.
B. Bona (DAUIN) Generalized coordinates and constraints Semester 1, 2016-17 11 / 25 Generalized Coordinates
The set of independent generalized coordinates is not unique: many other sets of coordinates may represent the system motion. The set must be
independent (no generalized coordinates qi shall exist that can be obtained as linear combinations of other generalized coordinates) complete (the motion of the constrained set is completely determined by the generalized coordinates included in the set) If the set is complete and independent, it is also minimal. The number n defines the dimension of the generalized coordinate space Q.
B. Bona (DAUIN) Generalized coordinates and constraints Semester 1, 2016-17 12 / 25 Generalized Coordinates
It is always possible to express each position vector xi , with i = 1,...,M, as a function of the n generalized coordinates
xi = hi (q1,q2,...,qn,t) = hi (q(t),t)
where hi is a generic nonlinear vector function, whose derivatives with respect to its arguments exist up at least to the second order. Similarly, if we consider the configuration variables χ, we can set the following transformation between q and χ:
χ = g(q1,q2,...,qn,t) = g(q(t),t)
B. Bona (DAUIN) Generalized coordinates and constraints Semester 1, 2016-17 13 / 25 Generalized velocities
The generalized velocities are defined as
dq(t) T q˙ (t) = = q˙1(t) ... q˙n(t) dt The configuration velocities χ˙ are defined as
dχ(t) T χ˙ (t) = = χ˙1(t) ... χ˙ (t) dt M with M = 3N.
B. Bona (DAUIN) Generalized coordinates and constraints Semester 1, 2016-17 14 / 25 Generalized velocities and accelerations
The relation between χ˙ and q˙ is
χ˙ (t) = J(t)q˙ (t) + b(t)
M×n M×1 where J ∈ R and b ∈ R are defined as
∂fi (t) ∂fi (t) [J]ij = [b]i = ∂qj (t) ∂t
J is called the transformation Jacobian; b is non zero only if χ directly depends from time. The generalized accelerations are
χ¨(t) = J(t)q¨(t) + J˙(t)q˙ (t) + b˙ (t)
B. Bona (DAUIN) Generalized coordinates and constraints Semester 1, 2016-17 15 / 25 Generalized constraints
The constraints obtained considering the generalized coordinates and velocities are called generalized constraints. If the constraints depend directly on time they are written as
Φ(q(t),q˙ (t),t) = 0 or Φ(q(t),q˙ (t),t) ≤ 0
If they do not depend directly on time they are written as
Φ(q(t),q˙ (t)) = 0 or Φ(q(t),q˙ (t)) ≤ 0
B. Bona (DAUIN) Generalized coordinates and constraints Semester 1, 2016-17 16 / 25 Virtual Displacements and Constraints
Virtual displacements or admissible variations δr are a small (i.e., virtual, not real) displacements of body points, allowed by the kinematic constraints. Virtual displacements can take place independently from time, i.e., are not subject to the law of physics. We assume δt ≡ 0.
For every generalized coordinate qi there is a virtual displacement δqi .
The number ndof of independent and complete virtual displacements δqi defines the degrees-of-freedom of the multibody system. Usually the number n of independent and complete generalized coordinates qi is equal to the degrees-of-freedom n = ndof. However, this is not always the case, and depends on the type of constraints; when the constraints are non-holonomic ndof < n. The term holonomic come from the Greek oλoς and means integer, integrable.
B. Bona (DAUIN) Generalized coordinates and constraints Semester 1, 2016-17 17 / 25 Non-holonomic constraints
Let us consider first the equality constraints, and, in particular, those that depend only on the positions
Φ(q(t),t) = 0
The equality constraints that depend only on the positions are always holonomic constraints. Non-holonomic constraints belong to two classes of constraints: Inequality constraints:
Φ0(q(t),q˙ (t),t) ≤ 0
Equality constraints that depend also on velocities:
Φ00(q(t),q˙ (t),t) = 0
but are not exactly integrable.
B. Bona (DAUIN) Generalized coordinates and constraints Semester 1, 2016-17 18 / 25 Non-holonomic constraints
For simplicity and without loss of generality, we restrict our attention to the constraints that depend only on the generalized velocities,
Φ00(q˙ (t),t) = 0
When these differential equations do not provide an exact integral, they represent non-holonomic constraints.
B. Bona (DAUIN) Generalized coordinates and constraints Semester 1, 2016-17 19 / 25 Non-holonomic constraints
Take a generic i-th holonomic constraint φi (q(t),t) = 0, and derive it with respect to time to obtain the corresponding constraint expressed as a function of the velocities d φ (q(t),t) = 0 ⇔ φ 00(q˙ (t),t) = 0 ⇔ a(q)Tq˙ + b(q) = 0 dt i i where ∂φi (t) ∂q1(t) . ∂φi (t) a(q) = . b(q) = . ∂t ∂φi (t) ∂qn(t) 00 The two constraints φi (q(t),t) = 0 and φi (q˙ (t),t) = 0 are equivalent, 00 since φi can be obtained integrating φi .
B. Bona (DAUIN) Generalized coordinates and constraints Semester 1, 2016-17 20 / 25 Non-holonomic constraints
The constraint written in differential form:
a(q)Tdq + b(q)dt = 0
represents the so-called Pfaffian form.
If the Pfaffian form is integrable, i.e., if it represent an exact differential, it can substituted by its integral: in this case the constraint is holonomic.
If on the contrary the Pfaffian form is not an exact differential, it cannot be integrated and the corresponding constraint is non-holonomic.
B. Bona (DAUIN) Generalized coordinates and constraints Semester 1, 2016-17 21 / 25 Exact differentials
Given the differential form
dφ = a(q)Tdq
n R it is an exact form in R if dφ does not depend on the integration path. This is true when dφ = (∇φ)Tdq where ∂φ ∂φ (∇φ)T = (grad φ)T = ··· ∂q1 ∂qn Therefore the coefficients a(q) must satisfy the relation
∂φ ai (q) = , i = 1,...,n ∂qi
B. Bona (DAUIN) Generalized coordinates and constraints Semester 1, 2016-17 22 / 25 Exact differential form
These identities between the second partial derivatives hold
∂ 2φ ∂ 2φ = , ∀i,j = 1,...,n ∂qj qi ∂qi qj and this implies
∂a (q) ∂a (q) i = j , ∀i,∀j = 1,...,n ∂qj ∂qi
If the coefficients ai ’s satisfy all the above relations, the differential form is integrable and the constraint is holonomic. Otherwise the form is not exactly integrable and the constraint is non-holonomic. From a physical point of view, the classical examples are those of a wheel rolling on a plane without slippage between wheel and plane at the contact point, or certain kind of sliding object, such as the ice skates.
B. Bona (DAUIN) Generalized coordinates and constraints Semester 1, 2016-17 23 / 25 Virtual work
Virtual displacements are important for the definition of the virtual work δW . Given a system consisting of N point masses, each defined by a position vector ri , on which acts a system of N forces fi , applied on the system and having their application point in ri , the virtual work δW is defined as:
N N T δW = ∑ fi · δri ≡ ∑ fi δri i=1 i=1 The system is said to be in static/dynamic equilibrium if the virtual work of the static/dynamic forces is zero, i.e., if
N δW = ∑ fi · δri = 0 i=1
B. Bona (DAUIN) Generalized coordinates and constraints Semester 1, 2016-17 24 / 25 Virtual work
If both Nf linear forces and Nτ rotational moments act on the system, it is necessary to distinguish the relative contributions, as follows
Nf Nτ δW = ∑ fi · δri + ∑ τi · δαi = 0 i=1 i=1
where now we have introduced the moments τi and the virtual angular displacements δαi .
B. Bona (DAUIN) Generalized coordinates and constraints Semester 1, 2016-17 25 / 25