New tool - Line segment (Chord) from intersection of curve , circle / arc

While doing some tweaking of the Intersect Arc (Circle) Axis tool dialog / Property Editor I noticed the tool only takes the 1st point of intersection and wondered if there is a need to have a tool that provides both points of intersection of the Axis (technically known as a secant) and the line segment between the 2 (or more possible points if a curve) points - technically known as a chord? BTW… if the intersection provides only 1 point of intersection is called a tangent, and if there is no intersection it’s called an exterior line.

So is this something we might want to pursue?

chord

2 Likes

considering that it’s currently impossible to make a point at the intersection of a tangent & arc when the base point of the tangent is on a curve, it does sound like it might be desirable.

1 Like

I was thinking more in terms of getting results from 1 tool vs 3 tools to achieve the same objective… that is 2 points and a line segment - which could then be used in formulas for length and angle. There’s already precedent with the 2 new points with the True Dart tool - this tool would add a line to that. Of course an intersect with a curve could yield more than 2 points.

1 Like

I can’t say that I’ve ever had the need for this tool, however, I can see that it could help others. My only concern is having so many different tools that the program becomes very daunting for new users. Could it not be an option in the one tool to make either the 1st edge or both edges?

1 Like

I’ve not needed to do what is described above.

As a slight segway, when adding the ability to preview Seamly2D patterns directly on my-pattern.cloud (using JavaScript) I created quite a few examples of using more these more exotic tools in order to determine their behaviour at edge cases (obviously I can’t look at the source). Is there documentation that describes their precise behaviour? There are almost certainly still nuances that I’ve not discovered.

1 Like

That is a possibility. I’m sure you probably meant to say the 1st edge, the 2nd edge, or both. I’m thinking in terms of the arc / curve segments produced. Using only the 1st or the 2nd would produce 2 segments, while using both would produce 3 segments.

Of course if one were to use both points you could then draw a “line” between them, but part of what I was thinking was to have the tool produce the chord line too, without the need to use another tool.

2 Likes

As far as I know… no there is no documentation specific to each tool, That being said, with some of tools still having some bugs it’s hard to describe a precise behavior. There’s an expected behavior, but even with a tool that normally works, there can be unexpected behavior when using a different set of measurements. For example, when using the Intersect Arc Axis tool, with one set of measurements the arc may indeed intersect the axis, while switching the measurements may then move the arc or axis where they no longer intersect. If you were relying on that point for another tool and it “disappears” the program crashes. In that case the intersect point will now use the only “known” point - the draft block base point.

If there’s specific tools you’re looking at let me know - I might be able to describe what they are suppose to do and / or do.

2 Likes

The main thing is being able to put a point at the intersection of a curve & multiple parts of a tangent. Because if the base point of a tangent is on the arc that it’s supposed to intersect with, then obviously it’s already intersecting, so it just places a point on the existing point. Which is worthless.

I believe that the dart tool uses the names of the existing points that it’s based off of, just adding a suffix. I’m not clear on how we’d go about naming multiple original points simultaneously produced. Actually, I can’t remember the case where I thought it would be a problem.

So, multiple points of intersection? YES! Chord? It would be handy, sometimes, but I think that adding a line segment in the ordinary way will do a better job at keeping it super simple.

1 Like

Just create 2 consecutive numbers using the existing routine that keeps track of the next new block letter + number. Of course you could rename them if you want.

2 Likes

@Douglas, thanks for the response above. Some time ago I created a bunch of unit tests, at least one per tool, in order to understand the edge cases. Most of the later ones have a background picture showing the Seamly2D behaviour and the javascript version in the foreground. (Test1, see Test from JSON - point from circle and tangent as an example). The javascript preview is useless if it is not interpreted identically.

The .VAL version of each is also available - PatternEditor/tests/seamly2d/patterns at master · MrDoo71/PatternEditor · GitHub .

I would be very interested in keeping these use cases up to date, and I’d be happy to derive from my interpretation how I think edge cases are currently being interpreted by Seamly2D and to get this documented if that would be useful to anyone.

It would be really useful to have a thread for discussing the technical apsects of tool behaviour.

1 Like