This is the variation of Ron's spring.inc I wrote about on
povray.general.
It differs from the original in the following:
1. the angular length of the segments is variable, which can
be used for quality tuning
2. the radius of the segments is larger than their distance from
the helix axis, which agrees with reality (if you stretch a
spring, the curvature radius of the wire increases)
3. the relations for the endpoints of the segments are solved
numerically using Newton's algorithm, thus giving an exact
C^1 agreement at the glue points (more than C^1 is impossible
-- the only C^2 continuation of a torus is more of the same
torus). In addition, it does not break apart even when for
a very steep helix.
Ralf
Post a reply to this message
Attachments:
Download 'mkhelix.zip' (2 KB)
|