Can anyone confirm the Sqrt(-1)?

Started by
44 comments, last by JimPrice 19 years, 4 months ago
Now that's simple - imaginary numbers are composed of two part - a real part and an imaginary one.
You can write them as x = a + bi or simply as a pair (a,b).
Programs working with imaginary numbers only need to apply the set of rules defined for them, e.g. i2=-1.

Now if you have something like z = x + y it boils down to z = (xa + ixb) + (ya + iyb) = (xa + ya) + i(xb*yb).
Since all components are real numbers, the computer can easily deal with them. If you use the pair notation you don't even 'see' the i from the imaginary part.

Hope this helps,
Pat.
Advertisement
Re: AABBFFLLUUGG.

So I would be correct to assume that "i" is not a variable, but a value?

Languages; C, Java. Platforms: Android, Oculus Go, ZX Spectrum, Megadrive.

Website: Mega-Gen Garage

Quote:Original post by Anri
Re: AABBFFLLUUGG.

So I would be correct to assume that "i" is not a variable, but a value?

Yes.
Quote:Original post by Anri
Okay, you know how this is possible, but I see it in this way...the computer MUST have a value to work with. You simply cannot ask the computer x*i if i = ?. You cannot give it a "question mark".

You're absolutely right, and they do. Imaginary number are numbers that are the sqrt of a negative value. Let's say you wnat the sqrt(-16). Now, this is exactly the same ax (-16)^0.5, so we can break this up into 2 parts, (16^0.5)*((-1)^0.5), or alternatively sqrt(16)*sqrt(-1) = 4i. Doing things this way we can represent any imaginary number as a real number (that the computer *can* work with) multiplied by i (which to the computer is totally meaningless).

Complex numbers include a 'normal' real number with this, so a complex number can be represented as x+yi. Now, while the computer can't do jack with 'i', it *can* do anything it pleases with x and y. The fact that the i is there means there are certain rules that need to be followed to make the mathematical operations valid. For example, multipication. Say you want to find (1+2i)*(3+4i), you just multiply them together as you would normally with an unknown variable, so you get (3+10i+8i^2). However, since we know that i=sqrt(-1) then i^2=-1. So really the result is (-5+10i), which is again in a form that the computer can represent using x and y.

Now when coding this multiplication on computer, we don't try and plug in a value for i, we just apply some simple rules that get us the same results. Say you have 2 complex number on the computer, (x1=1,y1=2) and (x2=3,y2=4). To multiply them together we would calculate x3=x1*x2-y1*y2, y3=x1*y2+x2*y1.

Also, another way to help visualise complex numbers is to consider real numbers as the x axis and imaginary numbers as the y axis. This also allows you to represent a complex number as a magnitude and an angle, which is sometimes very useful (for example, in AC electricity as mentioned earlier).
"Voilà! In view, a humble vaudevillian veteran, cast vicariously as both victim and villain by the vicissitudes of Fate. This visage, no mere veneer of vanity, is a vestige of the vox populi, now vacant, vanished. However, this valorous visitation of a bygone vexation stands vivified, and has vowed to vanquish these venal and virulent vermin vanguarding vice and vouchsafing the violently vicious and voracious violation of volition. The only verdict is vengeance; a vendetta held as a votive, not in vain, for the value and veracity of such shall one day vindicate the vigilant and the virtuous. Verily, this vichyssoise of verbiage veers most verbose, so let me simply add that it's my very good honor to meet you and you may call me V.".....V
Quote:Original post by joanusdmentia
Quote:Original post by Anri
Okay, you know how this is possible, but I see it in this way...the computer MUST have a value to work with. You simply cannot ask the computer x*i if i = ?. You cannot give it a "question mark".

You're absolutely right, and they do. Imaginary number are numbers that are the sqrt of a negative value. Let's say you wnat the sqrt(-16). Now, this is exactly the same ax (-16)^0.5, so we can break this up into 2 parts, (16^0.5)*((-1)^0.5), or alternatively sqrt(16)*sqrt(-1) = 4i. Doing things this way we can represent any imaginary number as a real number (that the computer *can* work with) multiplied by i (which to the computer is totally meaningless).

