User Tools

Site Tools


visual3d:documentation:pipeline:model_based_data_commands:angular_momentum_pt

Angular Momentum about a Point

This example demonstrates how to calculate the angular momentum of a segment about an arbitrary point.

Note: It is very important to note that the total body angular momentum is not calculated by summing the ANGULAR_MOMENTUM for each segment because this model-based item represents the angular momentum of each segment about its own centre of mass. To calculate the total body angular momentum you must calculate the angular momentum for each segment about the same axis, such as the total body center of mass. The equations in the About Total Body Center of Mass section describe how to do this.

Calculating Angular Momentum

Visual3D's built in ANGULAR_MOMENTUM command calculates the angular momentum of a segment about the segment's center of mass, but angular momentum can also be calculated about a different point in space.

About a Segment's Centre of Mass

A segment's angular momentum about its own centre of mass is calculated as:

segmentangularmomentumexpression.jpg

where

I = Moment of Inertia
w = Angular velocity

About Total Body Center of Mass

A segment's angular momentum about the total body's centre of mass is calculated as:

where

Iw = angular momentum of the segment
r = distance from the segment's centre of mass to the total body centre of mass
m = mass of the segment
v = translational velocity

NOTE: In this case angular momentum for the whole body about the total body center of mass is simply the summation of the angular momentum of each segment about the total body center of mass.

Example

This example script demonstrates how to calculate a segment's angular momentum about a point, such as the model centre of mass, by the following steps:

  1. Compute r
  2. Compute mv
  3. Compute r x mv
  4. Compute the angular momentum of the segment using the Angular Momentum command
  5. Compute Iw x (r x mv)

Files

This script and sample CMO files can be downloaded here. The download also contains a PDF file with the Angular Momentum equations.

Script

First_Derivative
/SIGNAL_TYPES=KINETIC_KINEMATIC
/SIGNAL_FOLDER=Model
/SIGNAL_NAMES=CenterOfMass
/RESULT_TYPES=DERIVED
/RESULT_FOLDER=COM
! /RESULT_NAMES=
/RESULT_SUFFIX=_VEL
;

! Nested Loops
! Outer Loop gets an active segment
For_Each
/ITERATION_PARAMETER_NAME=SEG_NAME
/ITEMS=RFT+RSK+RTH+LFT+LSK+LTH+RPV
;

! compute the r for (r x mv)
Evaluate_Expression
/EXPRESSION=vector((Kinetic_Kinematic::&::SEG_NAME&:&:CGPos::X - KINETIC_KINEMATIC::MODEL::CenterOfMass::X ), (Kinetic_Kinematic::&::SEG_NAME&:&:CGPos::Y - KINETIC_KINEMATIC::MODEL::CenterOfMass::Y), (Kinetic_Kinematic::&::SEG_NAME&:&:CGPos::Z - KINETIC_KINEMATIC::MODEL::CenterOfMass::Z))
/RESULT_NAME=::SEG_NAME&_R 
! /RESULT_TYPE=DERIVED
! /RESULT_FOLDER=PROCESSED
;

! compute mv
Evaluate_Expression
/EXPRESSION=(MODEL::SEGMENT::&::SEG_NAME&:&:MASS)*(Kinetic_Kinematic::&::SEG_NAME&:&:CGVel - DERIVED::COM::CENTEROFMASS_VEL)
/RESULT_NAME=::SEG_NAME&_mv
! /RESULT_TYPE=DERIVED
! /RESULT_FOLDER=PROCESSED
;

! compute r x mv
Evaluate_Expression
/EXPRESSION=cross(DERIVED::PROCESSED::&::SEG_NAME&_R, DERIVED::PROCESSED::&::SEG_NAME&_mv)
/RESULT_NAME=::SEG_NAME&_rxmv
! /RESULT_TYPE=DERIVED
! /RESULT_FOLDER=PROCESSED
;

! compute Iw
Compute_Model_Based_Data
/RESULT_NAME=::SEG_NAME&_IW
/FUNCTION=ANGULAR_MOMENTUM
/SEGMENT=::SEG_NAME
/REFERENCE_SEGMENT=LAB
! /RESOLUTION_COORDINATE_SYSTEM=LAB
! /USE_CARDAN_SEQUENCE=FALSE
! /NORMALIZATION=FALSE
! /NORMALIZATION_METHOD=
! /NORMALIZATION_METRIC=
! /NEGATEX=FALSE
! /NEGATEY=FALSE
! /NEGATEZ=FALSE
! /AXIS1=X
! /AXIS2=Y
! /AXIS3=Z
;

! compute Iw x (r x mv)
Evaluate_Expression
/EXPRESSION=LINK_MODEL_BASED::ORIGINAL::&::SEG_NAME&_IW + DERIVED::PROCESSED::&::SEG_NAME&_rxmv
/RESULT_NAME=::SEG_NAME&_IW
/RESULT_TYPE=DERIVED
/RESULT_FOLDER=Momentum_Contribution
;
End_For_Each
/ITERATION_PARAMETER_NAME=SEG_NAME
;

The script:

  1. calculates the angular momentum for each of the listed segments (RFT+RSK+RTH+LFT+LSK+LTH+RPV). If the user would like to calculate the total body angular momentum about the model center of mass, the resulting signals from the last Evaluate Expression command for all segments should be summed together. If you would like to calculate the total body angular momentum, you can use the Add_Signals command after the End_For_Each.
  2. computes the angular momentum about the total body centre of mass, if the user would like to calculate angular momentum about a different point then they simply need to specify the desired signal in place of “KINETIC_KINEMATIC::MODEL::CenterOfMass”.
visual3d/documentation/pipeline/model_based_data_commands/angular_momentum_pt.txt · Last modified: by 172.204.27.30