PLFLfaceNormal

by Tim C. Lueth, SG-Lib Toolbox: SolidGeometry 5.6 - Analytical Geometry
Introduced first in SolidGeometry 2.1, Creation date: 2015-01-09, Last change: 2025-09-14

returns the rounded (1e-5) length of the area size/length of normal vector

Description

This is a function to adapt the VLFL syntax to R2014b.
The normal vector in 2D is always (0 0 1); It is the z-value of the cross function, called crossz.

See Also: PLnorm , PLELnorm , VLnorm , VLFLfaceNormal

Example Illustration

 missing image of PLFLfaceNormal(PL,FL,fi)

Syntax

[NL,AL]=PLFLfaceNormal(PL,FL,[fi])

Input Parameter

PL: Point list n x 2
FL: Facet list
fi: optional value; facet index (list)

Output Parameter

NL: n x [0 0 1]
AL: Area list;




Copyright 2015-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, PLFLfaceNormal, calculates the normal vector and area of facets defined by a point list and a facet list. It is designed to adapt the VLFL syntax to MATLAB R2014b.

Input Parameters

Output Results

Algorithm Steps

  1. Initialize fi to cover all facets if not provided.
  2. Determine the number of facets to process, ni.
  3. Initialize NL and AL to store results for each facet.
  4. Loop over each facet index in fi:
    • Calculate the area of the facet using the crossz function, which computes the z-component of the cross product of two vectors formed by the points of the facet.
  5. Set the normal vector for each facet to [0 0 1], indicating a constant normal direction in 2D.
Algorithm explaination created using ChatGPT on 2025-08-18 23: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