132 Section 11: Calculating With Complex Numbers
Conditional Tests
For programming, the four conditional tests below will work in the complex
sense: ~ and T 0 compare the complex number in the (real and
imaginary) X-registers to 0 + 0i, while T 5 and T 6 compare the
complex numbers in the (real and imaginary) X- and Y-registers. All other
conditional tests besides those listed below ignore the imaginary stack.
~ T 0 T 5 (x = y) T 6
Example: Complex Arithmetic. The characteristic impedance of a ladder
network is given by an equation of the form
,
where A and B are complex numbers. Find Z
0
for the hypothetical values
A = 1.2 + 4.7i and B = 2.7 + 3.2i.