News:

Please note new Forum URL: forum.designcad.com

Main Menu
DesignCAD 3D Max 2027 box
Now available

DesignCAD 2027

Hatches that follow their boundaries, an on-screen dial to turn your model, and a way to find any command by name, in a clean Windows 11 look.

Making a curved tube

Started by Shipmodeler, October 14, 2010, 11:10:04 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Shipmodeler

I'm making a boat davit drawing using DC-20.  Basically, it looks like a fish hook with the straight side stuck in the deck, with the top a quarter circle (see below).  I got the straight part OK using the cylinder (should I use the tube command?) command, but I can't figure out how to make the quarter circle extension at the top and a nice, round cap.  I'm new at 3D so forgive me.

"A man can never say he has truly lived until he has built a model ship"
Ronald Reagan

Bob P

Slightly mis-named in the help. "Extrude along a curve surface". (Ctrl-Shift-X)

You can do your entire line at the same time by combining all the lines into a single entity, but you lose the arc in favor of a segmented line.  But you can also use the command on the single arc and add the straight tubes later.

I create the circular plane by using perpendicular-plane at one endpoint of the line, then using three of the plane's points to create a circular plane (or a circle if you want a hollow tube).  A sizing shortcut is to make the initial plane with sides .7071 times your circle's diameter. (1/sqrt(2))  Otherwise, you can scale whatever circle you get from the square snaps.


Shipmodeler

#2
Many thanks.  

AutoCad calls a "line" one name while DC calls it another, and Adobe Illustrator calls it a "path", and Corel Draw calls it yet something else.  It's the same thing in all those programs.  Therein lies the problem with computer programs.  I use DC-20 mostly for 2D applications so I am somewhat unfamiliar with many of the command terms DC uses for 3D commands.  I find it easier to just admit ignorance and ask here.

Thanks again for the help.
"A man can never say he has truly lived until he has built a model ship"
Ronald Reagan

Bob P

#3
DC's legacy is probably from those da*n engineers (like me) who think not of a visual entity, but of an entity's length (magnitude) and direction, i.e. "vector".  I suspect that's where the shortcut V (for line) comes from.

Shipmodeler

Quote from: Bob P on October 16, 2010, 06:12:11 AM
DC's legacy is probably from those da*n engineers (like me) who think not of a visual entity, but of an entity's length (magnitude) and direction, i.e. "vector".  I suspect that's where the shortcut V (for line) comes from.

Interesting, thank you.  Thanks to your help  I drew up a nice davit in 3D. 
"A man can never say he has truly lived until he has built a model ship"
Ronald Reagan

Dr PR

shipmodeler,

The "Extrude Along A Curve" function can be used, but it has a few peculiarities you should be aware of. Most important - you need to place points along the curve VERY carefully. Not just any curve will work.

You cannot actually create a "Curve" (C) that is straight for some distance and curved beyond. At the place where the line transitions from the straight segment to the curve, some curvature will propagate into the "straight" section. In a "Curve" if all but one point actually are on a geometrically straight line, and only one point is not, the entire line will be nonlinear. The difference is greatest near the point where the curved part begins, but even between points at a distance the curve will bend slightly away from a straight line between points.

To create a davit you should extrude the linear portion separately from the curved portion.

If the curved part actually follows a constant radius arc, use the "Sweep" function to sweep a cross section of the davit around the arc.

"Extrude Along A Curve" can be used to create tapered curved objects, but the instructions are incomprehensible and operation of the command is totally illogical. I usually have to try again and again before it works, but if you keep at it eventually you might get useable results.

I do use the "Extrude along A Curve" function extensively, but only for things that do not require any precision, like cable runs or ropes.
DesignCAD user since 1987

Shipmodeler

That's what I ended up doing.  That is making the linear and curved section as separate parts.  I popped a hemisphere cap on the end and came up with a nice looking davit. 

Thanks to all for the help.
"A man can never say he has truly lived until he has built a model ship"
Ronald Reagan

bdeck

#7
Quote from: Dr PR on October 20, 2010, 02:47:22 PM
You cannot actually create a "Curve" (C) that is straight for some distance and curved beyond.


Hi Dr P,

As it turns out, DC is mathematically correct in interpreting two consecutive curve points having identical coordinates as a breakpoint. (an endpoint is also a class of breakpoint). The curve between any two breakpoints is a straight line.

And you can extrude along a curve with breakpoints. (I hope this feature does not get lost in future improvements.)

Here's a 2d example of a curve with multiple breakpoints done in version 17.2.

Of course one must manually set the points on the radiused portion to try to achieve something close to tangency at the knuckle. Because the curve only approximates an arc, the sweep function may be marginally better than extrude-along-a-curve if accuracy is important.


BD

bdeck

#8
Quote from: bdeck on October 20, 2010, 04:43:32 PM
...  (an endpoint is also a class of breakpoint). The curve between any two breakpoints is a straight line.... And you can extrude along a curve with breakpoints.

Caveat

