Author | Comment |
fubli Marine Posted: 21 Dec 2006 19:37 GMT Total Posts: 21 | What exacly are complex numbers and how would you use them in a program? Examples Please! |
haveacalc Guardian
Posted: 22 Dec 2006 14:23 GMT Total Posts: 1111 | Pretty much all floating point number variables you have to work with (including those in lists) are complex numbers, which means that they each hold a real and imaginary value (a+bi). You can always access the "a" of a complex variable with real(, but there's no reason to use it unless "b" is nonzero. Likewise, access "b", the imaginary coefficient, using imag(.
The main reason to use number variables complexly, besides avoiding lists, is to just save space. Since each number variable takes up only 18 bytes each, I wouldn't bother with it unless you're making something kinda big.
Yay, knowledge!
--- -quoted directly from most movies that don't exist (and some that do). |
Zachary940 Wraith
Posted: 22 Dec 2006 21:35 GMT Total Posts: 714 | and i thought i would never use what I learn in Trig
--- It is much easier to suggest solutions when you know nothing about the problem. |