Syntax
[VL,FL,CLO,CLI]=VLFLcreateframe(X,Y,H,b)
Input Parameter
X : | | Size in X [0..X] |
Y : | | Size in Y [0..Y] |
H : | | Size in Z [0..H] |
b : | | bar width |
Output Parameter
VL : | | Vertex list |
FL : | | Facet list |
CLO : | | Contour list |
CLI : | | |
Examples
frame of size 40x60 with thickness 4 and bar width of 5 mm
closeall; [VL,FL]=VLFLcreatecross (40,60,4,5); VLFLplot (VL,FL);
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, VLFLcreateframe
, is designed to generate a 2.5D frame-shaped structure. It takes four input parameters and returns four outputs. Below is a detailed explanation of the algorithm and its parameters.
Input Parameters
- X: Represents the size in the X-direction, ranging from 0 to X.
- Y: Represents the size in the Y-direction, ranging from 0 to Y.
- H: Represents the size in the Z-direction, ranging from 0 to H.
- b: Represents the bar width.
Output Results
- VL: Vertex list, which contains the coordinates of the vertices of the frame.
- FL: Facet list, which contains the indices of the vertices that form each facet of the frame.
- CLO: Contour list for the outer boundary of the frame.
- CLI: Contour list for the inner boundary of the frame.
Algorithm Steps
- Initialize
bw
with the value of X
and bd
with the value of Y
.
- Set
pw
to the value of b
, which represents the bar width.
- Define the outer contour
CLO
as a 4x3 matrix representing the corners of the frame in the x/y plane at z=0:
- (0, 0, 0)
- (bw, 0, 0)
- (bw, bd, 0)
- (0, bd, 0)
- Define the inner contour
CLI
as a 4x3 matrix representing the inner boundary of the frame:
- (pw, pw, 0)
- (bw-pw, pw, 0)
- (bw-pw, bd-pw, 0)
- (pw, bd-pw, 0)
- Call the function
VLFLclose3D2C
with CLO
, CLI
, and H
to generate the vertex list VL
and facet list FL
.
The function VLFLclose3D2C
is assumed to create a 3D closed structure based on the provided outer and inner contours and the height H
.
Algorithm explaination created using ChatGPT on 2025-08-18 23:15. (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