TurboCAD Forums

The Ultimate Resource for TurboCAD Knowledge

Register
 
The purpose of these forums is to discuss TurboCAD.  Please keep the discussion of other products to compatibility issues or how the other software’s can be used with TurboCAD.


Length of spline
Read 2541 times
* August 12, 2009, 07:43:30 PM
I know you can calculate the area within a closed spline using the 2D geometric parameters tool, but is there any way of calculating the length of a spline?

Logged
Vista Business SP 2
Turbocad Prof V15.2
Turbocad CAM V3.5


* August 12, 2009, 09:17:19 PM
#1
You can get a close approximation by exploding the Spline. This converts it into a Polyline, whose length v15 will report in the Selection Info palette. Accuracy is increased by increasing The number of segments between adjacent control points -- although the default value of 20 gives good results.

Version 16 will report the length of a Spline directly.

As a test of accuracy, I drew the Spline shown in the attached screenshot in v15.2, with The number of segments between adjacent control points = 20, and exploded it. Reported length was 54.7586220624". Having saved the drawing before exploding the Spline, I opened it in v16 and found the reported length of the actual Spline to be 54.764390859". Assuming this latter value is correct, the error incurred by exploding to a Polyline was about 0.0058", or just a little over 0.01 percent.

Henry H

[attachment deleted by admin]

Logged


* August 12, 2009, 10:15:30 PM
#2
Excellent - works very well. Thanks Henry.

Logged
Vista Business SP 2
Turbocad Prof V15.2
Turbocad CAM V3.5


* August 12, 2009, 10:39:59 PM
#3
Hi!

Isn't there is a tool for this?

In tools / Measurements / Distance you can actually measure a spline (I'm still using ver. 12.3 with Mech pack)
Simply choose the icon length of a single entity (a triangle with a question mark icon) and it does work for a spline. You can even use it for a 3D spline (tried it by curiosity)

Logged
Stephane Faucher


* August 13, 2009, 10:02:43 AM
#4
Hi!

Isn't there is a tool for this?

In tools / Measurements / Distance you can actually measure a spline (I'm still using ver. 12.3 with Mech pack)
Simply choose the icon length of a single entity (a triangle with a question mark icon) and it does work for a spline. You can even use it for a 3D spline (tried it by curiosity)

Yup. You're right, Stephane; but that tool actually reports  the same "Length" as the Selection Info palette reports when the Spline is exploded into a Polyline. In other words, it's an approximation, and its accuracy depends upon The number of segments between adjacent control points. Use whichever approach is more convenient, since the results are identical.

Henry H

Logged


* August 13, 2009, 10:31:33 AM
#5
I see!

Measurement info tool is not as accurate as "metrics" in the selection info palette.
The first one seems to be based on the graphical representation (finite line elements for curves and circles) and the other one
is the actual geometrical dimensions.

A circle with a radius of one shows a circumference of 3.1415910586 in the measurement info, and gives the correct pi number in selection info. Thanks for the notice.

Logged
Stephane Faucher