rotdeg

by Tim C. Lueth, SG-Lib Toolbox: SolidGeometry 5.6 - Analytical Geometry
Introduced first in SolidGeometry 1.0, Creation date: 2012-11-20, Last change: 2025-09-14

returns 3x3 rotation matrix for Deg angles in x, y, z

Description

Similar to 'rot' but the angles are given in Deg instead of Rad.

Example Illustration

 missing image of rotdeg(wx,wy,wz)

Syntax

R=rotdeg(wx,wy,wz)

Input Parameter

wx: angle for x-rotation in Deg
wy: angle for y-rotation in Deg
wz: angle for z-rotation in Deg

Output Parameter

R: Rotation matrix 3x3




Copyright 2012-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, rotdeg, computes a 3x3 rotation matrix for given rotation angles in degrees around the x, y, and z axes. It is part of the SG-Library and was developed by Tim Lueth.

Input Parameters

Output

Algorithm Explanation

The function begins by defining a conversion factor f to convert degrees to radians, which is pi/180.

The function checks the number of input arguments using nargin:

The function relies on an external function rot to compute the actual rotation matrix from the given angles in radians.

Algorithm explaination created using ChatGPT on 2025-08-18 22:25. (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