Referencing local coordinate system in python

1

I'm developing a 3D structural calculation software and I need to reference the local coordinate system of the bars. We define that the x-axis will always coincide with the central axis of the bar, the z-axis will be perpendicular to the global Y-axis, and the y-axis will have the orientation in relation to the Y-axis as well: if its Y-axis projection is positive, , if the projection is negative, it will be negative. Now, from providing the coordinates of a slash, how can I do that? I can not understand which logic I will use to make the program understand this

    
asked by anonymous 19.05.2018 / 15:18

1 answer

0

What you want to do is a base-coordinate transformation

Suppose your bar is positioned at the (x, y, z) point of the global coordinate system and has its "local" coordinates (the coordinate system of the bar) (x ', y', z '), if a force is applied at the end of the bar (where x '= 0) you want to find which global position (coordinates (x, y, z)) where that force is being applied, for this you need to transform the coordinates of the bar system for the global system, this is done through a transformation matrix.

To simplify, let's suppose that the bar of the above example is in the position (10, 0, 0) ie, 10 cm away from the yz plane, in which case its force at x '= 0 would have a coordinate x = 10, in the global system, since the end of the bar coincides with the position x in that system.

This type of transformation is called translation, there are other types of transformation (rotation, shearing), you can read more about base change here:

link

    
04.09.2018 / 20:14