gravityAcceleration

Function to compute the gravity acceleration, resolved in world frame

Information

This information is part of the Modelica Standard Library maintained by the Modelica Association.

Replaceable function to define the gravity field. Default is function standardGravityAcceleration that provides some simple gravity fields (no gravity, constant parallel gravity field, point gravity field). By redeclaring this function, any type of gravity field can be defined, see example Examples.Elementary.UserDefinedGravityField.

Syntax

gravity = gravityAcceleration(r, gravityType, g, mue)

Inputs (4)

r

Type: Position[3] (m)

Description: Position vector from world frame to actual point, resolved in world frame

gravityType

Default Value: gravityType

Type: GravityTypes

Description: Type of gravity field

g

Default Value: g * Modelica.Math.Vectors.normalizeWithAssert(n)

Type: Acceleration[3] (m/s²)

Description: Constant gravity acceleration, resolved in world frame, if gravityType=UniformGravity

mue

Default Value: mue

Type: Real (m³/s²)

Description: Field constant of point gravity field, if gravityType=PointGravity

Outputs (1)

gravity

Type: Acceleration[3] (m/s²)

Description: Gravity acceleration at position r, resolved in world frame