Hello!
I have 2 Math questions.
Q1: How can I get the complex number i (i^2=-1) in ActionScript 3?
Q2: How can I calculate logarithm base 10 (log10)?
Thank you!
Q2: The Math class has log functionality.
Q1: This thread may be helpful: http://www.actionscripts.org/forums/showthread.php3?t=130934
Ok, thanks! I had worked it out... I knew it has ln, but i needed log10.
There is a theorem that says: logY(a)=ln(a)/ln(Y). To Q2 is done.
Q1 please?
This is a matter bookkeeping since for a complex
number a + ib, you'll need to keep track of the real
and imaginary parts. Then you'll need to implement
the specific arithmetic you desire
This is not terribly difficult - see for instance:
http://www.mathcentre.ac.uk/resources/leaflets/firstaidkits/7_2.pdf