When extruding over a straight section near a single endpoint, DC draws a linear grid as an extrusion over a straight curve, with multiple (180 deg) breaks in the resulting grid (figure A, attached) ,  rather than as a simple cylinder (figure B) where a double endpoint is used.

Also, the fineness of the extusion may interfere with a miter in the middle of a curve (figure C), but can be corrected with less fineness (figure D) or straight sections adjacent to the miter (figure E)

The APW macro can be used to examine the points in the underlying curve.

Dr PR

BD,

I know about the "breakpoint" feature in curves, where two points are set at a single position. However, I have no idea what DesignCAD actually does if you try to extrude a curve with a breakpoint.

As your example shows, the "Extrude Along A Curve" creates many sections in the straight section of the extrusion. This bloats file sizes - for example, I created a simple object with a single straight section and a curved section using program defaults and the single object added 13 megabytes to the file! Using a cylinder for the straight section and sweeping the curved part added only about 100 Kbytes to the file. For this reason alone, "Extrude Along A Curve" should never be used if other options achieve the same result, and you should NEVER use the program defaults. Cylindrical sections should be created with a cylinder to achieve the smallest file size.

I do not know what DesignCAD does "between" the two coincident points. Your example shows segments where the two coincident points are at a sharp angle in the line. This makes me wonder if DesignCAD is adding a lot of hidden segments - another cause of file bloating, and potential source of invisible garbage if the solid is later exploded.

There are more than enough problems with "Extrude Along A Curve" when it is used with a simple curve. Using it with curves having breakpoints is just asking for trouble!

****

Note: curves with breakpoints can also be used as template curves for Surface Connect. The results are usually awful! Intermediate facets are "folded" over the edge, producing a rough faceted edge instead of a sharp knuckle. Again, it is MUCH better to use two separate curves rather than a single curve with two points at the same position.

****

The only place I have found curves with "breakpoints" useful is in 2D drawings.
DesignCAD user since 1987

bdeck

#10
Hi Dr PR,

Quote from: Dr PR on October 21, 2010, 11:35:02 AM
I do not know what DesignCAD does "between" the two coincident points.

From Help/Drawinginfo one can compare the number of the grid surface entities on an extrusion with those that are visible in the rendering. From this analysis it appears that DC creates a zero-length grid in the space between the two points on the defining curve. This does not seem to cause a problem for an extruded grid. Fortunately, I learned from you how to break up grid definition curves advantageously to avoid problems at knuckles in surface connect grids.

QuoteYour example shows segments where the two coincident points are at a sharp angle in the line.

On figure E  I drew a source curve having 3 consecutive knuckles (3 pairs of duplicate points) to illustrate a simple way to avoid conflict at a miter bend (shown in figure C). Even without knuckles, if the fineness of the grid is too great for the curvature of the defining curve, bad things can happen.

QuoteThis makes me wonder if DesignCAD is adding a lot of hidden segments - another cause of file bloating, and potential source of invisible garbage if the solid is later exploded.

You've given me an idea for a new project: a macro to go through a drawing and remove all the grids and solids having zero size. Didn't someone already do this for zero length lines?

As an aside,  one big cause of bloat is that anytime you trim a curve or use the scissor tool in point select mode, the point density on the curve skyrockets. Since the number of breaks in a grid generated with the extrude-along-a-curve function is a multiple of the points on the defining curve, this can be a real issue. I've done this inadvertently  in the past.

Best Regards,

BD


Dr PR

BD,

Thanks for the additional information.

Your last point about trimming curves and the resultant huge increase in points reminded me of a practice I follow religiously when using DesignCAD. I never use a curve generated by DesignCAD. After trimming or slicing a curve I use the resultant parts as templates and trace my own curve over them. I can do a much better job of point placement than DesignCAD does. Then the originals are deleted.

I never keep a grid after it has been edited. For example, suppose I need to place a hole in a grid surface, by defining the grid to be a solid and then using "Solid Subtract" to subtract a cylinder. The resulting grid will be a large collection of unassociated facets (but still a solid) that bloats the file size. I use the fragmented grid as a template to draw curves used with "Surface Connect" to create several new grids around the hole. Next I add individual planes to fill in the gap around the hole, using the original grid as a template. Then I delete the original fragmented grid. All of the individual grids and planes are then defined to be a solid to get smooth shading. The resulting file is much smaller.

The point here is that you can reduce file size and create "better behaved" objects by using existing curves and grids as templates for creating new curves and grids.
DesignCAD user since 1987

bdeck

Quote from: Dr PR on October 22, 2010, 02:41:19 PM
The point here is that you can reduce file size and create "better behaved" objects by using existing curves and grids as templates for creating new curves and grids.

Hear, Hear.

One project that I've been threatening to tackle for years is a giant macro to keep original curves in a dedicated editing layer, and keep trimmed  renderings of those curves in another layer. The editing layer would know about trim lines but the original endpoints would never change, unless changed explicitly by the user. One could edit or add or delete individual points in the dedicated layer in a sort of point select mode, but trims and cuts would never happen in that layer.

So much to do, so little time....

Regards,

BD