Occasionally I encounter messages like
Power::indet: Indeterminate expression (0. + 0. I)^0 encountered.
(or just 0^0). I believe I can safely declare these to be 1 for all of my purposes. Is there a way to build this in?
Occasionally I encounter messages like
Power::indet: Indeterminate expression (0. + 0. I)^0 encountered.
(or just 0^0). I believe I can safely declare these to be 1 for all of my purposes. Is there a way to build this in?
Operator overloading is one way.
Unprotect[Power];
Power[0, 0] = 1;
Protect[Power];
You should add also the cases like Power[0.,0.]. When you want to clear your own definitions, Unprotect, Clear, Protect.
0^0. Let us mark it as duplicate. Although I already learned from the answer below some additional possibilities, but still... – მამუკა ჯიბლაძე Jul 18 '17 at 05:14>!, no? – მამუკა ჯიბლაძე Jul 18 '17 at 06:18