SGTcopyasopponent

by Tim C. Lueth, SG-Lib Toolbox: SolidGeometry 5.6 - Kinematics and Frames
Introduced first in SolidGeometry 5.0, Creation date: 2020-12-17, Last change: 2025-09-15

copies a frame that crosses a surface as surface frame



See Also: TofcrossedSG

Example Illustration

 missing image of SGTcopyasopponent(B,A,NA,NB)

Syntax

B=SGTcopyasopponent(B,A,[NA,NB])

Input Parameter

B: Solid to receive the frame
A: Solid that sends the frame
NA: Name of the Solid to copy
NB: optional new Name of B

Output Parameter

B: Solid that received the frame




Copyright 2020-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 algorithm is designed to copy a frame from one solid (A) to another solid (B) in a kinematic and frame context. It is part of the SolidGeometry library and is used to manage frames that cross surfaces.

Input Parameters

Output

Algorithm Steps

  1. Retrieve the frame name NA from the input parameters using getfuncparams.
  2. If NB is not provided, set it to NA.
  3. Select the frame from solid A using SGTframeselect with the name NA.
  4. Check if the frame selection is empty. If so, throw an error indicating no frame was found.
  5. Loop through each frame index found in fs:
  6. If no output is expected (nargout==0), plot the frames:
Algorithm explaination created using ChatGPT on 2025-08-19 01:35. (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