陈老师,请教您关于边界等的问题
陈老师,请教您, 1,先获取一个曲面(或平面)的边界,
2。平行于x轴的截线(无数条),截得曲面边界上的两点
3。求这两点间的距离
4。代人一个方程d'=d+3d^2放大
5。将得到的值还给边界,得到新的边界。
就以上几步,您可不可以给点提示改用什么方法和命令做?万分感谢!!!
我现在用的是visual lisp. 刚刚家人将您的书用国际快递寄给我,寄费好贵阿。:)写的确实很好,解我燃眉之急。 用Hatch直线填充、分解剖面线、逐条取出分解后的直线得到长度... 谢谢您,陈老师,我刚刚想起,是不是可以用一个条件语句,对於同样的y坐标,得到边界上两点的横坐标,再求它们的差值?这样就可免掉做截线这一步了。如果可行,请问是用if 型还是用while 型,谢谢。对了,怎么样将新值返还给边界呢?我用的boundary 命令得到了一个边界,可以吗? 我好像看到过您提到的方法,翻到过,就是想不起来在哪一页了,可以提个醒吗? 很遗憾,我自己也没有书,都送人了,只文本文件,说不清页数... 请问它在你随书附赠的磁盘里吗?是哪一个?如果不再可以请您传一份给我吗?
xqy66@hotmail.com I just compiled a small program according to the above purpose.Seems there is something wrong to run this program.Could you please help me to check them?Thanks a lot!
(Defun bl (/ l l')<BR> (vl-load-com)<BR> (command "_.boundary")<BR> (command "_.hatch" (entlast))<BR> (command "_.explode" (entlast))<BR> (setq ss (ssget '((0 . "lines"))))<BR> (setq i 0)<BR> (repeat (sslength ss)<BR> (setq ent (ssname ss i))<BR> ;can i use this kind of sentence directly?(set l (list (getdist ent "select line")))<BR> (setq ens (vlax-Ename->Vla-Object (car ent)))<BR> (setq l (vlax-curve-getdistatparam ens <BR> (vlax-curve-getendparam ens )))<BR> (alert (strcat "Length = " (rtos l)))<BR> (entdel ent)<BR> (setq i (1+ i))<BR> )<BR> <BR> (setq l'(+ (EXPT l 3.0) l 1.0))<BR> <BR>(set dx(/(l'-l) 2))
(setq pt1x (cdr (assoc 10 l)))<BR>(setq pt1y (cdr (assoc 20 l)))<BR>(setq pt2x (cdr (assoc 11 l)))<BR>(setq pt2y (cdr (assoc 21 l)))<BR> <BR>(set ncl(list (- pt1x dx)))<BR>(set ncr(list (+ pt2x dx)));change the x coordinates of start and end points,but how to put back to points?
)
<BR>10 Start point (in OCS)<BR>DXF: X value; APP: 2D point <BR>20 DXF: Y value of start point (in OCS) <BR>11 End point (in OCS)<BR>DXF: X value; APP: 2D point <BR>21 DXF: Y value of end point (in OCS) <BR> 陈老师,可以请您帮我看看上面的程序吗?谢谢了。
页:
[1]