couple of beginner questions

In the Tutorial : getting started with anyscript: lesson 2; on defining segments and displaying objects,it talks about the referencenode. How do I define the sRel vectors? If I am planning on modeling the ankle ( tibia, fibula, complete foot ) is there a way to simply import an already modeled foot from a bigger already completed model?also to make my model realistic, I am confused about when or how I am defining its length, size ( is that all done by the mass and inertial properties)
Finally, if I would like to represent my model as actual bones, I need stl files of them if I gathered correctly? Is there anywhere I can get these? I have understood I can import for example implants into the anybody model, but is it possible to do the reverse? I’m guessing, to implement my implants correctly into the anybody model is going to be quite difficult so was wondering if I can export the bone model into ProE and do it there.

Hi,

Because I was also a beginner of AnyBody before, I hope that my answers may help to you.
But my answers may be different from the official answer from AnyBody team. Also my answers may contain some wrong information.

  1. How can we set ‘sRel’ vectors for defining AnyRefNode objects in an AnySeg?
    -> To do it easy, I think that it is better for us to see the local coordinate system of the AnySeg object. To do that, use ‘AnyDrawRefFrame’ like this:
AnyDrawRefFrame DrwRefFrame=
{
	RGB = {1, 0, 0}; // Color as you want to use.
	ScaleXYZ = 0.5*{1,1,1}; // Size as you want to use.
};

Put this code in the AnySeg object that you have to investigate. Then you can see the origin and the orientation of the local coordinate system of the AnySeg.
Then you can determine the proper sRel values for AnyRefNode objects.

  1. Is there a way to simply import an already modeled foot from a bigger already completed model?
    -> I could not understand this question well.
    Even if you have another musculoskeletal dynamic model, you have to transform it into the form of AnyScript.
    If you want to import a single part, then it may not be a big problem. All you have to care are only mass, center of mass, moments of inertia, and its geometry file if you want it additionally.
    But if you want to import an assembly(multi body model), then you should consider that AnyBody uses the body(cartesian) coordinate system.
    Some open source models are made in form of the relative coordinate system.

  2. Exporting STL files of AnyBody human model segments
    -> Please see the attached capture file. Each seg of AnyBody human models has its ‘DrwSurf’ in form of AnyDrawSurf. Find it.

  3. Modeling your implant with respect to the exported bone geometry files from AnyBody human model in CAD environment.
    -> Most of CAD software can import STL files. But because STL file does not contain the B-REP information, usually you can not do boolean operations to the imported model such as STL files.
    So it may be better for you to use some reverse engineering software like RapidForm. In RapidForm the poind cloud data or STL file may be transformed into a IGES file.
    As you know IGES file contains the surface information in form of B-spline or NURBS, then ProE may be able to do the boolean operations to the IGES files.
    Of course I don’t know much about the recent version of ProE. So you should check what kinds of file types are allowed to do the boolean operations in ProE.
    I’ve heard that the recent version of RapidForm may create the CAD format file directly from the 3D scanned data or STL. I think that you’d better to check it, too.

I hope my answers helps you. Please understand if you know what I wrote here already.

Best regards,
Moonki

Hi,

Yes it has definitely helped but I am still confused:) with the sreal, i dont understand how accurate it has to be? like for example in the tutorial they define it as sreal= ( 0.2, 0, 0,) but i am confused as to how accurate the x coordinate has to be… what is the difference between the x value being 0.1 or 0.3? does it just have to show where it is?

what I ment with bringiing in a model is that, i need to model the gait for the lower extremity, so i need a to model a foot with all the little 26 bones so i was hoping to just maybe manage to import one.

also what about turning my models into actual bone images, do i need an stl file of the bones? also do i need c3d files to perform a gait cycle?
i am very confused…

thank you

Hi,

First thank you Moonki for your help in this post. We are always happy to see that users can help each others. Don’t hesitate to write again if you think you have a good opinion to give.

I’ll try to add some more details.

About the sRel accuracy: the model are build so that the length unit is meter. So for models the size of humans, an accuracy of 0.001 (1 mm) is usualy enough. In your example of sRel 0.2 is seen by the system as 0.2000…, so it is exactly 20 cm. So now you see that the difference between 0.1 and 0.3 is 20 cm, which is a lot of course for a human size model.

Bringing a new body part as you mean is possible but can require a lot of work. As Monnki pointed out it as to be translated into AnyScript, and it should also be compatible with the already existing model structure (folder stucture, scaling facility, etc).
Concerning the foot model with all 26 bones we are actually working in this direction already. But it will probably not be ready before a year or two.

Having a C3D file is strongly recomended to perform a gait cycle. The gait motion has to be imposed to the model in the first place. Imposing a motion can be done directly by setting joints angle and velocity. But it is very difficult for such a complex motion. Instead the C3D file give the detailed motion in a quick and easy way.

Best regards, Sylvain.

thank you very much for your help, I was just wonderin a few more things. a I do not have a c3d file, the ones in the repository have these included if I am not mistaken, so I could just use the results of that? For example I cannot get the gaitlowerextremity model moving, is that mainly because I do not know what I am doing?

also my main question is, how difficult is it to incorporate a cad model (ankle implant) correctly into the bone? is there the possibility of exporting the anybody model into for example proE and remodel it etc?

Hi,

Yes, you can use the C3D files already included in the repository. But you have to be aware that the GaitLowerExtremity and GaitFullBody motion comes from a young healthy subject. There is no guaranty that this particular gait kinematic is valid for a subject with an implant (as it seems you want to model).

The GaitLowerExtremity model should be very easy to run if you did no modifications from the original version of the repository. To run the inverse dynamic analysis you just have to load the main file, select RunInverseDynamicAnalysis in the operation tree and clic Run. To run the optimization you have to change the switch at the top of the main file.
I you have version 5 of Anybody and the newest repository you can try the GaitLowerExtremityProject where every step is guided. It should be even easier.

For the cad model i think it is important to understand first that in AnyBody the cad files are only used for visual purpose. They do not provide any mechanical information. So you can export easily the existing bones files, modify them with the sofware of your choice with any implant you want and put that back in AnyBody. But it will not change the mechanic of the model (joints and segments). To do so you have to modify the joints and segments of the model into the script to match the mechanics of your implant. That part has to be done inside AnyBody. It is not very difficult to do in most cases.

Best regards, Sylvain.