Arrow

Visualizing an arrow with variable size

    Arrow

Library

Modelica/Mechanics/MultiBody/Visualizers/Advanced

Description

Model Arrow defines an arrow that is dynamicallyvisualized at the defined location (see variables below).If you want an arrow representing something that is not a relative position, useVector instead.

model Visualizers.Advanced.Arrow

The dialog variables R, r, r_tail, r_head, color,specularCoefficient, and headAtOriginare declared as (time varying) input variables.If the default equation is not appropriate, a correspondingmodifier equation has to be provided in themodel where an Arrow instance is used, e.g., in the form

Visualizers.Advanced.Arrow arrow(r_head = {sin(time),cos(time},0});

Variable color is an Integer vector with 3 elements,{r, g, b}, and specifies the color of the shape.{r, g, b} are the "red", "green" and "blue" color parts.Note, r, g and b are given in the range 0 … 255.The predefined typeMultiBody.Types.Colorcontains a menu definition of the colors used in the MultiBodylibrary together with a color editor.

Parameters

Arrow_0

NameLabelDescriptionData TypeValid Values

mo_R

R

Orientation object to rotate the world frame into the arrow frame

FromModelica('Modelica.Mechanics.MultiBody.Frames.Orientation')

mo_r

r

Position vector from origin of world frame to origin of arrow frame, resolved in world frame

Vector of size 3

mo_r_tail

r_tail

Position vector from origin of arrow frame to arrow tail, resolved in arrow frame

Vector of size 3

mo_r_head

r_head

Vector from arrow tail to the head of the arrow, resolved in arrow frame

Vector of size 3

mo_color

color

Color of arrow

Vector of size 3

mo_specularCoefficient

specularCoefficient

Material property describing the reflecting of ambient light (= 0 means, that light is completely absorbed)

Scalar

mo_headAtOrigin

headAtOrigin

= true, if the vector is pointing towards the origin of vector frame

Scalar

true
false

mo_quantity

quantity

Kind of physical quantity represented by the vector

Structure

mo_quantity/choice1

Modelica.Mechanics.MultiBody.Types.VectorQuantity.Force

Number

0
1

mo_quantity/choice2

Modelica.Mechanics.MultiBody.Types.VectorQuantity.Torque

Number

0
1

mo_quantity/choice3

Modelica.Mechanics.MultiBody.Types.VectorQuantity.Velocity

Number

0
1

mo_quantity/choice4

Modelica.Mechanics.MultiBody.Types.VectorQuantity.Acceleration

Number

0
1

mo_quantity/choice5

Modelica.Mechanics.MultiBody.Types.VectorQuantity.AngularVelocity

Number

0
1

mo_quantity/choice6

Modelica.Mechanics.MultiBody.Types.VectorQuantity.AngularAcceleration

Number

0
1

mo_quantity/choice7

Modelica.Mechanics.MultiBody.Types.VectorQuantity.RelativePosition

Number

0
1

Arrow_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

'rvisobj'

mo__modifiers/attribute

Attribute

Cell of strings

'start'
'fixed'

mo__modifiers/value

Value

See Also