Tof2Tcrossez

by Tim C. Lueth, SG-Lib Toolbox: SolidGeometry 5.6 - Kinematics and Frames
Introduced first in SolidGeometry 5.1, Creation date: 2021-03-20, Last change: 2025-09-15

adjusts the position of frames relative to a crossing point with another frame

Description

faster implementation than cross2L

See Also: cross2L

Example Illustration

 missing image of Tof2Tcrossez(T1,T2)

Syntax

[TA,TB]=Tof2Tcrossez(T1,T2)

Input Parameter

T1: Frame 1
T2: Frame 2

Output Parameter

TA: Moved Frame 1
TB: Moved Frame 1

Examples


Tof2Tcrossez(SGTget(YKLower,'B'),SGTget(YKLower,'F')*TofR([0 pi 0]))




Copyright 2021-2025 Tim C. Lueth. All rights reserved. The code is the property of Tim C. Lueth and may not be redistributed or modified without explicit written permission. This software may be used free of charge for academic research and teaching purposes only. Commercial use, redistribution, modification, or reverse engineering is strictly prohibited. Access to source code is restricted and granted only under specific agreements. For licensing inquiries or commercial use, please contact: Tim C. Lueth

Algorithm (Workflow)

This function, Tof2Tcrossez, is designed to adjust the position of two frames, T1 and T2, relative to a crossing point. It is a faster implementation than the function cross2L.

Input Parameters

Output Results

Algorithm Steps

  1. Calculate the transformation matrix T from T1 to T2 using the inverse of T1 multiplied by T2: T = T1\T2.
  2. Extract the z-component of the translation from the transformation matrix T: z1 = T(3,4).
  3. Compute the crossing point cp1 for T1 using its translation and the z-component: cp1 = (T1(1:3,4) + z1*T1(1:3,3))'.
  4. Calculate the transformation matrix T from T2 to T1: T = T2\T1.
  5. Extract the z-component of the translation from the transformation matrix T: z2 = T(3,4).
  6. Compute the crossing point cp2 for T2: cp2 = (T2(1:3,4) + z2*T2(1:3,3))'.
  7. Calculate the accuracy of the crossing points by finding the norm of the difference between cp1 and cp2: acc = norm(cp1-cp2).
  8. Adjust the position of Frame 1 by setting its translation to cp1: TA = T1; TA(1:3,4) = cp1'.
  9. Adjust the position of Frame 2 by setting its translation to cp2: TB = T2; TB(1:3,4) = cp2'.
  10. If no output arguments are specified, visualize the frames and crossing points using plotting functions.
Algorithm explaination created using ChatGPT on 2025-08-19 00:43. (Please note: No guarantee for the correctness of this explanation)

Last html export of this page out of FM database by TL: 2025-09-21