问题

软件 >> Calculator >> Bug
Questions in category: Bug (Bug).

[Bug] 复数运算

Posted by haifeng on 2023-05-03 14:18:40 last update 2023-05-03 17:30:28 | Answers (0) | 收藏


>> (1+2i)/(3-4i)+(3i-2)
in> (1+2i)/(3-4i)+(3i-2)

out> (3*-1)|3*+(8*+2)|8*i
------------------------

 

>> (1+2i)/(3-4i)+2

会导致退出.

 

>> (1+2i)+(3-4i)-2+2i
in> (1+2i)+(3-4i)-2+2i

out> 2-4i
------------------------

正确答案应该是 2.  这里遇到 -, 将后面的 2+2i 直接作为操作数. 即执行的是 (1+2i)+(3-4i)-(2+2i)

 

 

v0.553

 


 

>> (1+2i)/(3-4i)
in> (1+2i)/(3-4i)

out> -1|5+2|5i
------------------------


>> (1+2i)/(3-4i)+1|5
in> (1+2i)/(3-4i)+1|5

out> 0+2|5i
------------------------

这里不能输入 (1+2i)/(3-4i)+1/5  因为 / 会被认为是复数之间的运算符.

>> (1+2i)/(3-4i)+(1+2i)*(3-4i)
in> (1+2i)/(3-4i)+(1+2i)*(3-4i)

out> 54|5+12|5i
------------------------

 

 

>> (a+bi)-(a+bi)
in> (a+bi)-(a+bi)

out> (0+a-(a+0)+0)+(0+b-(b+0)+0)i
------------------------

未化简

 

 

>> (1)/(5)i+2+3
in> (1)/(5)i+2+3

out> 25|26-5|26i
------------------------

在 numerical 模式下,

>> (1)/(5)i+2+3
in> (1)/(5)i+2+3

out> 5/i+5
------------------------