I am trying to perform a simple arithmetic in complex algebra.
a := Subscript[a, 1] + I*Subscript[a, 2];
b := Subscript[b, 1] + I*Subscript[b, 2];
r[z_] := a/(b - z) + a\[Conjugate]/(b\[Conjugate] - z);
when I try to evaluate r[0], mathematica gives me the following message
$RecursionLimit::reclim: Recursion depth of 256 exceeded.
I was expecting something like the following
2*Re[a/b] = 2 (a_1 * b_1 + a_2 * b_2)/(b_1 ^2 + b_2 ^2)
Could someone please point out where I did mess up?
Subscript
is a function too so Mathematica tries to evaluate the value ofa
ad infinitum inside it. Just change them toa1
anda2
for example. The same applies tob
. $\endgroup$=
instead of:=
. $\endgroup$