;;De Gua's Generalization of Pythagorean theorem to 3 D ;; May 12, 2007 Takaya Iwamoto ;; (defun C:DeGua() (setup_DeGua) (reset_sysvar) ) ;;; ;;; (defun setup_DeGua() (setup_sysvar) (setvar "PDMODE" 32) (setvar "PDSIZE" -2) (setq a 3 b 4 c 5 pnt_a (list a 0 0) pnt_b (list 0 b 0) pnt_c (list 0 0 c) pnt_org '(0 0 0) pnt_x '(4.5 0 0) pnt_y '(0 5.5 0) pnt_z '(0 0 7) chr_size 0.2 pnt_o (shift_pnt pnt_org '(-0.5 -0.5)) ) (make_line_1 "0" 8 pnt_org pnt_x) (make_line_1 "0" 8 pnt_org pnt_y) (make_line_1 "0" 8 pnt_org pnt_z) (make_pt "0" 0 pnt_a) (make_pt "0" 0 pnt_b) (make_pt "0" 0 pnt_c) (command "_.color" "1") (command "_.3dface" pnt_org pnt_a pnt_c "" "") (command "_.color" "2") (command "_.3dface" pnt_org pnt_b pnt_c "" "") (command "_.color" "3") (command "_.3dface" pnt_org pnt_a pnt_b "" "") (command "_.color" "4") (command "_.3dface" pnt_a pnt_b pnt_c "" "") (command "_.color" "BYLAYER") (textdisplay "X" pnt_x chr_size 0.) (textdisplay "Y" pnt_y chr_size 0.) (textdisplay "Z" pnt_z chr_size 0.) (textdisplay "A" pnt_a chr_size 0.) (textdisplay "B" pnt_b chr_size 0.) (textdisplay "C" pnt_c chr_size 0.) (textdisplay "O" pnt_o chr_size 0.) (command "_.zoom" "_E") (command "_.regen") (command "_.vports" 2 "_V") )