Derive threadlib specs from industrial norms
developTo create a new thread specification for threadlib, you must translate values from an industrial standard (e.g., BS EN ISO 228-1) into the piecewise linear profile used by the library.
Derivation Logic
- Pitch (
P): Must match the pitch defined in the norm exactly (e.g.,0.907mm for G1/16). - Pitch Diameter: Choose a value in the center of the tolerance range provided by the norm.
- Radii (
r_crestandr_valley):r_crest: This is the major/minor radius (external/internal). It must account for both the allowed deviations in the norm and the rounding radius. To ensure the piecewise linear profile stays on the correct side of the true profile, the crest radius should equal the radius where the straight rising edge of the profile touches the rounding circle.r_valley: This is the minor/major radius (external/internal). Since norms often do not specify limits for the valley, choose a small, finite width for the "valley floor" that ensures ample clearance to the parting line and ensures the thread profile covers less than one pitch.