Forums Anyscript.org  

Go Back   Forums Anyscript.org > Professional Forum > AnyBody Managed Model Repository

Notices

Reply
 
Thread Tools Display Modes
  #1  
Old 06-17-2018, 12:30 PM
xunxiangerluo xunxiangerluo is offline
Junior Member
 
Join Date: Mar 2014
Posts: 9
Default Access force at the specific motion angle during the parameter study

Hi,
I am studying the parameter study on the cervical spine. I tried to output the joint force at the specific motion angle, for example 1 degree. However, the value outputed by the AnyDesMeasure was the force at the end time. I found someone use the function argmin to realize the index of the minimum value in the previous thread. But I not only want to find the minimum, the force at specific angle (1°,2°,3°,4°...) could be outputed.
Code:
 
 AnyBodyStudy Study = {
AnyOutputFun Force = {
      Val = .Model.HumanModel.Trunk.JointsCervicalSpine.C5C4Jnt.Constraints.Reaction.Fout[0];
    };
AnyOutputFun Angle = {
      Val = .Model.HumanModel.Trunk.JointsCervicalSpine.C5C4Jnt.Pos[0];
    };
  }; 
AnyParamStudy ParamStudy = {
AnyDesMeasure C5C4JntForce = {
      Val = ???..Study.Force();// the force at the specific C5C4Jnt angle
    };
};
Thank you in advance.
Reply With Quote
  #2  
Old 06-20-2018, 11:59 AM
mkjung9980's Avatar
mkjung9980 mkjung9980 is offline
Senior Member
 
Join Date: Aug 2009
Posts: 886
Default

Hi,

1) I would assume that you've seen our tutorial chapter for parameter studies:
https://anyscript.org/tutorials/Para...n/lesson1.html

2) Based on your code, it can be utilized like this:
Code:
 AnyBodyStudy Study = {
  AnyOutputFun Force = {
    Val = .Model.HumanModel.Trunk.JointsCervicalSpine.C5C4Jnt.Constraints.Reaction.Fout[0];
  };
  AnyOutputFun Angle = {
    Val = .Model.HumanModel.Trunk.JointsCervicalSpine.C5C4Jnt.Pos[0];
  };
}; 
AnyParamStudy ParamStudy = 
{
  AnyDesMeasure C5C4JntForce = 
  {
    Val = min(..Study.Force());
  };
};
But you need to define your own AnyDesVar objects inside your AnyParamStudy class instance.

3) But if you want to have the full history of the force at a specific parameter for your parameter studies,
it may be better to use external tool to test different parameters and hold all results for all different parameters.
I would recommend you to use AnyPyTools here:
https://anybody-research-group.githu...ocs/index.html

I hope that this may be helpful to you.

Best regards,
Moonki
__________________

Moon Ki Jung, Ph.D, Application Engineer, AnyBody Technology A/S.

※ AnyScript™ Reference Manual is the bible.
※ AnyScript™ wiki page is the best supplementary information(http://wiki.anyscript.org).
※ When you would upload your models, please write information about your AMS and AMMR versions.
※ If you want to get more intensive support, please update your information(profile, organization and signature).
Reply With Quote
Reply

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 10:08 PM.