This example demonstrates the use of the absolute value statement to insure that you define a positive radius for a circle.
$$
$$ Declarations
$$
ENTITY/CR1
L10:PARAM/'DEFINE CIRCLE','X',X,'Y',Y, $
'RADIUS',RAD,RESP
JUMP/L10:,TERM:,,RESP
CR1=CIRCLE/X,Y,ABSF(RAD)
TERM:HALT
Because the radius parameter in the CIRCLE statement is defined using the absolute value, the radius is positive even if you enter a negative number for the radius in the PARAM statement.
A similar program can contain a mathematical function to create a tapped hole.
$$
$$ Declarations
$$
ENTITY/CR1,CR2
L10:PARAM/'DEFINE TAP','X',X,'Y',Y, $
'THREAD O.D.',RAD,RESP
JUMP/L10:,TERM:,,RESP
A=ABSF(RAD-.032)
CR1=CIRCLE/X,Y,A
&FONT=&DASHED
CR2=CIRCLE/X,Y,ABSF(RAD)
TERM:HALT
CR1 could also be created as follows:
CR1=CIRCLE/X,Y,ABSF(RAD-.032)