Bug #119710 column value unexpectedly change ,after changing atan2 function
Submitted: 17 Jan 8:16 Modified: 19 Jan 8:03
Reporter: Aaditya Dubey Email Updates:
Status: Not a Bug Impact on me:
None 
Category:MySQL Server: Optimizer Severity:S3 (Non-critical)
Version:8.0.x, 8.4.x OS:Any
Assigned to: CPU Architecture:Any

[17 Jan 8:16] Aaditya Dubey
Description:
for the atan2 function,after changing atan2(y,x) to -atan(-y,x),the value should be the same ,but for the -0,+0value,there is a bug.

How to repeat:
mysql> select atan2(-0,-1);
+-------------------+
| atan2(-0,-1)      |
+-------------------+
| 3.141592653589793 |
+-------------------+
1 row in set (0.01 sec)
mysql> select -atan2(0,-1);
+--------------------+
| -atan2(0,-1)       |
+--------------------+
| -3.141592653589793 |
+--------------------+
1 row in set (0.00 sec)
[19 Jan 8:03] Roy Lyseng
Thank you for the bug report.
However, this is not a bug.
+0 and -1 are identical values, hence atan2(-0,-1) and atan2(0,-1) should have identical results.