RelativeVelocity

Measure relative velocity vector between the origins of two frame connectors

    RelativeVelocity

Library

Modelica/Mechanics/MultiBody/Sensors

Description

The relative velocity vector between the origins of frame_a and of frame_b aredetermined and provided at the output signal connector v_rel.This vector is defined as:

r_rel = MultiBody.Frames.resolve2(frame_a.R, frame_b.r_0 - frame_a.r_0);v_rel = der(r_rel);

Via parameter resolveInFrame it is defined, in which framethe velocity vector is resolved:

resolveInFrame =
Types.ResolveInFrameAB.
Meaning
world Resolve vector in world frame
frame_a Resolve vector in frame_a
frame_b Resolve vector in frame_b
frame_resolve Resolve vector in frame_resolve

If resolveInFrame = Types.ResolveInFrameAB.frame_resolve, the conditional connector"frame_resolve" is enabled and v_rel is resolved in the frame, towhich frame_resolve is connected. Note, if this connector is enabled, it mustbe connected.

Example

If resolveInFrame = Types.ResolveInFrameAB.frame_b, the output vector iscomputed as:

r_rel   = MultiBody.Frames.resolve2(frame_a.R, frame_b.r_0 - frame_a.r_0);v_rel_a = der(r_rel);v_rel   = MultiBody.Frames.resolveRelative(frame_a.R, frame_b.R, v_rel_a);

Parameters

RelativeVelocity_0

NameLabelDescriptionData TypeValid Values

mo_resolveInFrame

resolveInFrame

Frame in which output vector v_rel shall be resolved (world, frame_a, frame_b, or frame_resolve)

Structure

mo_resolveInFrame/choice1

Resolve in world frame

Number

0
1

mo_resolveInFrame/choice2

Resolve in frame_a

Number

0
1

mo_resolveInFrame/choice3

Resolve in frame_b

Number

0
1

mo_resolveInFrame/choice4

Resolve in frame_resolve (frame_resolve must be connected)

Number

0
1

RelativeVelocity_1

NameLabelDescriptionData TypeValid Values

mo__nmodifiers

Number of Modifiers

Specifies the number of modifiers

Number

mo__modifiers

Modifiers

Add new modifier

Structure

mo__modifiers/varname

Variable name

Cell of strings

mo__modifiers/attribute

Attribute

Cell of strings

'start'
'fixed'

mo__modifiers/value

Value

Ports

NameTypeDescriptionIO TypeNumber

frame_a

implicit

Coordinate system a

input

1

frame_b

implicit

Coordinate system b

output

1

v_rel

implicit

Relative velocity vector resolved in frame defined by resolveInFrame

output

2

Port 4

implicit

Coordinate system in which v_rel is optionally resolved

output

mo_resolveInFrame.choice4

See Also