4 ms·
C has native support for complex arithmetic since C99. What kind of support do you think is missing? http://en.cppreference.com/w/c/numeric/complex http://en.c
by jforberg 10y ago
C has native support for complex arithmetic since C99. What kind of support do you think is missing?
http://en.cppreference.com/w/c/numeric/complex http://en.cppreference.com/w/c/numeric/complex
- thisrod 10y agoLast time I looked at C, the libraries had yet to be ported to C99. You had to choose between z = u + 2 * i * w, or zs = fft(ws); you couldn't have both. Therefore Fortran kept winning.
- dzdt 10y agoIt is kind of a "too little, too late" problem. C added complex numbers a decade after C++ spun off, so the two languages have different approaches. And C99 complex number support was slow to be added to compilers. On the UNIX side, it was never added to Solaris 9 (EOL 2014); Microsoft finally added Visual Studio support in 2013. And even if your compiler supported it, code generation quality has been historically bad. Some things were never added to the standard, like printf support, so complex double is still a lesser native type than double.