I'm trying to build a subroutine for a custom contact normal force. I require the locations of the contact so I wanted to utilize the loci, locj variables but every time print their information they seem to be completely off. To elaborate:
I have set up a model with a contact taking place around the location of -100,0,0. I've built a subroutine that prints out the loci, locj arrays from matlab but instead of printing something like
[-100, 0, 0 (+-some small percentage due to the contact incidents)]
the numbers are completely off.
Does Adams measure the locations from a starting point other than the global (0,0,0)? Or am I perhaps interpreting the loci, locj vectors wrong?
Where are the i and j parts located at the time of incident? I would assume that loci and locj are expressed in local coordinates for the parts. Otherwise there would be no reason to have both loci and locj as in global coordinates they should be the same.
I assume that local coordinates are measured from a body's CG. One of the loci coordinates however is -1900 (on a body of a total length of 1000 mm in the same direction and its CG in its center i.e., 500 mm on either side). So this should not be possible really.
The contact force appears on a different position in the model so I tried measuring from there but the numbers till don't add up.
Come on now. CG? That changes all the time during building of a model.
They are measured from the LPRF (local part reference frame), i.e. the definition of the part (Right click on a part in View and select 'info' and you will see that each part has a location and orientation, that is the LPRF)
Yes it would be possible. However I still can't tell how they are estimated. There should still be a reference point based on which they are calculated. If I and J denote geometry, shouldn't there be a point of origin?
Loci and Locj seem to indeed be returned wrt the cg marker of each body, or at least, a marker in the same location. Would there be a way to return them in the global coordinate system? I believe that CNFSUB cannot be modified to do that.
Vector algebra? You can get the part CG location and orientation using a SYSARY call and then transform the local coordinates to global. Might sounds nasty, but it's really not that bad.