Syntax
PL=PLcirctrapezoid([bh,al,wz])
Input Parameter
bh : | | [diameter/width and height]; default is [4 0] |
al : | | rotation of CPL; default is 0 |
wz : | | default is 51 degree; used to calculate the height |
Output Parameter
PL : | | PL to replace a circular solid using |
Examples
PLcirctrapezoid(1.6/2)
PLcirctrapezoid(DIN13(3,'Core_Diameter_Bolt')/2)
Copyright 2022-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, PLcirctrapezoid
, generates a trapezoidal contour for self-tapping screws. It is part of the SolidGeometry library and was introduced in version 5.2.
Input Parameters
- bh: A vector containing diameter/width and height. Default is [4 0].
- al: Rotation of the contour in degrees. Default is 0.
- wz: Angle in degrees used to calculate the height. Default is 51 degrees.
Output
- PL: A polygon list (PL) that replaces a circular solid.
Algorithm Steps
- Retrieve input parameters using
getfuncparams
function with default values.
- Calculate the original base diameter
borg
as twice the first element of bh
.
- Set
b
and h
as twice the elements of bh
.
- Calculate the scaling factor
m
as 1/cos(pi/8)
.
- Scale
b
and h
by m
.
- Convert
al
from degrees to radians.
- If
h
is zero, calculate h
as b * tan(al)
.
- Create the trapezoid points
PL
as a matrix with four points.
- If
wz
is not zero, rotate PL
using PLtransR
function.
- If no output is requested, plot the trapezoid and a reference circle using
SGfigure
and PLplot
.
Example Usage
Examples of calling the function:
PLcirctrapezoid(1.6/2)
PLcirctrapezoid(DIN13(3,'Core_Diameter_Bolt')/2)
Algorithm explaination created using ChatGPT on 2025-08-19 01:28. (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