more tests for arithmetics, fixing NaN treatment in double to complex cast