用Autolisp编写程序,作一外切圆半径为100的五角星。 5
2个回答
展开全部
(defun C:wjx()
(setq p0 (getpoint "\n选择中心点"))
(setq p1 (polar p0 (/ (* 18 pi) 180) 323.606798 ))
(setq p2 (polar p0 (/ (* 90 pi) 180) 323.606798 ))
(setq p3 (polar p0 (/ (* 162 pi) 180) 323.606798 ))
(setq p4 (polar p0 (/ (* 234 pi) 180) 323.606798 ))
(setq p5 (polar p0 (/ (* 306 pi) 180) 323.606798 ))
(command "line" p1 p3 p5 p2 p4 "c" "")
(command "circle" p0 100))
(setq p0 (getpoint "\n选择中心点"))
(setq p1 (polar p0 (/ (* 18 pi) 180) 323.606798 ))
(setq p2 (polar p0 (/ (* 90 pi) 180) 323.606798 ))
(setq p3 (polar p0 (/ (* 162 pi) 180) 323.606798 ))
(setq p4 (polar p0 (/ (* 234 pi) 180) 323.606798 ))
(setq p5 (polar p0 (/ (* 306 pi) 180) 323.606798 ))
(command "line" p1 p3 p5 p2 p4 "c" "")
(command "circle" p0 100))
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询