Pulser3 Programming Manual Download PDF

Calculating the Hypotenuse of a Right Triangle (a = sqrt[b * b + c * c])

It adds the square of b and the square of c, then loads the square root of the resulting value into variable a.

Example:

(IT ADDS THE SQUARE OF 3 AND THE SQUARE OF 4)

(THEN TAKES THE SQUARE ROOT OF THE RESULTING VALUE)

(AND LOADS IT INTO VARİABLE #0)

G65 L27 P#0 Q3 R4 (#0 WILL BE 5)

(IT ADDS THE SQUARE OF #1 AND THE SQUARE OF #2)

(THEN TAKES THE SQUARE ROOT OF THE RESULTING VALUE)

(VALUE AND LOADS IT INTO VARIABLE #0)

G65 L27 P#0 Q#1 R#2

Example:

(IT ADDS THE SQUARE OF 3 AND THE SQUARE OF 4)

(THEN TAKES THE SQUARE ROOT OF THE RESULTING VALUE)

(AND LOADS IT INTO VARIABLE #0)

#0 = SQRA[3, 4] (#0 WILL BE 5)

(IT ADDS THE SQUARE OF #1 AND THE SQUARE OF #2)

(THEN TAKES THE SQUARE ROOT OF THE RESULTING VALUE)

(VALUE AND LOADS IT INTO VARIABLE #0)

#0 = SQRA[#1, #2]