Jump to content

Locate a point on "Ellipse arc" to get chord of desired length


Ahankhah
 Share

Recommended Posts

Hi everyone,

 

is it possible to get a point on an "ellipse arc", in an specified distance to the start point of "ellipse arc"?

Link to comment
Share on other sites

Hi everyone,

 

is it possible to get a point on an "ellipse arc", in an specified distance to the start point of "ellipse arc"?

 

How about something like this?

 


(setq sel (entsel))
(setq ent (car sel))
(setq obj (vlax-ename->vla-object ent))
(setq res (vlax-curve-getPointAtDist obj 2.0)) ;; where 2.0 is the desired distance

Link to comment
Share on other sites

How about something like this?

 


(setq sel (entsel))
(setq ent (car sel))
(setq obj (vlax-ename->vla-object ent))
(setq res (vlax-curve-getPointAtDist obj 2.0)) ;; where 2.0 is the desired distance

 

R.K.McSwain, thank you very much for your prompt reply.

 

But unfortunately vlax-curve-getPointAtDist behaves like MEASURE command. It doesn't return the desired point. I want to find point on the curve with straight certain distance from its start point.

Link to comment
Share on other sites

Hi everyone,

 

is it possible to get a point on an "ellipse arc", in an specified distance to the start point of "ellipse arc"?

 

But unfortunately vlax-curve-getPointAtDist ...... doesn't return the desired point. I want to find point on the curve with straight certain distance from its start point.

 

OK, you did not say that you wanted the straight linear distance in your original request.

 

Do you mean like in the image below?

 

point6.png

 

Then draw a circle from the startpoint with a radius = the desired distance, and then find the intersection of the elliptical arc and the circle.

Link to comment
Share on other sites

Then draw a circle from the startpoint with a radius = the desired distance, and then find the intersection of the elliptical arc and the circle.

 

Thank you R.K.McSwain for the good offer, but...

 

Finding the intersection of two curves, this is the problem!

Link to comment
Share on other sites

 

Finding the intersection of two curves, this is the problem!

 

Here is an example:

 


(setq a (car (entsel)))
(setq b (car (entsel)))
(foreach item (ACET-GEOM-INTERSECTWITH a b 3)
 (vl-cmdf "._circle" item (* 0.02 (getvar "viewsize")))
)

Link to comment
Share on other sites

Thank you R.K.McSwain for the good offer, but...

 

Finding the intersection of two curves, this is the problem!

 

if you cannot find the INT of two curves, you should certainly be able to trim one to the other. then used the end point.

 

good luck.

Link to comment
Share on other sites

Here is an example:

 


(setq a (car (entsel)))
(setq b (car (entsel)))
(foreach item (ACET-GEOM-INTERSECTWITH a b 3)
(vl-cmdf "._circle" item (* 0.02 (getvar "viewsize")))
)

 

Nice and very good function: ACET-GEOM-INTERSECTWITH

 

R.K.McSwain, I appreciate your great help:D.

Edited by Ahankhah
Link to comment
Share on other sites

if you cannot find the INT of two curves, you should certainly be able to trim one to the other. then used the end point.

 

good luck.

lamensterms, your method works very good in lack of express tools. Thank you very much.

Link to comment
Share on other sites

:) ........

 

Yea, I don't like using code that you don't have the source to either.... but in this case, it was more of a "yes, it can be done" type of reference....

 

Glad to know you got that intersection stuff covered also...

Link to comment
Share on other sites

Perhaps these will help, I try to avoid dependence on Express Tools functions as much as possible.

Lee,

as always you have the best answer to everything. :):D:lol:

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
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.

 Share

×
×
  • Create New...