How can $i^2 = k^2 = j^2 = ijk = -1$ be true? I have just started to learn the basics of quaternions, but I immediately run into a wall.
Litteraly the first equation on Wikipedia is as follows
$i^2 = k^2 = j^2 = ijk = -1$
This implies
$i = \sqrt{-1}$
$j = \sqrt{-1}$
$k = \sqrt{-1}$
but now $ijk = -1$ also need to be true 
$\sqrt{-1} * \sqrt{-1} * \sqrt{-1} = -1$
$-1 * \sqrt{-1} = -1$
$\sqrt{-1} = 1$ 
This can not be true. What am I missing here?
 A: There is no such thing as $\sqrt{-1}$ in the complex numbers. Don't use that symbol that's not well defined and your understanding of the complex numbers will improve.
While it is possible to define a square root function over the nonnegative real numbers, satisfying the property $\sqrt{a}\sqrt{b}=\sqrt{ab}$ for $a,b\ge0$, there is no function $f$ defined over the complex numbers satisfying


*

*$f(1)=1$;

*$(f(z))^2=z$, for all $z\in\mathbb{C}$;

*$f(z_1z_2)=f(z_1)f(z_2)$, for all $z_1,z_2\in\mathbb{C}$.


(here $f$ should be the square root).
Thus you can't use the relation $\sqrt{-1}\,
\sqrt{-1}=\sqrt{(-1)^2}=\sqrt{1}=1$: you see well this gives an immediate contradiction. But it is only apparent: since no function satisfies the requirements above, you can't use it. Actually, this contradiction is a proof that the above function cannot exist.
Over the quaternions the situation is even more complicated. There are infinitely many quaternions $h$ such that $h^2=-1$.
To wit, consider $h=a+bi+cj+dk$; then
\begin{align}
h^2
&=(a+bi+cj+dk)(a+bi+cj+dk) \\
&=a^2-b^2-c^2-d^2+2abi+2acj+2adk
\end{align}
so we get
$$
\begin{cases}
a=0 \\[4px]
b^2+c^2+d^2=1
\end{cases}
$$
and the second equation has infinitely many solutions (imagine the unit sphere in three-space). Among these there are indeed $\pm i$, $\pm j$, and $\pm k$.
Don't forget that the quaternions are not commutative, so seemingly mysterious things can happen. They're not mysterious, though: follow the given rules, not those that you think apply.
A: I think the best way to understand this in my opinion is by looking at the matrix form formulas (4,5,6,7) http://mathworld.wolfram.com/Quaternion.html, 
1
I
J
k
think about if $i^2=-1 iijk=-i$ so $jk=i$ further $jiijk=-ij$ so $k=-ji$, and other properties such as 
$jiijkj=-jij=-kj$ so $jk=i$ and $kj=-i$ and so on.
Arguably the simplest system with non commuting elements is the 2X2 matrix group which as is shown in the mathworld article is isomorphic to 1,i,j,k
A: The way to think about this is not to think of these as normal multiplication, but rather rotation. To rotate by i means to take the point at 1 and sort of move it 90 degrees up to i. Rotation by j and k is completely similar. All other numbers on the unit circles of i, j, and k for their respective multiplications follow the same 90-degree rotations. What happens to the other quaternions? Well, the unit circle of j and k, for the rotation of i, follows a similar motion, where j goes to k, and k goes to -j. And, for multiplications by other quaternions, you can probably guess what happens by now. Obviously, 180 degrees of rotation starting at 1 gives -1. Now we can tackle ijk. As I already said, ij gives k. This means that ijk = k^2. Obviously, this is -1. Problem solved!
