TurboCAD Forums

Turbo Talk => Problems => Topic started by: IanC on April 17, 2018, 12:50:48 PM

Title: Area of Polyline with varying width
Post by: IanC on April 17, 2018, 12:50:48 PM
I've never used polylines of varying width before, in fact I wasn't aware of them, but been given a drawing with these (world scale).

I'm trying to obtain the area of the line (which represents a cycle path). But if I explode it, I get a lot of segments, whereas what I want is an closed 'normal' polyline.

Any ideas?
Title: Re: Area of Polyline with varying width
Post by: murray dickinson on April 17, 2018, 05:55:06 PM
Too vague.  Do you mean that the segments are of a fixed width that follows the previous polyline's vectors, ie single path, or that you've got an outline of the variable-width polyline?   If it's an outline, modify|join polyline will give you area if the outline's closed, otherwise some tracing will probably be needed.
Title: Re: Area of Polyline with varying width
Post by: Henry Hubich on April 17, 2018, 05:56:42 PM
Can you post the .tcw?

Henry H
Title: Re: Area of Polyline with varying width
Post by: IanC on April 17, 2018, 11:41:14 PM
Just a single polyline, now attached.

I think it needs tracing, but that doesn't seem very efficient!
Title: Re: Area of Polyline with varying width
Post by: murray dickinson on April 18, 2018, 06:55:09 AM
35,141.576 square feet is the answer I got.  I drew two arbitrary polylines either side of the variable width one, and pick point hatched the area enclosed either side of it, added the area of the hatches.  Then I deleted the variable width polyline, hatched the   entire area enclosed by the two arbitrary polylines, subtracted the area of the two initial hatches, the answer is the area of the variable width polyline.   There are beginning and end segments of the pline that don't have variable width, I disregarded them.
Imperial measurements are rubbish.   Why did the hatches' area get reported in them?  3264.759240791 m² is the conversion. 
Title: Re: Area of Polyline with varying width
Post by: IanC on April 18, 2018, 09:17:23 AM
Perfectt! Thanks Murray, now why didn't I think of that?   ;D

Actually, just done it even more simply, based on your idea:

1. Draw a rectangle arbritarily encompassing the whole area.
2. Pick-point hatch it.
3. Delete variable-width polyline.
4. Pick-point hatch the area where the v-w polyline was.
4. Delete objects created in steps 1 and 2.
Title: Re: Area of Polyline with varying width
Post by: Jeffin90620 on May 09, 2018, 04:48:16 PM
Actually, just done it even more simply, based on your idea:

1. Draw a rectangle arbritarily encompassing the whole area.
2. Pick-point hatch it.
3. Delete variable-width polyline.
4. Pick-point hatch the area where the v-w polyline was.
45. Delete objects created in steps 1 and 2.

And just how do we do that?


Jeff
Title: Re: Area of Polyline with varying width
Post by: Jeffin90620 on May 09, 2018, 05:09:54 PM
35,141.576 square feet is the answer I got.  I drew two arbitrary polylines either side of the variable width one, and pick point hatched the area enclosed either side of it, added the area of the hatches.  Then I deleted the variable width polyline, hatched the   entire area enclosed by the two arbitrary polylines, subtracted the area of the two initial hatches, the answer is the area of the variable width polyline.   There are beginning and end segments of the pline that don't have variable width, I disregarded them.
Imperial measurements are rubbish.   Why did the hatches' area get reported in them?  3264.759240791 m² is the conversion.

I did it slightly differently by drawing one closed Polyline with two of its vertices V-snapped to the ends of the Variable-Width Polyline (aka VWP).  Pick-Point Hatch created two areas, above and below.

I then used Selection Info / Metrics / Area to get the three areas, subtracting the smaller two from the largest to yield 3,264.772378577 square inches, which varies from Murray's result by 0.0004%+.  I am surmising that the reason for this very minor discrepancy is the near-zero width of the very thin line segments at each end of the wider line segments being included in my calculation while not being included in Murray's (which would make Murray's result more accurate (probably).


Jeff
Title: Re: Area of Polyline with varying width
Post by: murray dickinson on May 09, 2018, 05:12:49 PM
IanC's refinement is fast.  A variable-width polyline is an island with physical area when completely within a rectangle.  PPHatch the rectangle, delete the pline, and it leaves a void in the hatch.  Hatch the void and the hatch's area registers in selection info. 
Title: Re: Area of Polyline with varying width
Post by: Jeffin90620 on May 09, 2018, 05:18:54 PM
IanC's refinement is fast.  A variable-width polyline is an island with physical area when completely within a rectangle.  PPHatch the rectangle, delete the pline, and it leaves a void in the hatch.  Hatch the void and the hatch's area registers in selection info.

That's what I tried, but did not see a hollow area in the hatch.  What am I missing?


Jeff
Title: Re: Area of Polyline with varying width
Post by: murray dickinson on May 09, 2018, 05:24:12 PM
Dunno.  Was the VW pline completely inside the rectangle? 
Title: Re: Area of Polyline with varying width
Post by: Jeffin90620 on May 09, 2018, 05:25:50 PM
Yes, it was completely inside the Rectangle.


Jeff
Title: Re: Area of Polyline with varying width
Post by: murray dickinson on May 09, 2018, 05:32:25 PM
Click close to the pline for the hatch, not the rectangle, maybe?