(DEFUN C:GP ()
(COMMAND "SETVAR" "CMDECHO" 0)
(SETQ NY (GETVAR "CLAYER"))
;THE POINT IS FIST COUNTER Y THEN X
(MENUCMD "S=GP")
;(COMMAND "UJ" "")
(GRAPHSCR) (TERPRI)                                     ;GRAPHICS MODE
(SETQ D (GETREAL"\nSelect dim:"))
(SETQ C (GETPOINT"\nSelect center point:"))
(IF (AND (>= D 16) (< D 20))
    (PROGN
       (SETQ R1 8)
       (SETQ R2 10.5)
       (SETQ R3 13)
       (SETQ R4  15.5)
     )
)
(IF (AND (>= D 20) (< D 25))
    (PROGN
       (SETQ R1 10)
       (SETQ R2 12.5)
       (SETQ R3 15)
       (SETQ R4  17.5)
     )
)
(IF (AND (>= D 25) (< D 30))
    (PROGN
       (SETQ R1 12.5)
       (SETQ R2 15)
       (SETQ R3 17.5)
       (SETQ R4  20)
     )
)
(IF (AND (>= D 30) (< D 35))
    (PROGN
       (SETQ R1 15)
       (SETQ R2 17.5)
       (SETQ R3 21)
       (SETQ R4  23.5)
     )
)
(IF (AND (>= D 35) (< D 40))
    (PROGN
       (SETQ R1 17.5)
       (SETQ R2 20)
       (SETQ R3 24)
       (SETQ R4  27)
     )
)
(IF (AND (>= D 40) (< D 50))
    (PROGN
       (SETQ R1 20)
       (SETQ R2 22.5)
       (SETQ R3 27.5)
       (SETQ R4  31)
     )
)
(IF (AND (>= D 50) (< D 60))
    (PROGN
       (SETQ R1 25)
       (SETQ R2 28)
       (SETQ R3 35)
       (SETQ R4 38)
     )
)
(IF (AND (>= D 60) (< D 70))
    (PROGN
       (SETQ R1 30)
       (SETQ R2 33)
       (SETQ R3 40)
       (SETQ R4 43)
     )
))
;(IF (AND (>= D 70) (< D 100))
;    (PROGN
;    (PRIN1 'SORRY NO DATA)
;))
;========================================
(DEFUN C:GP4 ()
(setvar "BLIPMODE" 0)
(SETQ P1 (POLAR C PI (+ R1 4)))
(SETQ P2 (POLAR C 0 (+ R1 4)))
(SETQ P3 (POLAR C (* PI 0.5) (+ R1 4)))
(SETQ P4 (POLAR C (* PI 1.5) (+ R1 4)))
(SETQ P5 (POLAR C (* PI 0.25) (/ R1 3)))
(COMMAND "LAYER" "SET" "DRAW" "")
(COMMAND "CIRCLE" C (+ R1 1))
(COMMAND "LAYER" "SET" "CENTER" "")
(COMMAND "LINE" P1 P2 "")
(COMMAND "LINE" P3 P4 "")
(COMMAND "LAYER" "SET" "TEXT" "")
(COMMAND "TEXT" P5 "3" "0" "GP")
(COMMAND "LAYER" "SET" NY "")
(setvar "BLIPMODE" 1)
)
;========================================
(DEFUN C:GP3 ()
(setvar "BLIPMODE" 0)
(SETQ P1 (POLAR C PI (+ R4 3)))
(SETQ P2 (POLAR C 0 (+ R4 3)))
(SETQ P3 (POLAR C (* PI 0.5) (+ R4 3)))
(SETQ P4 (POLAR C (* PI 1.5) (+ R4 3)))
(SETQ P5 (POLAR C (* PI 0.25) (/ R4 3)))
(COMMAND "LAYER" "SET" "DRAW" "")
(COMMAND "CIRCLE" C R1)
(COMMAND "CIRCLE" C R4)
(COMMAND "LAYER" "SET" "HIDDEN" "")
(COMMAND "CIRCLE" C R3)
(COMMAND "LAYER" "SET" "CENTER" "")
(COMMAND "LINE" P1 P2 "")
(COMMAND "LINE" P3 P4 "")
(COMMAND "LAYER" "SET" "TEXT" "")
(COMMAND "TEXT" P5 "3" "0" "GP")
(COMMAND "LAYER" "SET" NY "")
(setvar "BLIPMODE" 1)
)
;========================================
(DEFUN C:GP2 ()
(setvar "BLIPMODE" 0)
(SETQ P1 (POLAR C PI (+ R4 3)))
(SETQ P2 (POLAR C 0 (+ R4 3)))
(SETQ P3 (POLAR C (* PI 0.5) (+ R4 3)))
(SETQ P4 (POLAR C (* PI 1.5) (+ R4 3)))
(SETQ P5 (POLAR C (* PI 0.25) (/ R4 3)))
(COMMAND "LAYER" "SET" "DRAW" "")
(COMMAND "CIRCLE" C R1)
(COMMAND "CIRCLE" C R3)
(COMMAND "LAYER" "SET" "HIDDEN" "")
(COMMAND "CIRCLE" C R4)
(COMMAND "LAYER" "SET" "CENTER" "")
(COMMAND "LINE" P1 P2 "")
(COMMAND "LINE" P3 P4 "")
(COMMAND "LAYER" "SET" "TEXT" "")
(COMMAND "TEXT" P5 "3" "0" "GP")
(COMMAND "LAYER" "SET" NY "")
(setvar "BLIPMODE" 1)
)
;========================================
(DEFUN C:GP1 ()
(setvar "BLIPMODE" 0)
(SETQ P1 (POLAR C PI (+ R2 3)))
(SETQ P2 (POLAR C 0 (+ R2 3)))
(SETQ P3 (POLAR C (* PI 0.5) (+ R2 3)))
(SETQ P4 (POLAR C (* PI 1.5) (+ R2 3)))
(SETQ P5 (POLAR C (* PI 0.25) (/ R2 3)))
(COMMAND "LAYER" "SET" "DRAW" "")
(COMMAND "CIRCLE" C R1)
(COMMAND "LAYER" "SET" "HIDDEN" "")
(COMMAND "CIRCLE" C R2)
(COMMAND "LAYER" "SET" "CENTER" "")
(COMMAND "LINE" P1 P2 "")
(COMMAND "LINE" P3 P4 "")
(COMMAND "LAYER" "SET" "TEXT" "")
(COMMAND "TEXT" P5 "3" "0" "GP")
;(COMMAND "TRIM" "C" C (POLAR C (* PI 0.25) 1) "" (POLAR C (* PI 0.75) R2) "")
;(COMMAND "ROTATE" (POLAR C (* PI 0.25) R2) "" C -8)
(COMMAND "LAYER" "SET" NY "")
(setvar "BLIPMODE" 1)
)