Complex numbers include a 'normal' real number with this, so a complex number can be represented as x+yi. Now, while the computer can't do jack with 'i', it *can* do anything it pleases with x and y. The fact that the i is there means there are certain rules that need to be followed to make the mathematical operations valid. For example, multipication. Say you want to find (1+2i)*(3+4i), you just multiply them together as you would normally with an unknown variable, so you get (3+10i+8i^2). However, since we know that i=sqrt(-1) then i^2=-1. So really the result is (-5+10i), which is again in a form that the computer can represent using x and y.

Now when coding this multiplication on computer, we don't try and plug in a value for i, we just apply some simple rules that get us the same results. Say you have 2 complex number on the computer, (x1=1,y1=2) and (x2=3,y2=4). To multiply them together we would calculate x3=x1*x2-y1*y2, y3=x1*y2+x2*y1.

Erhh, you just repeated what I already wrote (just using more words[smile]).

Regards,
Pat.
Quote:
Original post by darookie
Physical meaning of imaginary numbers can easily be seen if you deal with AC voltage calculations (ok maybe that's more of a practical application).


Indeed, quantum mechanics too (don't get much more physical than that ;). My point was more that GA is fundamentally grounded in geometry which actually gives a way of visualizing i. I realize the standard Argand diagram gives a 'visual' appearance but that doesn't really explain what i is.

Quote:Original post by JuNC
Quote:
Original post by darookie
Physical meaning of imaginary numbers can easily be seen if you deal with AC voltage calculations (ok maybe that's more of a practical application).


Indeed, quantum mechanics too (don't get much more physical than that ;). My point was more that GA is fundamentally grounded in geometry which actually gives a way of visualizing i.

Yes, I understand that.

Cheers,
Pat.
Quote:Original post by darookie
Erhh, you just repeated what I already wrote (just using more words[smile]).

Regards,
Pat.

Yeah, but mine looks more impressive.... [smile]

Seriously though, I was being lazy and just replied to his post without checking the couple below it. My bad!
"Voilà! In view, a humble vaudevillian veteran, cast vicariously as both victim and villain by the vicissitudes of Fate. This visage, no mere veneer of vanity, is a vestige of the vox populi, now vacant, vanished. However, this valorous visitation of a bygone vexation stands vivified, and has vowed to vanquish these venal and virulent vermin vanguarding vice and vouchsafing the violently vicious and voracious violation of volition. The only verdict is vengeance; a vendetta held as a votive, not in vain, for the value and veracity of such shall one day vindicate the vigilant and the virtuous. Verily, this vichyssoise of verbiage veers most verbose, so let me simply add that it's my very good honor to meet you and you may call me V.".....V
Hmmm. Okay, I'm starting to get the idea - i ain't a variable. Thats the hard part over with. Great.

Once I'm over this, I shall take a Holiday!

Cheers.

Languages; C, Java. Platforms: Android, Oculus Go, ZX Spectrum, Megadrive.

Website: Mega-Gen Garage

Quote:Original post by Anri
Hmmm. Okay, I'm starting to get the idea - i ain't a variable. Thats the hard part over with. Great.

Once I'm over this, I shall take a Holiday!

Cheers.


Exactly. It's a symbolic representation of an impossible (yet useful) number. Well, impossible in the sense that you can't write it as x=1.234
"Voilà! In view, a humble vaudevillian veteran, cast vicariously as both victim and villain by the vicissitudes of Fate. This visage, no mere veneer of vanity, is a vestige of the vox populi, now vacant, vanished. However, this valorous visitation of a bygone vexation stands vivified, and has vowed to vanquish these venal and virulent vermin vanguarding vice and vouchsafing the violently vicious and voracious violation of volition. The only verdict is vengeance; a vendetta held as a votive, not in vain, for the value and veracity of such shall one day vindicate the vigilant and the virtuous. Verily, this vichyssoise of verbiage veers most verbose, so let me simply add that it's my very good honor to meet you and you may call me V.".....V

This topic is closed to new replies.

Advertisement