www.digitalmars.com         C & C++   DMDScript  

D - Complex type: .im property

reply Felix <Felix_member pathlink.com> writes:
The documentation states that if z is complex, z.im is imaginary while z.re is
extended. Shouldn't both be extended? (as in mathematics)
Also, in eng. the j is used for imaginary unit. Could D allow the use of i/j
(both of them) to write complex numbers?
Dec 15 2003
parent reply "Walter" <walter digitalmars.com> writes:
"Felix" <Felix_member pathlink.com> wrote in message
news:brkput$dg8$1 digitaldaemon.com...
 The documentation states that if z is complex, z.im is imaginary while
z.re is
 extended. Shouldn't both be extended? (as in mathematics)
Yes (good catch).
 Also, in eng. the j is used for imaginary unit. Could D allow the use of
i/j
 (both of them) to write complex numbers?
I've used both i and j in college, and never had any trouble switching between the two. I'm reluctant to add features without a clear advantage to them.
Dec 16 2003
parent Felix <Felix_member pathlink.com> writes:
In article <bro8du$3qg$1 digitaldaemon.com>, Walter says...
"Felix" <Felix_member pathlink.com> wrote in message
news:brkput$dg8$1 digitaldaemon.com...
 The documentation states that if z is complex, z.im is imaginary while
z.re is
 extended. Shouldn't both be extended? (as in mathematics)
Yes (good catch).
 Also, in eng. the j is used for imaginary unit. Could D allow the use of
i/j
 (both of them) to write complex numbers?
I've used both i and j in college, and never had any trouble switching between the two. I'm reluctant to add features without a clear advantage to them.
OK, I agree, maybe doesn't worth to add this feature. I got your point.
Dec 16 2003