TheSwamp
CAD Forums => CAD General => Topic started by: bchapman on January 24, 2013, 03:26:32 AM
-
Is it possible to graphically find an arc that will be tangent to a line, and intersect another arc at exactly 90% (the tangent point I guess). See image:
Edit by Mark
Replaced your .bmp file with a .png.
Went from 4300 KB to 7KB.
Look up the command pngout.
Thanks mark!
-
Start,End, Direction method???
-
Start,End, Direction method???
Hey MJ, still overseas? I'll try that out and let ya know. My professor in college showed me a way to accomplish this by offsetting lines and bisecting circles and junk, but I forgot how he did that... to be fair it was 10 years ago lol
-
Start,End, Direction method???
Hey MJ, still overseas? I'll try that out and let ya know. My professor in college showed me a way to accomplish this by offsetting lines and bisecting circles and junk, but I forgot how he did that... to be fair it was 10 years ago loleffort
Yes, I'm in South Africa these days...with occasional junkets back to Qatar and other points on the globe.
It is just a geometric construction
-
Unfortunately that doesn't seem to work. I don't know the direction that will make the arc exactly 90 degrees at the intersection point. Thanks though.
Start,End, Direction method???
Hey MJ, still overseas? I'll try that out and let ya know. My professor in college showed me a way to accomplish this by offsetting lines and bisecting circles and junk, but I forgot how he did that... to be fair it was 10 years ago loleffort
Yes, I'm in South Africa these days...with occasional junkets back to Qatar and other points on the globe.
It is just a geometric construction
-
Here is how I might construct the Arc (I have used Dynamic Input for clarity):
(http://www.theswamp.org/lilly_pond/leemac/arcconstruction.gif)
To explain:
- Construct an XLINE extending perpendicular to the ARC using the PERpendicular Object Snap.
- Draw a CIRCLE centered at the intersection between the XLINE and ARC with circumference passing through the intersection between the XLINE & LINE.
- Copy the CIRCLE so that the center is located at the intersection between the XLINE and LINE.
- Construct the ARC with start point at the intersection of the copied CIRCLE and LINE, end point at the intersection of XLINE and ARC, and direction located at the intersection between the XLINE and LINE.
There are of course alternative methods (there are many ways to skin a cat in AutoCAD); for example, you can construct the initial XLINE using the center of the ARC to avoid using the PERpendicular Object Snap.
Also, you could construct two additional XLINEs perpendicular to the LINE and initial XLINE, and then use the intersection of these XLINEs as the center of the resulting arc, as shown in the following diagram:
(http://www.theswamp.org/lilly_pond/leemac/arcconstruction.png)
The arc could also be constructed using AutoLISP:
(defun c:myarc ( / a c i l p u v x z )
(while
(and
(setq p (getpoint "\nSpecify point on Arc: "))
(or
(null (setq a (car (nentselp p))))
(/= "ARC" (cdr (assoc 0 (entget a))))
)
)
(princ "\nPoint does not lie on an Arc.")
)
(if p
(progn
(while
(progn (setvar 'errno 0) (setq l (car (entsel "\nSelect Line: ")))
(cond
( (= 7 (getvar 'errno))
(princ "\nMissed, try again.")
)
( (= 'ename (type l))
(if (/= "LINE" (cdr (assoc 0 (entget l))))
(princ "\nSelected object is not a Line.")
)
)
)
)
)
(if l
(progn
(setq l (entget l)
u (cdr (assoc 10 l))
v (cdr (assoc 11 l))
p (vlax-curve-getclosestpointto a (trans p 1 0))
)
(if (< (distance p u) (distance p v))
(setq x u u v v x)
)
(if (and
(setq i (inters u v p (cdr (assoc 10 (entget a))) nil))
(setq x (polar i (angle i u) (distance p i)))
(setq c
(inters
x (polar x (+ (angle u v) (/ pi 2.0)) 1.0)
p (polar p (+ (angle p i) (/ pi 2.0)) 1.0)
nil
)
)
)
(progn
(if (LM:Clockwise-p p i x)
(setq z p p x x z)
)
(entmake
(list
'(0 . "ARC")
(cons 10 c)
(cons 40 (distance c p))
(cons 50 (angle c p))
(cons 51 (angle c x))
)
)
)
(princ "\nLine is parallel with perpendicular from Arc.")
)
)
)
)
)
(princ)
)
;; Clockwise-p - Lee Mac
;; Returns T if p1,p2,p3 are clockwise oriented
(defun LM:Clockwise-p ( p1 p2 p3 )
(<
(* (- (car p2) (car p1)) (- (cadr p3) (cadr p1)))
(* (- (cadr p2) (cadr p1)) (- (car p3) (car p1)))
)
)
(vl-load-com) (princ)
(http://www.theswamp.org/lilly_pond/leemac/arcconstructionlisp.gif)
Note that this arc is not unique since the original XLINE can be position at any perpendicular on the arc.
I hope this is clear!
-
Thanks Lee! You, like so many on this site, never cease to amaze me :)
-
Thanks Lee! You, like so many on this site, never cease to amaze me :)
You're very welcome Brian, it was an interesting geometrical problem to solve :-)