log for complex

J-S Caux js at gmail.com
Wed Mar 7 07:42:37 UTC 2018


Simple question: how do I get the log of a complex number?

If I try the simple
logtest = log(complex(1.0, 2.0))

I get the compiler error

Error: function core.stdc.math.log(double x) is not callable 
using argument types (Complex!double)

Some basic functions are described in 
https://dlang.org/phobos/std_complex.html, but not the log...


More information about the Digitalmars-d-learn mailing list