Syntax
wa=CVLpathwarning(CVL,[warna,ignor])
Input Parameter
CVL : | | |
warna : | | warning angle; default is pi/2*0.99 |
ignor : | | if true (default), CvL is considered as open, if false start to end is also considered |
Output Parameter
wa : | | true if angles exist larger thatn pi/2 |
Examples
TLofn([1 6 6]);TL=ans; VLof2TR(TL(:,:,1),TL(:,:,2),10); VL=ans; CVLpathwarning(VL)
TLofn([1 6 6]);TL=ans; VLof2TR(TL(:,:,1),TL(:,:,2),10); VL=ans; CVLpathwarning(VLradialEdges(VL,5))
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 algorithm checks if a given path, represented as a closed polygon list (CVL), contains angles larger than a specified warning angle. It is part of the SolidGeometry library.
Input Parameters
- CVL: A closed polygon list representing the path.
- warna: The warning angle threshold. Default is 0.99 * pi/2.
- ignor: A boolean flag. If true (default), the path is considered open, ignoring the angle between the start and end points. If false, the path is considered closed.
Output
- wa: A boolean indicating if any angles in the path exceed the warning angle.
Algorithm Steps
- Retrieve the warning angle (
warna
) and the ignore flag (ignor
) from the input parameters or use default values.
- Check the dimensions of
CVL
. If it has more than one layer or more than three columns, convert it using VLofT
.
- Calculate the angles of the path using
VLangle
.
- If
ignor
is true, set the first and last angles in the list to NaN
to ignore them.
- Find indices of angles greater than
warna
.
- If no output is requested, plot the path using
SGfigure
and VLplot
, highlighting angles that exceed the warning threshold.
Algorithm explaination created using ChatGPT on 2025-08-19 00:51. (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