ticksofminmax

by Tim C. Lueth, SG-Lib Toolbox: SolidGeometry 5.6 - Auxiliary function
Introduced first in SolidGeometry 5.0, Creation date: 2020-09-21, Last change: 2025-09-14

returns a list of unique increasing values between bb(1) and bb(2)



See Also: ticksofBB

Example Illustration

 missing image of ticksofminmax(bb,res,det)

Syntax

tck=ticksofminmax(bb,[res,det])

Input Parameter

bb: [min max]
res: distance between ticks
det: resolution default is .1

Output Parameter

tck: unique increasing values between bb(1) and bb(2)

Examples


ticksofminmax([-pi +pi],1,.01)




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, ticksofminmax, generates a list of unique, increasing values between two specified bounds, bb(1) and bb(2). It is part of the SolidGeometry library and was introduced in version 5.0.

Input Parameters

Output

Algorithm Steps

  1. Retrieve the res parameter using getfuncparams, defaulting to 5 if not specified.
  2. Retrieve the det parameter using getfuncparams, defaulting to 0.1 if not specified.
  3. Generate a range of values from rounddiv(bb(1), res) to rounddiv(bb(2), res) with a step size of res.
  4. Include the rounded values of bb(1) and bb(2) using det for rounding.
  5. Combine all values into a single vector.
  6. Sort the vector and remove duplicates using sort(unique(tck)).

Example

To generate ticks between -pi and +pi with a resolution of 1 and a detail of 0.01, use:

ticksofminmax([-pi +pi], 1, .01)
Algorithm explaination created using ChatGPT on 2025-08-18 22:55. (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