msvcp: fixed complex division
Piotr Caban
piotr.caban at gmail.com
Fri Nov 1 05:39:28 CDT 2013
On 11/01/13 00:44, Andrey Zhezherun wrote:
> This patch implements complex division correctly. The existing
> implementation did something else which is not division.
How about making it more numerically safe? Something like this should do
the job:
if(|c|>=|d|)
(a+ib)/(c+id) = ((a+b(d/c))+i(b-a(d/c)))/(c+d(d/c))
else
(a+ib)/(c+id) = ((a(c/d)+b)+i(b(c/d)-a))/(c(c/d)+d)
Thanks,
Piotr
More information about the wine-devel
mailing list