Jump to content

Tangent to Spline - Specified Slope


tdfsks

Recommended Posts

Hello All,

 

I am looking for a method to draw a tangent to a spline that is parallel to another line. In other words I would like to find the point on the spline that has a tangent with the same slope as the line.

 

See the attached image and .dwg files. Basically I want to move the line (or generate a new parallel one) so that it is tangent to the spline.

 

There are a few old threads that deal with drawing a tangent to a spline at a specified point on that spline and there are several methods by which this can be done. However I cannot find any discussion of the problem that I have ....

 

This problem is an essential step in manually lofting sheet metal developments in the traditional way.

 

Any help will be greatly appreciated.

 

Steve

Tangent to Spline.jpg

Spline Tangent.dwg

Link to comment
Share on other sites

Welcome to CADTutor forum. :)

Set your snaps like in the screenshot, or you could use Endpoint instead of Midpoint, if you prefer.

Lots of other ways, but this is pretty straight forward.

I copied the top line, dragged it down towards the spline, and it defined the snap point at the point of tangency.

spline tangency.jpg

spline tangent qps.jpg

Link to comment
Share on other sites

Thanks for the reply.

 

However I cannot make this work for me ...

 

I set the Snaps as instructed and copy the line using the mid point of the line as the reference point. The only places it will snap to the spline as tangent are at the two points where an imaginary line from the reference point I have selected is tangent to the spline. It will not snap where the line itself should be tangent (i.e. somewhere near the top of the spline curve in the pictures).

 

See attached pictures. The mid point of the line is just above the top of the spline curve.

 

What am I doing wrong ? I have tried hovering the cursor all around the area on the spline where the tangent point should be ..... I have tried zooming in but the line will only snap to one of the two 'tangent' points shown in the pictures.

 

Is there another method ?

Tangent 1.jpg

Tangent 2.jpg

Link to comment
Share on other sites

One possible work-around is to Flatten the Spline, which turns it into a polyline as a series of arcs. You can now draw a line from the centre of the appropriate arc perpendicular to your line. Where this line intersects the spline is your tangent point.

Tangent to Spline.PNG

Link to comment
Share on other sites

The technique which I described in my earlier post worked fine for me, when I tried it on the spline which I created and is shown in my previous screenshot.

Having seen your response, I opened your drawing and I too found that it would not work, and I don't understand why either. Splines are tricky.

I then tried an approach like eldon suggested, but using the PEDIT command, and while doable, it seemed to me at the time, that there might be a better way, and it was bedtime, so I called it a night.

Revisiting the drawing, and eldon's post I see that FLATTEN turns the spline into ARCS, which is more accurate than the PEDIT approach I tried, because it creates a series of straight lines, which is less precise, as evidenced by the attached screenshot.

 

Sounds like eldon's suggestion is a winner (there is much to be said for consistency). :beer:

PEDIT not so good for spline tangency.jpg

Link to comment
Share on other sites

Thanks for the reply.

 

However I cannot make this work for me ...

 

I set the Snaps as instructed and copy the line using the mid point of the line as the reference point. The only places it will snap to the spline as tangent are at the two points where an imaginary line from the reference point I have selected is tangent to the spline. It will not snap where the line itself should be tangent (i.e. somewhere near the top of the spline curve in the pictures).

 

See attached pictures. The mid point of the line is just above the top of the spline curve.

 

What am I doing wrong ? I have tried hovering the cursor all around the area on the spline where the tangent point should be ..... I have tried zooming in but the line will only snap to one of the two 'tangent' points shown in the pictures.

 

Is there another method ?

Could that be a coplanar issue? Orbit those guys around or check the Z values. I don't think tangent is possible unless the curve and line are on the same plane.
Link to comment
Share on other sites

I downloaded and tried it. Copy by midpoint, and shlubbed it around until the tangent snap lit up. No issues. Good grief! Why is this so dark?

Untitled.jpg

Link to comment
Share on other sites

I downloaded and tried it. Copy by midpoint, and shlubbed it around until the tangent snap lit up. No issues. Good grief! Why is this so dark?

 

Interesting Dana, yeah they are coplanar.

Having read your post, I reopened the OP's drawing, and I still can't get the tangent snap to light up on it, like it did on my own spline. :huh:

Link to comment
Share on other sites

Thanks for the comments and suggestions.

 

I finally got the snap to tangent approach to work after much fiddling. Just once though and I cannot repeat it. I have no idea why it works in some cases and not others. I will try the convert to Polyline / Arc approach ... not exact, but probably close enough.

Link to comment
Share on other sites

Interesting Dana, yeah they are coplanar.

Having read your post, I reopened the OP's drawing, and I still can't get the tangent snap to light up on it, like it did on my own spline. :huh:

 

EDIT: I re-reread this to the point where it does not make any sense to me any more. It may very well not make any sense at all. My advice is to not read any further, and go get a beer with friends.

 

You probably should have the other nearby snaps that might interfere turned off. Splines have a bunch of little blue grip thingies lurking all over the place and I don't know how they react to snap proximity, so I turned everything BUT Tangent OFF.

 

Caution, Science happening, Geometry to be specific. (Wait, let me qualify that. It's AutoCad Geometry, not Science.)

 

We must assume the line, if extending either end, will never intersect the curve in question.

 

Moving that line toward a curve by any point other than an end point must result in an intersection at a tangent point FIRST. It's just geometry, and all.

 

EDIT:Moving any line, without changing its angle, or moving the line to a point so it would intersect the circle if extended, toward a curve by any point on the line will result in an intersection at a tangent point first. It's just geometry, and all. It may not be, and does not have to be the point the line is being moved by.

 

Theoretically, OFFSET should work too, but you need to hit the exact tangent point for the Through solution on the curve.

 

EDIT: If one were to draw a line from the center of the circle to a perpendicular point on the line, then Offset Along the new line, from the intersection with the original line to the intersection of the new line and the circle, the result would be a line tangent with the circle.

 

The nearest point on a curve to a non-intersecting line is always the potential tangent point, and even AutoCad can't change that.

 

I have noticed that AutoCad will give one the chance to really mess up with a snap if one becomes too slow and tedious and tries too hard to zoom way in, and be all hesitant with the cursor.

 

The slower the worser.

 

If you use the tracking vectors for polar and snap tracking, when you get all antsy and try too hard to hit the perfect spot, you will see the vector lines begin to spin wildly all around the cursor after the potential snap has been acquired.

 

While you are still trying to make the hit perfect, AutoCad will begin to offer up all the other snap symbols that may be occupying that point, adding to the tracking vector craziness. It's as if it says "OK, that one wasn't to your liking, how bout this one, or this one, or this one." When this happens to me, I just hit escape and do it over, clicking as soon as the first snap symbol is lit. Otherwise, the initial attempt will almost always result in a miss. Once you have a tracking vector, the snap will happen ANYWHERE along the vector.

 

Sometimes, in AutoCad he who hesitates (slow, tentative, wishy washy) is sloppy.

Edited by Dana W
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...