Go Back   Forums > Professional Forum > AnyGait


Thread Tools Display Modes
Old 01-09-2017, 07:47 AM
tjwjdal tjwjdal is offline
Junior Member
Join Date: May 2016
Posts: 20
Default about application point of GRF


Now, I am using Mocap model, and GRF data of C3D file.
And I would like to ask the following questions about the application point of force of that.

The code for inputting force at ForcePlateType2AutoDetection Function is shown below.
(C: \ Program Files \ AnyBody Technology \ AnyBody.6.0 \ AMMR \ Body \ AAUHuman \ ToolBox \ Mocap)
#if FootPresent

AnyFolder PlateFootReactions={
AnySeg &ref1=..ForcePlate;
AnySeg &ref2=..Limb2;
AnyMuscleModel &MusMdl=.InContactMuscle;
#include "ArtificialMuscleConnection.any"

At this time, the Force is inputted at segment. Is the application point of the force the center of the segment?

Looking at C3D raw data, the position of the CoP is not fixed.
However, the CoP ball in the Model View is fixed at the center point of the force plate.
How can I modify this?
The Cop ball code of ForcePlateType2AutoDetection function is as follows.

AnyFolder CenterOfPressure =
AnyForceMomentMeasure2 NetEffectMeasure =
AnyRefFrame& ref = ..ForcePlate;
AnyForceBase& Forces = ..Force;
AnyForceBase& Moments = ..Moment;

AnyVec3 Flocal = F*ref.Axes;
AnyVec3 Mlocal = M*ref.Axes;

AnyVar fx = NetEffectMeasure.Flocal[0];
AnyVar fy = NetEffectMeasure.Flocal[1];
AnyVar fz = NetEffectMeasure.Flocal[2];
AnyVar mx = NetEffectMeasure.Mlocal[0];
AnyVar my = NetEffectMeasure.Mlocal[1];
AnyVar mz = NetEffectMeasure.Mlocal[2];

AnyVar fzz =iffun(gtfun( (fz^2)^0.5,0),fz,fz+1000000);

AnyVar Vx= -my/fzz;
AnyVar Vy= mx/fzz;
AnyVar Vz= 0;

AnyVar OnOff=.OnOff;

AnyRefFrame& ref_ForcePlate = .ForcePlate;
ref_ForcePlate =
AnyDrawSphere COP_ball =
RGB = {0,1,0};
ScaleXYZ = 0.015 *{1,1,1};
//Opacity = iffun(gtfun(..fz, -10.0), 0.0, 1.0);
Opacity = ..OnOff;
Position = {..Vx, ..Vy, ..Vz};

AnyDrawLine Line =
p0 = {.Vx, .Vy, .Vz};
p1 = p0+0.004*.OnOff*{.fx, .fy, .fz};
Visible = ..Switch_DrawForceVectorFromCOP ;
AnyRefFrame &ref = ..ForcePlate;

Line.RGB ={0,0,1};
Line.Thickness = 0.01;
Line.End.Thickness = 2*0.01;
Line.End.Length = 4*0.01;

I'm looking forward to any reply.
Thank you.
Reply With Quote
Old 01-16-2017, 05:11 PM
toerholm's Avatar
toerholm toerholm is offline
AnyBody Support
Join Date: Feb 2009
Posts: 940


I think you might not need to alter the forceplate class.

Please verify that you are using the right type of forceplate which corresponds with the way the data are stored in the C3D file.

To do that please check the forceplateform type setting, in your C3D file data, and then selected the forceplate class in the script which fits. If these are not matching you may encounter problems like yopu describe.

Please do the following:
  1. identify the forceplate type in your data ... so browse the modeltree and find something like this Main.ModelSetup.C3DFileData.Groups.Force_plate.Typ e
  2. this will contain a vector of integers so eg ={3,3,3} meaning that the file has three forceplates of type 3. (read more about different type at
  3. Then select the correct AnyScript class associated with type, we have the most common premade. see folder Bosy/Tools/mocap

Hope it helps

Best regards
TIP: How to save and load results. play_Results

Subscribe to the forums, click the 'Forum Tools' link above the list of threads then select 'Subscribe to Forum'. You will then have the option to choose the subscription mode for this forum and get an email automatically.
Reply With Quote

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

All times are GMT +2. The time now is 02:17 AM.