PLmirroratline

by Tim C. Lueth, SG-Lib Toolbox: SolidGeometry 5.6 - PL/Point Lists
Introduced first in SolidGeometry 5.0, Creation date: 2020-09-20, Last change: 2025-09-14

mirrors a PL or CPL



See Also: mirroringatline , mirroringatline3D

Example Illustration

 missing image of PLmirroratline(PL,p1,p2)

Syntax

MPL=PLmirroratline(PL,[p1,p2])

Input Parameter

PL: PL or CPL
p1: point 1 on line
p2: point 2 on line

Output Parameter

MPL: Mirrored PL

Examples


PLmirroratline(CPLsample(30));




Copyright 2020-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, PLmirroratline, mirrors a polyline (PL) or closed polyline (CPL) at a line defined by two points, p1 and p2.

Input Parameters

Output

Algorithm Steps

  1. Retrieve the points p1 and p2 from the input parameters or use default values if not provided.
  2. Initialize MPL as a copy of PL.
  3. Calculate the unit direction vector ez of the line from p1 to p2.
  4. Iterate over each point in PL:
  5. If no output is requested (nargout==0), plot the original and mirrored polylines:
Algorithm explaination created using ChatGPT on 2025-08-18 23:49. (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